• Stars
    star
    258
  • Rank 158,189 (Top 4 %)
  • Language
    C++
  • License
    BSD 3-Clause "New...
  • Created over 3 years ago
  • Updated almost 2 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

This package provides localization in a pre-built map using ICP and odometry (or the IMU measurements).

Localization using ICP in a known map

Overview

This package localizes the lidar sensor in a given map using the ICP algorithm. It subscribes to lidar scans and it registers them in a given map. If provided, it can use odometry or IMU to extrapolate the pose between the two iterations of ICP.

The user should provide a reference map (point cloud) as as a .pcd file and an initial pose in the reference map.

Released under BSD 3-Clause license. Parts of the code in this repo have been inspired by the code inside google cartogrpaher. We've retained the copyright headers where applicable.

Author: Edo Jelavic

Maintainer: Edo Jelavic, [email protected]

localization in a forest localization in an urban environment
forest urban

The package has been tested on the platforms shown in the images below. It has also been used during the ETH Robotic Summer School 2021 & 2022 (link). The corresponding launch files can be found here.

A corresponding map can for example be created using Open3D SLAM.

handheld sensor module skid steer robot legged robot
handheld skid-steer anymal

Installation

Clone the following three dependencies:

# in your source folder `src`
git clone https://github.com/leggedrobotics/libnabo.git
git clone https://github.com/leggedrobotics/libpointmatcher.git
git clone https://github.com/leggedrobotics/pointmatcher-ros.git

Install ROS and library dependencies with:

sudo apt install -y ros-noetic-pcl-ros ros-noetic-pcl-conversions ros-noetic-eigen-conversions ros-noetic-tf-conversions ros-noetic-tf2-geometry libgoogle-glog-dev
# OR, use rosdep in your source folder `src` 
sudo rosdep install -yr --from-paths .

Recommended to build in release mode for performance (catkin config -DCMAKE_BUILD_TYPE=Release)

Build with:

catkin build icp_localization

Usage

This package is based on the libpointmatcher package and it uses the ICP implementation from there. Libpointmatcher has an extensive documentation. icp_localization provides ROS wrappers and uses either odometry or IMU measurements to calculate initial guesses for the pointcloud alignment.

You can launch the program on the robot with: roslaunch icp_localization icp_node.launch. The pcd_filepath parameter in the launch file should point to the location where you stored your refrence map (pointcloud) in the .pcd format.

You can download the example bags and the example config files here. You can copy paste the rosbag and the map (.pcd file) to the data folder. Put the .yaml file in the config folder and you should be ready to run the forest environment example. For running the urban example, please adjust the parameters in the icp_node_rosbag.launch file. You need to chnage the pcd_filename, input_filters_config_name, bag_filename and the parameter_filepath.

The rosbag examples can be luaunched with roslaunch icp_localization icp_node_rosbag.launch

Note that the urban dataset uses the velodyne LIDAR whereas the forest dataset uses the ouster LIDAR. Please adjust the input_filters config file accordingly. Furthermore, in the forest dataset instead of full scans, each lidar packet is converted to pointcloud msg and then published.

The system has been tested with T265 tracking camera as an odometry source as well as legged odometry. If you are using the T265 make sure that you disable internal mapping and localization since it can cause pose jumps which will break the ICP.

The node also subscribes to the /initialpose topic and you can use rviz to set the initial pose of the range sensor. Note that this is not the initial robot pose since the range sensor coordinate frame might not coincide with the robot frame.

The node publishes the TF tree: map->odom->odom_source->range_sensor (in case you are using the odometry).

Configuration

The configuration is split into three .yaml files.

The icp.yaml file configures the ICP settings such as error metric and outlier filters. Any filter that is applied to the map can also be defined here.

The input_filters.yaml file configures operations that are applied to each scan of the range sensors. Subsampling, cropping and normal computation are configured in this file. Two examples have been provided (one for the velodyne puck range sensor and the other one for the ouste OS1 sensor).

The filtering and the ICP can be configured by adding your own custom configuration .yaml files. Documentation on how to do that can be found here.

