Tested on Ubuntu 22.04 with an Nvidia RTX 3090
-
Install ROS2 Humble: LINK
-
Set up a ROS2 workspace: LINK
2a. prepare automatic sourcing of the ROS2 installation and workspace:echo "source /opt/ros/humble/setup.bash" >> ~/.bashrc echo "source /home/user/ros2_ws/install/setup.bash" >> ~/.bashrc
where the second line must be adapted to your ros2 workspace. Afterwards, source the bashrc file (
source ~/.bashrc
) or simply close your terminal and open an new one (thus bashrc is loaded). -
Clone the pointcloud merge node: LINK
-
Set up a Second workspace for Point Labeler and SuMa -> See Instructions at: LINK
-
Install Point Labeler: LINK
-
Install Surfel Based Mapping (SuMa): LINK 5a. One dependency of SuMa is GTSAM. On Ubuntu 22.04 there is currently no pre-built package for GTSAM. After installing GTSAM's dependencies, build GTSAM with:
cd ~ git clone https://github.com/borglab/gtsam.git cd gtsam mkdir build cd build cmake .. sudo make install
-
Install pcd2bin: LINK
-
Create a folder structure which meets the KITTI standard LINK:
mkdir -p ~/dataset/pointclouds cd ~/dataset mkdir rosbags mkdir -p sequences/00/velodyne cd sequences/00 mkdir labels
-
Record ROSBAG of your LiDAR Data. In our case, this data is made out of 5 x Livox Horizon LiDARs:
ros2 bag record <params>
-
Start the pointcloud merge node inside
~/dataset/pointclouds
. (the pcd files are stored in the folder in which the node is started):
https://github.com/nerovalerius/pointcloud_merge_and_kitti
. -
Start playback of the ROSBAG within 5 seconds. Otherwise the pointcloud merge node quits.
ros2 bag play rosbag2_2022_06_21-12_56_43_0.db3 -s sqlite3 --rate 0.5
. -
Convert the .pcd files with the pcd2bin node and store the .bin files inside
~/dataset/sequences/00/velodyne
:
ros2 run pcd2bin_kitti pcd2bin
. -
create a dummy calibration file inside your created sequence:
nano ~/dataset/sequences/00/calib.txt
and fill it with:P0: 1 0 0 0 0 1 0 0 0 0 1 0 P1: 1 0 0 0 0 1 0 0 0 0 1 0 P2: 1 0 0 0 0 1 0 0 0 0 1 0 P3: 1 0 0 0 0 1 0 0 0 0 1 0 Tr: 1 0 0 0 0 1 0 0 0 0 1 0
-
Run SuMa with:
~/catkin_ws/src/SuMa/bin/visualizer
and open the first binary pointcloud of the sequence, e.g.:~/dataset/sequences/00/full_cloud_00001.bin
Run SuMa to get a
poses.txt
file for your sequence by pressing the PLAY button and thensave poses.txt
to the~/dataset/sequences/00/
folder. SuMa creates a posegraph for your pointcloud sequence.Each pointcloud then gets a absolute position in a world_frame, which is used to load a complete sequence of pointclouds into the Point Labeler. This means that a large number of pointclouds can be labelled at once.
-
Open
~/dataset/sequences/00/
with Point Labeler. Run Point Labeler with:
~/catkin_ws/src/point_labeler/bin/labeler
Point Labeler generates then generates the labes in the correct semantic KITTI format.
Hi! You dont need point labeler inside a ros2 workspace. Simply follow the instructions on the kitti page for the point labeler setup.
Basically you set up a separate catking workspace for point labeler. Build it and then run the point labeler binary. Is there a specific reason why you want to build point labeler in a ros2 workspace?
Best,
Armin