hari-sikchi / gym-gazebo

A toolkit for developing and comparing reinforcement learning algorithms using ROS and Gazebo.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

RL experiments on Husky integrated with OpenAI gym

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes.

Requirement

  • ROS Indigo
  • Gazebo 7

Build and install gym-gazebo

For installation on ROS Indigo:-

  1. Getting the ros packages necessary for our experiments

Get the following packages individually from their git respository(indigo branch) and replace/insert(if not already present) them in the <INSTALLATION_ROOT>/gym_gazebo/envs/installation/catkin_ws/src/ directory.

  • ar_track_alvar_msgs
  • ecl_core
  • ecl_navigation
  • ecl_tools
  • ecl_lite
  • mav_comm
    Now, for the husky environment we require packages provided by Clearpath Robotics for model import.
  • husky
    Note: Replace the urdf and launch files in husky/husky_description with those given in additional_packages/husky_description.
  • Copy all the packages given in the additional_packages folder in the path <INSTALLATION_ROOT>/gym_gazebo/envs/installation/
  • Navigate to <INSTALLATION_ROOT>/gym_gazebo/envs/installation/catkin_ws/
  • Run catkin_make
  1. Getting the plugins ready.
  • The plugins for gazebo world allow us to define behaviour in gazebo world(Random pose, Random velocity of obstacles, etc).

  • Plugins required for our experiment are located in <INSTALLATION_ROOT>/gym_gazebo/envs/husky/husky_plugin . Run the following commands to build the plugin. For more details regarding usage, see the README in the husky_plugin folder.

    mkdir build
    cd build
    cmake ..
    make
    

c. Add the following line to your bashrc.(Set the path for compiled plugins)

export GAZEBO_PLUGIN_PATH=${GAZEBO_PLUGIN_PATH}:<INSTALLATION_ROOT>/gym_gazebo/envs/husky/husky_plugin/build 

Running the experiments

  cd <INSTALLATION_ROOT>/examples/husky    
  python husky_reactive_control_qlearn.py  
Name Middleware Description Observation Space Action Space Reward range
husky_dynamic-v0.pngGazeboHuskyWallMovingObstacles-v0 ROS Continous Continuos
husky_dynamic-v0.pngGazeboHuskyReactiveControlEnv ROS Discrete Discrete

Visualize the Learning Process


About

A toolkit for developing and comparing reinforcement learning algorithms using ROS and Gazebo.

License:GNU General Public License v3.0


Languages

Language:Python 96.6%Language:Shell 3.4%Language:Makefile 0.0%