The rest of the parameters is explained below:

  • icp_localization/initial_pose - initial pose of the range sensor frame in the provided map.
  • icp_localization/imu_data_topic - ROS topic on which the imu data is published
  • icp_localization/odometry_data_topic - ROS topic on which the odometry data is published
  • icp_localization/num_accumulated_range_data - Number of pointcloud messages that will be accumulated before trying to register them in a map. In case you are using full scans this parameter should be set to 1. In case you are publishing LIDAR packets, you need to convert them to sensor_msgs::Pointcloud2 first. At the moment there is no motion compensation implemented.
  • icp_localization/range_data_topic - ROS topic on which the LIDAR data is published
  • icp_localization/is_use_odometry - Whether to use odometry for initial pose prediction. If set the false, the pose extrapolator will try to use the imu data.
  • icp_localization/is_provide_odom_frame - Whether to provide the odom frame or publish directly map to range sensor transformation only
  • icp_localization/gravity_vector_filter_time_constant - Constant used for filtering imu measurements when estimating gravity. Smaller constant gives noisier estimates but adapts quicker to changes in orientation. Higher numbers give smoother estimates but take longer time to adapt to new orientation.
  • icp_localization/fixed_frame - Fixed frame map. Used mostly for visualization.
  • icp_localization/min_num_odom_msgs_before_ready - Ensure to have minimum number of msgs before starting ICP such that we can interpolate between them.
  • calibration - calibration parameters between sensors. The coordinate frames are shown below. Tos_rs is a transoformation from odometry source (e.g. tracking camera) to the range sensor frame.Timu_rs is the transformaion form the imu to the range sensor frame.

frames

All coordinate frames follow the URDF convention: http://wiki.ros.org/urdf/XML/joint.

More Repositories

1

darknet_ros

YOLO ROS: Real-Time Object Detection for ROS
C++
2,158
star
2

ros_best_practices

Best practices, conventions, and tricks for ROS
C++
1,477
star
3

legged_gym

Isaac Gym Environments for Legged Robots
Python
1,188
star
4

ocs2

Optimal Control for Switched Systems
C++
802
star
5

elevation_mapping_cupy

Elevation Mapping on GPU.
Python
508
star
6

open3d_slam

Pointcloud-based graph SLAM written in C++ using open3D library.
C++
503
star
7

rsl_rl

Fast and simple implementation of RL algorithms, designed to run fully on GPU.
Python
487
star
8

se2_navigation

Pure Pursuit Control and SE(2) Planning
C++
439
star
9

free_gait

An Architecture for the Versatile Control of Legged Robots
C++
397
star
10

traversability_estimation

Traversability mapping for mobile rough terrain navigation
C++
352
star
11

raisimLib

RAISIM, A PHYSICS ENGINE FOR ROBOTICS AND AI RESEARCH
325
star
12

xpp

Visualization of Motions for Legged Robots in ros-rviz
C++
293
star
13

graph_msf

A graph-based multi-sensor fusion framework. It can be used to fuse various relative or absolute measurments with IMU readings in real-time.
C++
259
star
14

viplanner

ViPlanner: Visual Semantic Imperative Learning for Local Navigation
Python
236
star
15

delora

Self-supervised Deep LiDAR Odometry for Robotic Applications
Python
232
star
16

iPlanner

iPlanner: Imperative Path Planning. An end-to-end learning planning framework using a novel unsupervised imperative learning approach
Python
200
star
17

SimBenchmark

Physics engine benchmark for robotics applications: RaiSim vs Bullet vs ODE vs MuJoCo vs DartSim
C++
193
star
18

learning_quadrupedal_locomotion_over_challenging_terrain_supplementary

Supplementary materials for "Learning Locomotion over Challenging Terrain"
C++
173
star
19

raisimGym

Python
141
star
20

art_planner

Local Navigation Planner for Legged Robots
C++
132
star
21

perceptive_mpc

Code for "Perceptive Model Predictive Control for Continuous Mobile Manipulation"
C++
129
star
22

wild_visual_navigation

Wild Visual Navigation: A system for fast traversability learning via pre-trained models and online self-supervision
Python
126
star
23

tensorflow-cpp

Pre-built TensorFlow for C/C++ and CMake.
Shell
114
star
24

terrain-generator

Python
108
star
25

vitruvio

Vitruvio is a framework for rapid leg design analysis and optimization for legged robots. The purpose of the simulation framework is to guide the early stages of legged robot design. The end effectors track an input trajectory and the necessary joint speed, torque, power and energy for the tracking is computed.
MATLAB
88
star
26

L3E

Learning-based localizability estimation for robust LiDAR localization.
87
star
27

elmo_ethercat_sdk

