Skip to content

Reinforcement learning environment based on openAI gym

License

Notifications You must be signed in to change notification settings

BabakAkbari/Slither.io-AI

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

29 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

slither.io-v0

slither.io-v0 is an openAI gym enviroment for testing and evaluating reinforcment learning algorithms in a popular classic snake game such as slither.io. The enviroment has a reasonably large field with multiple snakes. snakes grow when eating randomly-appearing fruit a snake dies when colliding with another snake, itself, or the wall and the game ends when all snakes die.

Getting started

Installation

Supported systems We currently support Linux and OSX running Python 2.7 or 3.5. Install Universe

To get started, first install slither.io-v0:

Supported systems:

We currently support Linux and OSX running Python 2.7 or 3.5. Install slither.io-v0 To get started, first install ``slither.io-v0``:
    git clone https://github.com/BabakAkbari/Slither.io-AI.git
    cd Slither.io-AI/
    pip install -e gym-slitherio				

Now install the latest version of docker and then:

docker build -t slitherio .
docker run --name=slither -v $(pwd):/home/apps -p 5005:5005 -p 5900:5900 -it --rm --user apps --privileged slitherio bash -l

In the docker container's bash run the following commands:

export DISPLAY=:0
vncserver :0
cd /home/apps
python remote.py

You will be asked to setup a password for your vnc enviroment. By default the password secure is hardcoded. You can change it whenever you want. Now your vncserver is ready and you can use any vncclient software with the given password to view the following screen.