LoginSignup
0

More than 3 years have passed since last update.

[Unity]ML-Agentsでサンプルプログラムが動かないときの対処法

Posted at

何があった?

Unityで強化学習ができるML-Agentsを使って見ようと思い、ここを見ながら環境を構築していたら、こんなエラーが

The API number is not compatible between Unity and python. Python API: API-13, Unity API: 1.0.0.

Google翻訳

API番号はUnityとPythonの間で互換性がありません。 Python API:API-13、Unity API:1.0.0。

原因

どうやら調べてみると、

pip install ml-agents

でインストールできるml-agentsは古いらしく、ml-agentsの最新リポジトリからインストールする必要があるみたい

対処法

ml-agentsをダウンロードし、ターミナルでml-agents-masterまで移動し、以下のコマンドで最新リポジトリのml-agentsをインストールできます。

pip install -e ./ml-agents
pip install -e ./ml-agents-envs

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0