Simple SLAM Package
Extract from Autoware.ai but improved the speed after refactor codes.
Refer the latest README in the code repo: https://github.com/Kin-Zhang/simple_ndt_slam
Introduction
This package is extracted from autoware.ai 1.14.0 version, but with debug fixed, re-factor and speed up.
- fix the empty tf problem, check the related pull request
- speed up the whole package, more efficient than previous one, could run 10hz stably in 4-core CPU
Package Usage, using one LiDAR to do SLAM, no IMU no camera needed, of course sometime the result may not good enough, These Ubuntu 16.04-20.04 system with ROS can all run this package:
- Localization
- Mapping
- Dynamics points remove, check our benchmark repo
CHANGE LOG:
- 2023/05/21: Update to Dynamic Removal Benchmark link. This repo can provide the dataset format from rosbag to required format.
- 2022/12/2: For more people to use this package, Change README to English version. Here is a chinese readme before
- 2022/10/19: Update: download test Kitti dataset bag: onedrive link: kitti_sequence11_half.bag and follow building steps, modify the bag path in
ndt_mapping_kitti.launch
and roslaunch it.
Real robots/dataset I tried:
- 1x1m Small cars (Velodyne-16)
-
quadruped robot (Robosense-16), check our paper website, for our work on Real-time Neural Dense Elevation Mapping for Urban Terrain with Uncertainty Estimations
- KITTI dataset (Velodyne-64), teaser bag try onedrive link: kitti_sequence11_half.bag only 876Mb
- HKUST dataset (Ouster-128), check our dataset webiste
- RS-LiDAR-M1 (special LiDAR but have points cloud is enough for simple_ndt)
Effects shown here [remember modify the topic name on config]:
Running
Test on following system: Ubuntu 20.04 noetic, 18.04 melodic, 16.04 kinetic
Can run at any computer if using the docker
Option: docker
Provide the docker also:
# pull or build select one
docker pull zhangkin/ndt_mapping:refactor
docker build -t zhangkin/ndt_mapping:refactor .
Running inside:
docker run -it --net=host --name ndt_slam zhangkin/ndt_mapping:refactor /bin/zsh
cd src && git pull
cd .. && catkin build -DCMAKE_BUILD_TYPE=Release
roscore
# open another terminal
docker exec -it ndt_slam /bin/zsh
source devel/setup.zsh
roslaunch lidar_localizer ndt_mapping_docker.launch
Option: computer
Clone and running in your computer
mkdir -p ~/workspace/mapping_ws
cd ~/workspace/mapping_ws
git clone --recurse-submodules https://github.com/Kin-Zhang/simple_ndt_slam
mv simple_ndt_slam src
Install some dependences (glog, gflag)
cd src
sudo chmod +x ./assets/scripts/setup_lib.sh
sudo ./assets/scripts/setup_lib.sh
Opne src/packages/lidar_localizer/config/ndt_mapping.yaml
, modify the topic name based on your robot setting:
lidar_topic: "/velodyne_points"
if you are running on the bag, remember to modify the bag path in the launch
<arg name="bag_file" default="/home/kin/bags/kitti/semantickitti_sequence11.bag" />
<node pkg="rosbag" type="play" name="bag_play" args="$(arg bag_file) --clock -r 0.8" required="false"/>
Build and run, please remember modify the config to point out correct topic name
cd ~/workspace/mapping_ws
catkin build -DCMAKE_BUILD_TYPE=Release
source devel/setup.zsh
roslaunch lidar_localizer ndt_mapping.launch
Running image with save map: