Welcome to the comprehensive installation guide for Animal-AI. This guide is designed to help you install and set up Animal-AI smoothly, even if you're not familiar with Python dependencies, GitHub repositories, or Unity.
For Windows Users: This guide is tailored for Windows, aiming to provide a straightforward installation process.
For Mac and Linux Users:
Most instructions for Windows should apply to you as well. For MacOS, you might need to run chmod -R 777 AnimalAI.app
in your terminal to adjust permissions. Linux users may need to make the .exe
file executable with chmod +x env/AnimalAI.x86_64
and ensure files are moved to the parent folder after extraction.
- Download Python: Obtain Python 3.10.x from Python's official website. N.B. Python 3.10.x is the mininum version for AAI version 4.2.0 and above.
- Run the Installer: Follow the installation prompts and ensure to add Python to your PATH (via the checkbox). For custom installations, keep the
install pip
box ticked. - Check Installation: Open Command Prompt and run
python --version
to verify the version. It should be Python 3.10.x. - Check Pip: Run
pip --version
. If pip is not installed, runpython -m ensurepip
. Pip is included by default in Python 3.4 and later. - Check PATH: Run
echo %PATH%
to verify Python is added to your PATH. Instructions for manual addition can be found here.
This step is only needed if you want to contribute to Animal-AI. For users who just want to use the environment, you can skip to step 3.
- Prepare a Directory: Create a root folder for the AnimalAI project.
- Clone the Repository: Choose one of the following options:
- Download the
.zip
file from Animal-AI GitHub and extract it. - Use GitHub Desktop for cloning.
- Clone via the GitHub CLI.
- Download the
- Verify: Ensure the root folder contains the
animal-ai
directory.
- Creating a Virtual Environment: This helps manage dependencies.
- Python: Use
python -m venv your_env_name
and activate it from theScripts
directory withactivate
. - Conda: Use
conda create --name your_env_name
and activate withconda activate your_env_name
.
- Python: Use
For more on virtual environments, see the Python Documentation or Conda Documentation.
- Navigate to the Repository: Go to the
animal-ai
directory. - Install Dependencies:
- Using pip: Run
pip install animalai
to install necessary dependencies from PyPI. - Using Conda: Install pip with
conda install pip
, then runpip install animalai
. - Using a Virtual Environment: Activate your environment, then run
pip install animalai
.
- Using pip: Run
- Check: Run
pip list
to confirmanimalai
is installed. For a specific version, usepip install animalai==x.x.x (e.g. 4.0.0)
.
- Download: Get the appropriate version for your OS from the Releases section.
- Extract: Unzip the downloaded file to your preferred location (Desktop recommended). Use tools like WinRAR or 7-Zip.
- Verify: Ensure the folder contains the
.exe
file for Windows,.app
file for MacOS, and.x86_64
file for Linux.
Launch the Animal-AI application from the directory where you extracted the files. Note that Animal-AI does not need to be installed on your system.
Refer to our Launching AAI guide for detailed instructions on starting and using Animal-AI.
-
Folder Navigation: Use
cd
to change directories. For example,cd AAI
moves to the "AAI" folder. Usecd..
to go up one directory level. For directory names with spaces, use quotes:cd "AAI Folder"
. List contents withdir
ordir /b
for a basic listing. -
Dependencies: All necessary dependencies, including Unity's
ml-agents
package, are included in the Python packageanimalai
. This is the only dependency needed. The package itself imports everything required.
If you encounter issues, please contact [email protected]. For common issues and solutions, visit our FAQ page.
Happy experimenting with Animal-AI!