boschresearch / remroc

This repository contains the code for the Realistic Multi-Robot Coordination (ReMRoC) Framework.
Apache License 2.0
48 stars 5 forks source link

Realistic Multi Robot Coordination

We introduce Realistic Multi Robot Coordination (REMROC). REMROC is a simulation and benchmark framework for multi-robot coordination methods and utilizes a physics based simulation and state-of-the-art robotic software tools.

It is based on ROS 2 Humble and Gazebo Fortress and uses Navigation 2 for the navigation stack of individual robots.

We recommend general knowledge of ROS 2 and the components of Navigation 2 when working with this framework.

Installation

REMROC consists of multiple ROS 2 packages and can be installed simply by cloning the repository and building the packages in a ROS 2 workspace. To ensure that all preconditions are met please check that your system fulfils the following prerequisites:

  1. installation of ROS 2 Humble - Instructions
  2. installation of Gazebo Ignition (version Fortress) - Instructions
  3. install colcon
    sudo apt install python3-colcon-common-extensions
  4. Either use rosdep to install the required ROS 2 packages or the following packages manually:
    sudo apt install ros-humble-ros-ign-gazebo ros-humble-ros-gz-bridge ros-humble-navigation2 ros-humble-robot-localization
  5. Move the contents of this repository into your ROS 2 workspace, remember to source the general ROS 2 installation source \opt\ros\humble\setup.bash, and build the packages with colcon build .

Start an experiment

To start an experiment, make sure the parameters in the launchfile ignition.launch.py are defined properly.

Remember to also source the respective workspace you have built the packages in, then you can start the specified experiment with

ros2 launch remroc ignition.launch.py

Contents

The REMROC framework consists of the following ROS 2 packages, some of which are interdependent:

Customization

REMROC allows for a high degree of customizability in mainly three parts:

In the following we will explain the main launchfile and these individual components, how they integrated and how one can modify them individually.

Launch file

The framework is started by launching the launchfile ignition.launch.py from the remroc package. At the beginning of the launchfile one can specify the following things:

Remember the following dependencies when modifying the launchfile:

Multi-robot coordination method

To introduce a new multi-robot coordination method or algorithm, one needs to define it in a ROS 2 node in remroc/remroc/. We provide a template as a starting point for anyone who wishes to implement a new coordination method.

The template implements subscribers to robot odometry and some sensors, like the laser scanner, to obtain robot information. It also implements interfaces to control the robots. This can be done either by directly publishing control commands or utilizing action servers which are provided by the robot's navigation stack.

Remember the following dependencies when implementing a new coordination method:

Environment and humans

The environments in REMROC are currently fixed sdf files. We utilize the agent class with a human skeleton and mesh to include humans which move along predetermined paths. The final sdf files need to be placed in remroc/world/sdfs/. The naming convention we follow is {mapname}_{_number_ofhumans}_{_samplenumbers}.sdf. In addition to the sdf file itself, the nav2 map server requires a .pgm occupancy map and a corresponding yaml file, which need to be placed in the src/remroc/world/maps/ directory and named with {mapname}.pgm and {mapname}.yaml.

The tutorial on actor models in gazebo ignition can be found here

The remroc_world_generation package provides a starting point to populate an existing map with humans that move on preexisting trajectories. In the respective launchfiles we utilize a navigation 2 global path planner to generate paths between random start and goal positions. Currently there is no way to do this out-of-the-box for arbitrary maps and number of humans, so you will need to add specific launchfiles and auxilery code if you want to generate trajectories for different environments.

Robots

Using a robot type in REMROC, requires a Gazebo model and a local navigation stack of the respective robot. We use a Navigation2 stack for the robots. To add a new type of robot, create a folder with the robot name in remroc_robots/robots/ containing the model.sdf and required meshfiles. Create another folder with the robot name in remroc_robots/config, containing the config files for the navigation stack.

Remember the following dependencies when adding new robot types:

Known Issues

Simulating multiple robots and their navigation stacks requires a considerable amount of computational resources. To resolve performance issues we recommend reducing the number of robots in the experiment.

The setuptools library may need to be downgraded to build the packages properly.

Navigation 2 may need to be build from source (humble branch) to include all the required packages, specifically the MPPI controller.

Gazebo can cause problems sometimes. in case the simulation does not start up as expected, try to verify that gazebo works properly. e.g. run ign gazebo shapes.sdf.

License

REMROC is open-sourced under the Apache-2.0 license. See the LICENSE file for details.

For a list of other open source components included in REMROC, see the file 3rd-party-licenses.txt.