Installing Python and TensorFlow on macOS and Unix-like systems

To install the ML-Agents Toolkit on macOS or Linux, you need first to install Python 3.6 (at the moment, the ML-Agents Toolkit works only with Python 3.6).

Then, just go in the ml-agents subfolder and run the following command:

pip3 install .

If everything is correct, you should be able to run the mlagents-learn --help command without any errors.

Pip3 is automatically installed with any Python 3.x distribution. If, for some reason, you don't have pip3 installed, try following the official guide: https://pip.pypa.io/en/latest/installing/

Get Unity Artificial Intelligence Programming - Fourth Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.