Giter Club home page Giter Club logo

learning_modular_policies's Introduction

Overview Code used in the publication "Learning modular robot control policies." (see https://arxiv.org/abs/2105.10049) Trains and runs modular robot policies with model based reinforcement learning, from the Biorobotics Laboratory at Carnegie Mellon University. Written and maintained by Julian Whitman.

System requirements

  • Training: NVIDIA GPU with minimum 8 Gb VRAM, ideally multiple GPUs with >12 Gb.
  • Running policies: most CPUs can run the policy, but we have only verified computers with at least four Intel i7 cores running it in real-time.

Dependencies

  • python3
  • pybullet for simulation: pip3 install pybullet
  • pytorch for deep neural networks: see https://pytorch.org/, install the version corresponding to your OS and GPU.
  • scipy for interpolation utility: pip3 install scipy
  • If you want to compile the modular robot urdfs from xacros, this requires a ROS verison of at least kinetic and with at least the xacro command installed.
  • If you are using a joystick to control the trained policy, get pygame for joystick reading: pip install pygame
  • The physical robot control (run_robot_policy.py) uses the hebi python API: pip install hebi-py, but is not needed for training or simulation, so most users will not need to install this package.
  • Some analysis scripts (with file extension .ipynb) use jupyter notebook, but it is not necessary to run the training or simulation tests.

Running

  • The first step after installing dependencies is to simulate a pre-trained policy with modular_policy/simulate_policy.py.
  • If you would like to train the modular policy from scratch, the main modular policy training script is modular_policy/mbrl.py. See "Learning modular robot control policies" for more information about the training process and compute time.

Repository contents

  • modular_policy contains scripts and utilities for training and executing modular policies.
  • mpl_policy contains scripts and utilities for training and executing multi-layer perceptron policies, which serve as a basis of comparison.
  • urdf contains the robot models used in simulations.

learning_modular_policies's People

Contributors

modularrobot avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

learning_modular_policies's Issues

robot hardware

Honored Dr. Julian Whitman:
I am Cui Ruopeng, a master student in Fudan University. Your work on "Learning Modular Robot Control Policies (TRO 2023)" is truly outstanding and we hope to reproduce this work. Could you please provide the purchase information for the robot hardware mentioned in the paper, such as purchase links?

Sorry for the inconvenience. Looking forward to your reply!

Cui Ruopeng

Where is print_xacros ?

Hi, I've tried modular_policy/simulate_policy.py to see how your codes work.
However, I encountered an error when loading the URDF file by p.loadURDF in robot_env.py.

I think this is because the urdf folder you provided only contains .xacro or .stl files and necessary to be compiled to urdf format. I found you got the job done in visualize_robot.ipynb using compile_to_urdf function. But I could not find print_xacros where you imported it from.

If possible, I would like you to provide print_xacro's source code. Thanks in advance.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.