项目作者: xmba15

项目描述 :
ROS package for stereo matching and point cloud projection using AANet (Adaptive Aggregation Network for Efficient Stereo Matching, CVPR 2020)
高级语言: Python
项目地址: git://github.com/xmba15/aanet_stereo_matching_ros.git
创建时间: 2020-08-24T16:09:19Z
项目社区:https://github.com/xmba15/aanet_stereo_matching_ros

开源协议:

下载


📝 aanet_stereo_matching_ros


ROS package for stereo matching and point cloud projection using AANet

:tada: TODO


  • create ros nodes to get disparity map from stereo matching with AANet
  • create pseudo-lidar point cloud from disparity map with camera info

🎛 Dependencies


  • create stereo_matching conda environment

    1. conda env create --file environment.yml
  • Fetch AANet

    1. git submodule update --init --recursive
  • Activate conda environment and build deformable convolution for aanet

    1. conda activate stereo_matching
    2. cd ./scripts/aanet/nets/deform_conv && bash build.sh
  • python3: this package (also the original implementation) uses python3, which is taboo for ROS1. One solution to avoid confliction between ROS1 and python3 is to run roslaunch under the directory with stereo_matching env activated.

🔨 How to Build


Better to build with catkin or colcon
Before building with ROS build tool, config current ROS workspace to use python in stereo_matching conda environment with

  1. catkin config -DPYTHON_EXECUTABLE=`which python` -DPYTHON_INCLUDE_DIR=`python -c "from __future__ import print_function; from distutils.sysconfig import get_python_inc; print(get_python_inc())"` -DPYTHON_LIBRARY=`python -c "from __future__ import print_function; import distutils.sysconfig as sysconfig; print(sysconfig.get_config_var('LIBDIR') + '/' + sysconfig.get_config_var('LDLIBRARY'))"`
  2. catkin build

:running: How to Run


  • A sample rosbag of stereo images created from DrivingStereo Dataset with this tool has been prepared HERE. Please download and extract into ./data/output.bag

  • Download AANet+ KITTI 2015 model from MODEL ZOO and put into ./data/aanet+_kitti15-2075aea1.pth

  • Start sample roslaunch

    1. roslaunch aanet_stereo_matching_ros aanet_stereo_matching_ros_rviz_sample.launch

Please take a look at the sample roslaunch to know how to use the parameters.
Tune img_scale with bigger value (1.0 means original image size) would yeild better point cloud at the cost of speed. Currently the perspective projection from disparity to point cloud in python seems costly. Might be better to just propagate disparity message and do the projection in C++ package.

aanet_sample

:gem: References