/SpaceRobotEnv

A open environment for free-floating space robot based on the MuJoCo platform.

Primary LanguagePythonApache License 2.0Apache-2.0

SpaceRobotEnv

SpaceRobotEnv is an open-sourced environments for trajectory planning of free-floating space robots. Different from the traditional robot, the free-floating space robot is a dynamic coupling system because of the non-actuated base, as shown in the [figure](#Introduction of free-floating space robot). Therefore, model-based trajectory planning methods encounter many dif- ficulties in modeling and computing.

Accordingly, the researches focus on how to utilize the model-free methods, like reinforcement learning algorithms, to obtain the trajectory directly. However, reaching high-level planning accuracy, bimanual coordination and end-to-end control remains an open challenge for space robotics researchers. To better help the community study this problem, SpaceRobotEnv are developed with the following key features:

  • Real Space Environment: we construct environments similar to the space. The free-floating space robot is located in a low-gravity condition.
  • Dynamic coupling control: Compared with robots on the ground, the torques of joints have a significant impact on the posture of the base. The movement of the base makes a disturbance on the positions of end-effectors, thus leading to a more complex trajectory planning task.
  • Image input: We provide the ability to use images as observations. And we also demonstrates our environment is effective, please see our paper.
  • Quick Demos

Paper link

Paper link

Paper link

Environments of this repo are as follows:

  • SpaceRobotState-v0
    • State vector contains the angular positions and velocities of joints, the positions and velocities of end-effectors and the positions of goals. The core goal is to make the end-effector reach the goal randomly selected within a large space.
  • SpaceRobotImage-v0
    • State vector only contains images information. The core goal is the same as that of the SpaceRobotState-v0 environment.
  • SpaceRobotDualArm-v0
    • The free floating space robot owns two robotic arms which are attached with the base. That means two end-effectors are corresponding to two goal positions. When two end-effectors reach the goals together, the task is finished.

Installation

Our environment is built on the Mujoco Simulation. So before using our repo, please make sure you install the Mujoco platform. Additionally, our framework is based on the Gym. Details regarding installation of Gym can be found here.

After you finish the installation of the Mujoco and Gym and test some toy examples using them, you can install this repo from the source code:

pip install -e .

Quick Start

We provide a Gym-Like API that allows us to get interacting information. test_env.py shows a toy example to verify the environments. As you can see, A Gym-Like API makes some popular RL-based algorithm repos, like Stable Baselines3, easily implemented in our environments.

import SpaceRobotEnv
import numpy as np

env = SpaceRobotEnv.SpaceRobotState()

dimu = env.action_space.shape
print(dimu)
dimo = env.observation_space['observation'].shape
print(dimo)


observation = env.reset()
max_action = env.action_space.high
print('max_action:',max_action)
print('mmin_action',env.action_space.low)
for e_step in range(20):
    observation = env.reset()
    for i_step in range(50):
        env.render()
        # print(observation)
        # action = env.action_space.sample()
        action = np.random.uniform(low=-1.0, high=1.0, size=(dimu,))
        observation, reward, done, info = env.step(max_action * action)

env.close()

Introduction of free-floating space robot

The free-floating space robot contains two parts, a robotic arm and a base satellite. The robot arm is rigidly connected with the base, and the whole space robot remains in a low-gravity condition. The 6-DoF UR5 model is chosen as the robot arm, and to simplify, we considered the base as a cubic structure. The specific structure is shown as follows.

Future plan

Tasks under development:

  • Point cloud inputs
  • Add new torque controllers, like impedance controller.
  • Bulid new environments

Algorithms:

  • PPO
  • TRPO
  • DDPG
  • TD3
  • SAC
  • HER
  • HDO

Citing SpaceRobotEnv

If you find SpaceRobotEnv useful, please cite our recent work in your publications.

@article{wang2022collision,
  title={Collision-Free Trajectory Planning for a 6-DoF Free-Floating Space Robot via Hierarchical Decoupling Optimization},
  author={Wang, Shengjie and Cao, Yuxue and Zheng, Xiang and Zhang, Tao},
  journal={IEEE Robotics and Automation Letters},
  volume={7},
  number={2},
  pages={4953--4960},
  year={2022},
  publisher={IEEE}
}

@inproceedings{wang2021multi,
  title={A Multi-Target Trajectory Planning of a 6-DoF Free-Floating Space Robot via Reinforcement Learning},
  author={Wang, Shengjie and Zheng, Xiang and Cao, Yuxue and Zhang, Tao},
  booktitle={2021 IEEE/RSJ International Conference on Intelligent Robots and Systems (IROS)},
  pages={3724--3730},
  organization={IEEE}
}

@inproceedings{wang2021end,
  title={An End-to-End Trajectory Planning Strategy for Free-floating Space Robots},
  author={Wang, Shengjie and Cao, Yuxue and Zheng, Xiang and Zhang, Tao},
  booktitle={2021 40th Chinese Control Conference (CCC)},
  pages={4236--4241},
  year={2021},
  organization={IEEE}
}

The Team

SpaceRobotEnv is a project contributed by Shengjie Wang, Xiang Zheng, Yuxue Cao , Fengbo Lan at Tsinghua University.

License

SpaceRobotEnv has an Apache license, as found in the LICENSE file.