C++
80
star
28

MPC-Net

Accompanying code for the publication "MPC-Net: A First Principles Guided Policy Search"
Python
79
star
29

tree_detection

This package implements a simple tree detector from point cloud data. It makes no assumptions about the ground plane and can handle arbitrary terrains.
C++
69
star
30

rayen

Imposition of Hard Convex Constraints on Neural Networks
Python
68
star
31

raisimOgre

https://rsl.ethz.ch/partnership/spinoff/raisim.html
67
star
32

smug_planner

C++
59
star
33

noesis

A Reinforcement Learning Software Toolbox for Robotics
C++
53
star
34

RSLGym

Reinforcement learning framework from RSL for policy training with RaiSim.
Python
48
star
35

hardware_time_sync

Guidelines on how to hardware synchronize the time of multiple sensors, e.g., IMU, cameras, etc.
46
star
36

anomaly_navigation

Anomaly Navigation - ANNA
Python
41
star
37

cerberus_darpa_subt_datasets

Datasets collected by Team CERBERUS during the DARPA Subterranean Challenge
39
star
38

RaiSimUnity

A visualizer for RaiSim based on Unity
31
star
39

raw_image_pipeline

Image processing pipeline for cameras that provide raw data
C++
31
star
40

soem_interface

This software package serves as a C++ interface for one or more EtherCAT devices running on the same bus. The lower level EtherCAT communication is handled by the SOEM library.
C
28
star
41

tcan

A library to communicate to devices connected through CAN, EtherCat, USB or TCP/IP.
C++
28
star
42

swerve_steering

C++
26
star
43

workflows

Collection of workflows, best-practices and guidelines for software development.
Python
26
star
44

radiance_field_ros

Implementation of Radiance Fields for Robotic Teleoperation
Python
25
star
45

terra

A grid world environment for high-level earthworks planning in JAX for RL.
Python
22
star
46

urdf2robcogen

A tool that translates a robot URDF description into the kindsl format that can be processed by RobCoGen.
C++
21
star
47

maxon_epos_ethercat_sdk

Implementation of an ethercat device driver for the maxon epos 4
C++
18
star
48

self_supervised_segmentation

Python
17
star
49

ocs2_robotic_assets

Various robotic assets for OCS2 Toolbox
CMake
17
star
50

cerberus_anymal_locomotion

C++
16
star
51

cuda_ue4_linux

C++
15
star
52

ethercat_sdk_master

A wrapper around SOEM to allow multiple masters and devices on EtherCAT
C++
14
star
53

ethercat_device_configurator

Manages setup yaml files for the RSL ethercat infrastructure
C++
14
star
54

lunar_planner

Python
14
star
55

pytictac

Simple Timing Utils
Python
13
star
56

catkin_create_rqt

An RQT plugin generator script, supporting several arguments to generate a rqt plugin for ROS, similar to catkin_create_pkg
Python
12
star
57

rl-blindloco

Project page for Science Robotics paper "Learning Quadrupedal Locomotion over Challenging Terrain"
HTML
11
star
58

learning_docker

Shell
9
star
59

any_ping_indicator

An Ubuntu indicator applet to show the ping status.
Python
8
star
60

plr-exercise

Python
7
star
61

terra-baselines

Train, visualize, and evaluate RL policies for the Terra environment.
Python
7
star
62

rsl_heap

CMake
7
star
63

anymal_brax

Python
7
star
64

perfectlyconstrained

Official implementations from the paper "Should We Relax a Bit? A Study on Degeneracy Mitigation in Point Cloud Registration"
7
star
65

unity_ros_teleoperation

C#
6
star
66

gtsam_catkin

Catkinized version of gtsam.
CMake
4
star
67

digbench

Benchmarks and map generation for the Terra environment.
Python
4
star
68

mobile_manipulation

Under construction
3
star
69

realsense_eth_robotics_summer_school_2019

Launch files and utility nodes for running the Realsense on SMB
CMake
2
star
70

xpp-release

Release repository of the xpp repo, necessary for ros hosting.
1
star
71

rsl_panoptic_mapping

C++
1
star
72

rsl_panoptic

Python
1
star
73

pretrained_depth_embedders

Python
1
star
74

darknet_ros-release

1
star
75

webapp-container

Scripts and tools to containerize a PHP-FPM, Nginx, Redis web-application โš™๏ธ
Dockerfile
1
star