Public Repository

Last pushed: 10 months ago
Short Description
Train your own autonomous car in a racing game with artificial intelligence
Full Description

ddpg-keras-torcs Docker image for AI Racing Game

Here are Dockerfile to get you up and running with a fully functional Using Keras and Deep Deterministic Policy Gradient to play TORCS code and Website .

Setup

You have 2 options to obtain the Docker image

Option 1 : Download the Docker image from Docker Hub

Docker Hub is a cloud based repository of pre-built images. You can download the image directly from here, which should be much faster than building it locally (a few minutes, based on your internet speed).

docker pull berlius/ddpg-keras-torcs:gpu

Option 2 : Build the Docker image locally

git clone https://github.com/berlius/DeepLearningDockerfile
cd ddpg-keras-torcs

sudo docker build -t berlius/ddpg-keras-torcs:gpu -f Dockerfile.gpu .

Running the Docker image as a Container

Only for the first intallation in your shared folder :

sudo nvidia-docker-plugin

xhost + ; sudo nvidia-docker run -it -p 8888:8888 -p 6006:6006 -p 8000:8000 -v `pwd`:/root/sharedfolder -v /mnt/sda4:/root/sda4 --privileged --device=/dev/snd:/dev/snd -v /tmp/.X11-unix:/tmp/.X11-unix:ro -e DISPLAY=unix$DISPLAY berlius/ddpg-keras-torcs:gpu lxterminal

In "lxterminal"

/root/install.sh

And the other session from the "DDPG-Keras-Torcs" folder :

sudo nvidia-docker-plugin

xhost + ; sudo nvidia-docker run -it -p 8888:8888 -p 6006:6006 -p 8000:8000 -v `pwd`:/root/sharedfolder -v /mnt/sda4:/root/sda4 --privileged --device=/dev/snd:/dev/snd -v /tmp/.X11-unix:/tmp/.X11-unix:ro -e DISPLAY=unix$DISPLAY berlius/ddpg-keras-torcs:gpu lxterminal

In "lxterminal"

python ddpg.py

Torcs can also be run separately by typing in a another "lxterminal" tab :

torcs
Docker Pull Command
Owner
berlius

Comments (0)