Skip to content

PRBonn/vdbfusion_ros

Repository files navigation

ROS-VDBFusion: Flexible and Efficient TSDF Integration

A ROS C++ wrapper to the vdbfusion library for flexible and efficient TSDF Integration

Installation

OpenVDB

# Install OpenVDB dependencies
sudo apt-get update && apt-get install --no-install-recommends -y \
    libblosc-dev \
    libboost-iostreams-dev \
    libboost-system-dev \
    libboost-system-dev \
    libeigen3-dev

# Install OpenVDB from source
git clone --depth 1 https://github.com/nachovizzo/openvdb.git -b nacho/vdbfusion && cd openvdb
mkdir build && cd build && cmake  -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DUSE_ZLIB=OFF .. &&  sudo make -j$(nproc) all install

VDBfusion

git clone --depth 1 https://github.com/PRBonn/vdbfusion.git && cd vdbfusion
mkdir build && cd build && cmake .. &&  sudo make -j$(nproc) all install

ROS

For now only ROS Noetic is supported.

As an extra dependency install: sudo apt install ros-noetic-tf2-sensor-msgs. On your catkin workspace, clone the vdbfusion_ros:

cd catkin_ws/src/
git clone https://github.com/PRBonn/vdbfusion_ros.git
catkin build

Usage

Configuration

  1. Create a config file compatible with your dataset and desired tsdf integration parameters using this template configuration
  2. The PointClouds should be a sensor_msgs/PointCloud2 message published on a custom topic name which needs to be specified in the config file
  3. The Transforms should be either a tf2_msgs/TFMessage or a geometry_msgs/TransformStamped. See the template configuration for more details
  4. The data can be published either through a rosbag file or directly from another ros node

Launch

roslaunch vdbfusion_ros vdbfusion.launch config_file_name:=<insert config file name here> path_to_rosbag_file:=<insert path to rosbag file here>

Save the VDB Grid and Extract Triangle Mesh

rosservice call /save_vdb_volume "path: '<insert filename and path to save the volume and mesh>'"    

Dataset Examples

Download the dataset rosbag files from the respective links

  • Convert the dataset into a rosbag file using kitti2bag
  • Use the sample config file provided for this dataset

Run the launch command providing config file and rosbag path corresponding to the dataset.

Use the rosservice to save the VDB volume and mesh

Citation

If you use this library for any academic work, please cite the original paper.

@article{vizzo2022sensors,
  author         = {Vizzo, Ignacio and Guadagnino, Tiziano and Behley, Jens and Stachniss, Cyrill},
  title          = {VDBFusion: Flexible and Efficient TSDF Integration of Range Sensor Data},
  journal        = {Sensors},
  volume         = {22},
  year           = {2022},
  number         = {3},
  article-number = {1296},
  url            = {https://www.mdpi.com/1424-8220/22/3/1296},
  issn           = {1424-8220},
  doi            = {10.3390/s22031296}
}

Others ROS wrappers around VDBFusion