furushchev / gpu_stereo_image_proc

Stereo and image rectification and disparity processing with NVIDIA VisionWorks and fixstars libSGM

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

gpu_stereo_image_proc CircleCI

Overview

This package provides ROS wrapper for CUDA implementations of Semi-Global (Block) Matching (i.e. SGM or SGBM). This package currently supports Fixstars libSGM and NVIDIA VisionWorks as stereo-matching engine.

Requirement

Installation

Only "Build from Source" option is provided. Simply pull the source and build the package on your machine.

cd <path-to-your-catkin-workspace>/src
git clone https://github.com/WHILL/gpu_stereo_image_proc.git
cd ..
catkin_make
# Note: libSGM is automatically pulled to gpu_stereo_image_proc/libSGM as CMake's external project.

If you want to build this package on a machine which does not have any GPU, CMake would not be able to detect CUDA architecture and build may fail. In this case, you can specify CUDA architecture by providing build options.

catkin_make -DAUTO_DETECT_ARCH=OFF -DCUDA_ARCH="<your-selection>"
# e.g. -DCUDA_ARCH="-arch=sm_72" for Jetson Xavier

Usage

Basic Usage

Basic usage of this package (e.g. subscribed/published topics, node structure) is compatible with ros-perception/image_pipeline/stereo_image_proc. Refer to its wiki for quick start.

Nodelets

This package contains nodelets for creating disparity images from stereo.

gpu_stereo_image_proc/libsgm_disparity

Nodelet which wraps Fixstars libSGM.

gpu_stereo_image_proc/vx_disparity

Nodelet which wraps NVIDIA VisionWorks.

Parameters

Most of the parameters can be configured via dynamic reconfigure. These wiki pages describes configurable parameters.

Example: Compare disparity calculation results

This package provides an example launch file which enables you to see difference of three stereo-mathing implementations: OpenCV (CPU), libSGM (GPU) and VisionWorks (GPU).

# Launch your stereo camera
# Launch your nodelet manager
rosrun nodelet nodelet manager __name:=manager # Note that manager must be located in global namespace

# Launch image processing nodelets
roslaunch gpu_stereo_image_proc comparison.launch manager:=/manager __ns:=<namespace-of-your-camera> # Don't forget '/' before manager's name.

Note: disparity and points2 topics are remapped with libsgm_ prefix (libSGM) and vx_ prefix (VisionWorks).

Demo Video

See https://youtu.be/whCAjrDg9_A

Licenses

About

Stereo and image rectification and disparity processing with NVIDIA VisionWorks and fixstars libSGM

License:BSD 3-Clause "New" or "Revised" License


Languages

Language:C++ 89.2%Language:Python 6.3%Language:CMake 4.5%