GithubHelp home page GithubHelp logo

ut-austin-rpl / sirius Goto Github PK

View Code? Open in Web Editor NEW
30.0 0.0 3.0 150 MB

Official codebase for Sirius: Robot Learning on the Job

Home Page: https://ut-austin-rpl.github.io/sirius/

License: MIT License

Python 99.24% Shell 0.76%
behavioral-cloning human-in-the-loop human-robot-interaction imitation-learning pytorch robot-learning robotics

sirius's Introduction

Sirius ๐ŸŒŸ: Robot Learning on the Job


This is the official codebase for the Sirius paper:

Robot Learning on the Job: Human-in-the-Loop Autonomy and Learning During Deployment
Huihan Liu, Soroush Nasiriany, Lance Zhang, Zhiyao Bao, Yuke Zhu
UT Austin Robot Perception and Learning Lab
Robotics: Science and Systems (RSS), 2023
[Paper] ย [Project Website] ย [Real Robot Control]


Quickstart

Sirius builds upon robomimic, a framework for robot learning from demonstration. Sirius also uses the robotics simulator robosuite powered by the MuJoCo physics engine.

Setup Sirius codebase

Installing Sirius

git clone https://github.com/UT-Austin-RPL/sirius
cd sirius
conda env create -f sirius.yml
conda activate sirius
pip install -e .

Installing robosuite

The additional reference for installing robosuite here and here could be helpful.

$ git clone https://github.com/ARISE-Initiative/robosuite.git
$ cd robosuite
$ pip install -r requirements.txt
$ pip install -e .

Usage

Running Sirius

Running Sirius intervention-guided policy learning:

python robomimic/scripts/train.py --config robomimic/exps/sirius/sirius.json

IWR baseline:

python robomimic/scripts/train.py --config robomimic/exps/sirius/bc_iwr.json

BC baseline:

python robomimic/scripts/train.py --config robomimic/exps/sirius/bc.json

Sirius Data Collection Pipeline

We include the script for collecting demonstrations and performing human intervention during robot policy execution below. We use a spacemouse for providing both demonstration and intervention. More details for setting up Spacemouse can be found here.

Performing Human Demonstration

Perform human demonstration with the flag --all-demos:

python robomimic/scripts/hitl/collect_hitl_demos.py --all-demos --num-traj 50

Policy Execution with Intervention

Perform human intervention with the policy checkpoint ${checkpoint}:

python robomimic/scripts/hitl/collect_hitl_demos.py --num-traj 50 --checkpoint ${checkpoint}

Processing data

Adding modalities

By default, the datasets are generated in the minimum format with only low-level state information to save space. To add image observation and other modalities for training, run the following post-processing script. It will process the original data ${data.hdf5} into ${data_processed.hdf5}, with image size ${image_size}. By default, the two camera view uses are agentview and robot0_eye_in_hand, which you can modify in the script template_process_sim_dataset.sh.

cd robomimic/scripts/hitl

source template_process_sim_dataset.sh ${data.hdf5} ${data_processed.hdf5} ${image_size}

Acknowledgements

This codebase is largely built on robomimic and robosuite. We also thank Ajay Mandlekar for sharing well-designed simulation task environments beyond the robomimic codebase like Coffee and Threading tasks during project development.

For real-robot experiments, we used Deoxys, a controller library for Franka Emika Panda developed by Yifeng Zhu.


Citation

@inproceedings{liu2022robot,
    title = {Robot Learning on the Job: Human-in-the-Loop Autonomy and Learning During Deployment},
    author = {Huihan Liu and Soroush Nasiriany and Lance Zhang and Zhiyao Bao and Yuke Zhu},
    booktitle = {Robotics: Science and Systems (RSS)},
    year = {2023}
}

sirius's People

Contributors

huihanl avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

sirius's Issues

Missing file: template_process_sim_dataset.sh leading to subprocess error.

Hello,

While attempting to run the project, I encountered an error indicating that a file named template_process_sim_dataset.sh is missing.

Error Details:

bash: template_process_sim_dataset.sh: No such file or directory
Subsequent to this, a Python error is thrown:
Traceback (most recent call last):
  File "robomimic/scripts/hitl/collect_hitl_demos.py", line 815, in <module>
    subprocess.run([
  File "/home/zhaoting/miniconda3/envs/sirius/lib/python3.8/subprocess.py", line 493, in run
    with Popen(*popenargs, **kwargs) as process:
  File "/home/zhaoting/miniconda3/envs/sirius/lib/python3.8/subprocess.py", line 858, in __init__
    self._execute_child(args, executable, preexec_fn, close_fds,
  File "/home/zhaoting/miniconda3/envs/sirius/lib/python3.8/subprocess.py", line 1639, in _execute_child
    self.pid = _posixsubprocess.fork_exec(
TypeError: expected str, bytes or os.PathLike object, not NoneType
This suggests that due to the missing bash script, a None value is being passed somewhere it shouldn't be, leading to the TypeError.

Could you please check if this file is missing from the repository or guide me if I've overlooked something?

Thank you for your assistance!

Error in running the script

I have tried to run the scripts and i have ran into two errors. First, when I ran the data collection script, the keyboard inputs are not registered. Secondly, when trying to fix the keyboard input error, I ran into this error:

  File "robomimic/scripts/hitl/collect_hitl_demos.py", line 253, in collect_trajectory
    obs, _, _, _ = env.step(action, action_mode=action_mode)
TypeError: step() got an unexpected keyword argument 'action_mode'

I have set up the environment with the following packages:
mujoco-py 2.0.2.8
robosuite 1.2.0

Thank you for your help!

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.