-
-
Notifications
You must be signed in to change notification settings - Fork 21
Installation instructions
Download the official build from itch.io or by using the itch.io app which will allow you to easily update AI Runner, keep up with the devlogs and more.
I strongly recommend using the itch.io launcher which will automatically check for updates.
You can also manually check for updates by right clicking the app and clicking Check for update
from the dropdown menu
If you would like contribute towards development, or want to use the bleeding edge version of AI Runner you can do so in three different ways - Docker, pypi or bare-metal.
Prerequisites
- Ubuntu 20.04+ or Windows 10+
- Python 3.10.6
- pip-23.0.1
Follow these steps to install AI Runner from source or pypi
Windows
pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu118
pip install https://github.com/acpopescu/bitsandbytes/releases/download/v0.38.0-win0/bitsandbytes-0.38.1-py3-none-any.whl
Linux
pip install bitsandbytes
# txt2vid support on linux:
sudo apt-get install ubuntu-restricted-extras
Clone handler and install
git clone -b develop https://github.com/Capsize-Games/aihandler.git
cd aihandler && pip install -e .
Install Triton
git clone https://github.com/openai/triton.git
cd triton/python
pip install cmake
pip install -e .
Install torch
pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu118
Clone AI Runner and install
git clone -b develop https://github.com/Capsize-Games/airunner.git
cd airunner && pip install -e . --no-deps
Run
python airunner/src/airunner/main.py
Currently there isn't much of an external API so using AI Runner as a library is not recommended.
Install AI Runner
pip install airunner
Current builds of AI Runner are compiled with pyinstaller on docker.
Pull Docker container from repo
Windows
docker pull ghcr.io/capsize-games/airunner/airunner:windows
Linux
docker pull ghcr.io/capsize-games/airunner/airunner:linux
Build Docker
Windows
docker-compose -f docker-compose.windows.yml build
docker tag ghcr.io/capsize-games/airunner/airunner:windows ghcr.io/capsize-games/airunner/airunner:windows
docker push ghcr.io/capsize-games/airunner/airunner:windows
Linux
docker-compose -f docker-compose.yml build
docker tag ghcr.io/capsize-games/airunner/airunner:linux ghcr.io/capsize-games/airunner/airunner:linux
docker push ghcr.io/capsize-games/airunner/airunner:linux
Run the app using Docker
Windows
docker-compose -f docker-compose.windows.yml run windows_prod xvfb-run -e /dev/stdout wine64 C:/Python310/python.exe Z:/app/airunner/src/airunner/main.py
Linux
docker-compose run linux python3 /app/main.py
Build latest version of AI Runner using Docker locally - this will output a build
and dist
folder on your machine.
Windows
docker run -it -e DEV_ENV=0 -e AIRUNNER_ENVIRONMENT=prod -e AIRUNNER_OS=windows -e PYTORCH_CUDA_ALLOC_CONF=garbage_collection_threshold:0.9,max_split_size_mb:512 -e NUMBA_CACHE_DIR=/tmp/numba_cache -e DISABLE_TELEMETRY=1 -v ./build:/app/build -v ./dist:/app/dist ghcr.io/capsize-games/airunner/airunner:windows wine64 build.windows.cmd
Linux
docker run -it -e DEV_ENV=0 -e AIRUNNER_ENVIRONMENT=prod -e AIRUNNER_OS=linux -e PYTORCH_CUDA_ALLOC_CONF=garbage_collection_threshold:0.9,max_split_size_mb:512 -e NUMBA_CACHE_DIR=/tmp/numba_cache -e DISABLE_TELEMETRY=1 -e TCL_LIBDIR_PATH=/usr/lib/x86_64-linux-gnu/ -e TK_LIBDIR_PATH=/usr/lib/x86_64-linux-gnu/ -v $(pwd)/build:/app/build -v $(pwd)/dist:/app/dist ghcr.io/capsize-games/airunner/airunner:linux bash build.sh
Run the build
./dist/airunner/airunner