Skip to content

cbschaff/gym-duckietown

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

23 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Gym-Duckietown

Duckietown environment for OpenAI gym. Connects to a remote ROS simulation using ZeroMQ.

Installation

Requirements:

  • Python 3
  • OpenAI gym
  • numpy
  • scipy
  • pyglet
  • rospy

First, install rospy:

sudo apt-get install python-rospy

Clone the repository and install the other dependencies with pip3:

git clone https://github.com/duckietown/simulator.git
cd gym
pip3 install -e .

Usage

To run the standalone UI application, which allows you to control the robot manually:

./standalone.py

The standalone application will connect to the ROS bridge node, display camera images received and send actions (keyboard commands) back. By default, the ROS bridge is assumed to be running on localhost.

To train a reinforcement learning agent, you can clone the PyTorch code from this repository. It has been modified and tested for compatibility with gym-duckietown. I recommend using the PPO or ACKTR implementations. A sample command to launch training is:

python3 main.py --env-name Duckietown-v0 --no-vis --num-processes 1 --algo ppo

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 3

  •  
  •  
  •  

Languages