Skip to content

A deep reinforcement learning agent to play Slither.io

Notifications You must be signed in to change notification settings

zachabarnes/slither-rl-agent

Repository files navigation

RattLe: a Slither.io reinforcement learning agent

Installation Instructions (meant for ubuntu VM):

  • Install Conda for ubuntu 16.04

  • Create Conda env

conda create --name rattle python=3.5
  • Activate a conda env
source activate rattle
  • Install needed packages
sudo apt-get update
sudo apt-get install -y tmux htop cmake golang libjpeg-dev libgtk2.0-0 ffmpeg
  • Install universe installation dependencies
pip install numpy
  • Install universe
git clone https://github.com/openai/universe.git
cd universe
pip install -e .
  • Install codebase and packages
cd ..
git clone https://github.com/zabarnes/RattLe.git
cd RattLe
pip install -r requirements.txt
  • Install docker for ubuntu 16.04 MAKE SURE TO DO STEP 2 AS WELL

  • Restart VM

Test installation

Run the test agent script

cd RattLe
python test.py

you should see a tiny rendering of the game or "yay" on the command line.

Train a model

Run the corresponding shell script. For example, to train our Recurrent Q model, run:

train_recurrentq.sh

About

A deep reinforcement learning agent to play Slither.io

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published