Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[HANDS-ON BUG] mlagents-learn: command not found #586

Open
nnilayy opened this issue Jan 18, 2025 · 0 comments · May be fixed by #587
Open

[HANDS-ON BUG] mlagents-learn: command not found #586

nnilayy opened this issue Jan 18, 2025 · 0 comments · May be fixed by #587

Comments

@nnilayy
Copy link

nnilayy commented Jan 18, 2025

Describe the bug

The current Unit-5 and Bonus-Unit-1 notebooks, using the ML-Agents library, fail at the training step when executing the mlagents-learn command, indicating the mlagents-learn command is not found.

Image

Notebooks' Links
(1)Unit-5: https://colab.research.google.com/github/huggingface/deep-rl-class/blob/main/notebooks/unit5/unit5.ipynb
(2)Bonus-Unit-1: https://colab.research.google.com/github/huggingface/deep-rl-class/blob/main/notebooks/bonus-unit1/bonus-unit1.ipynb
(3)Bonus_Unit-1: https://colab.research.google.com/github/huggingface/deep-rl-class/blob/main/notebooks/bonus-unit1/bonus_unit1.ipynb

Material

  • Did you use Google Colab? Yes

If not:

  • Your Operating system (OS)
  • Version of your OS

Reason

This error is due to a compatibility issue between ML-Agents Python requirements and Colab's Latest Python version.

The ML-Agents library currently supports Python versions from Python 3.10.1 to Python 3.10.12, as specified in the setup files (ml-agents/ml-agents/setup.py and ml-agents-env/ml-agents/setup.py after cloning).
Image

However, the latest Python version in Colab is Python 3.11.11, which is not supported by the library.
Image

This version mismatch causes the installation step to fail silently, leading to the subsequent errors when the mlagents-learn or related commands are executed.

Fix

This can be solved by creating a new venv in Colab with a Python version that is supported by the with the ML-Agents library.

I have submitted a pull request to resolve this issue and have updated the documentation to reflect this change. Additionally, the notebook instructions have been updated to guide users on how to adjust the Python version if related issue arises in the future.

@nnilayy nnilayy linked a pull request Jan 18, 2025 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant