To install and use ML-Agents, you need install Unity, clone this repository and install Python with additional dependencies. Each of the subsections below overviews each step, in addition to an experimental Docker set-up.
Download and install Unity. If you would like to use our Docker set-up (introduced later), make sure to select the Linux Build Support component when installing Unity.
Once installed, you will want to clone the ML-Agents GitHub repository.
git clone git@github.com:Unity-Technologies/ml-agents.git
The unity-environment
directory in this repository contains the Unity Assets
to add to your projects. The python
directory contains the training code.
Both directories are located at the root of the repository.
In order to use ML-Agents, you need Python 3 along with the dependencies listed in the requirements file. Some of the primary dependencies include:
If you are a Windows user who is new to Python and TensorFlow, follow this guide to set up your Python environment.
If your Python environment doesn't include pip
, see these
instructions
on installing it.
To install dependencies, go into the python
subdirectory of the repository,
and run from the command line:
pip3 install .
If you'd like to use Docker for ML-Agents, please follow this guide.
You can download ML-Agents as Unity Packages:
- ML-Agents with TensorflowSharp Plugin
- ML-Agents without TensorflowSharp Plugin
- TensorflowSharp Plugin Only
If you run into any problems installing ML-Agents, submit an issue and make sure to cite relevant information on OS, Python version, and exact error message (whenever possible).