ML Agents Install Guide (V2.0.1)
The new versions of ML Agents also require a different version of python and the ML Agents package. This is the install guide for those new versions.
Windows Guide
1.Go to the python 3.8.10 download page
2. Download the 64 bit version of python 3.8 for windows
3. When this is done, open the downloaded file
4. !!! Select “Add Python 3.8 to Path” !!!
5. Continue the installation
6.Open your command prompt by typing “cmd” into the windows menu
7. Copy and paste the following command to install pytorch
py -3.8 -m pip install torch~=1.7.1 -f https://download.pytorch.org/whl/torch_stable.html
8. After the previous command finishes, copy and paste the following command to install ML Agents
py -3.8 -m pip install mlagents==0.28.0
9. If everything worked properly, you should be able to type in the following command without any errors
mlagents-learn --help
Mac Guide
For Mac M1 (or newer) chip
- Install Conda and create a new virtual environment named unity-mla
- Go to your terminal
- Copy and paste this following sequence into your terminal:
-
conda create -n unity-mla python=3.9.7 -y
-
conda activate unity-mla
-
conda install -c conda-forge pytorch=1.8 -y
-
conda install grpcio h5py -y
-
pip install mlagents==0.28.0 -q
-
- If everything worked properly, you should be able to type in the following command without any errors
mlagents-learn --help
For older Macs that use Intel chips
1. Go to the python 3.8.10 download page
2. Download the 64 bit version of python 3.8 for macOS
3. When this is done, open the downloaded file
5. Continue the installation
6. Open your command prompt by typing “terminal” into the search bar
7. Copy and paste the following command to install pytorch
pip3 install torch~=1.7.1 -f https://download.pytorch.org/whl/torch_stable.html
8. After the previous command finishes, copy and paste the following command to install ML Agents
pip3 install mlagents==0.28.0
9. If everything worked properly, you should be able to type in the following command without any errors
mlagents-learn --help
Debugging
…