Read-only mirror of https://github.com/ethz-asl/deeplab_ros — ETHZ ASL. Issues & pull requests at the source.
  • Python 94.5%
  • CMake 4%
  • Shell 1.5%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Margarita Grinvald 2a6f55dd4c
Update README.md
2020-05-22 17:22:09 +02:00
bags Added ROS node, sample launch file. 2019-05-17 16:46:57 +02:00
cfg Added ROS node, sample launch file. 2019-05-17 16:46:57 +02:00
doc Upload gif 2019-05-20 12:53:26 +02:00
launch Added ROS node, sample launch file. 2019-05-17 16:46:57 +02:00
nodes Update nodes/deeplab_ros_node.py 2020-04-17 19:29:23 -04:00
rviz Added ROS node, sample launch file. 2019-05-17 16:46:57 +02:00
scripts Added ROS node, sample launch file. 2019-05-17 16:46:57 +02:00
src/deeplab_ros Initial commit 2018-12-03 14:48:52 +01:00
.gitignore Added ROS node, sample launch file. 2019-05-17 16:46:57 +02:00
CMakeLists.txt Added ROS node, sample launch file. 2019-05-17 16:46:57 +02:00
package.xml * Switching to cv2for image resize to reduce cpu util 2020-03-30 22:36:01 -04:00
README.md Update README.md 2020-05-22 17:22:09 +02:00
setup.py Initial commit 2018-12-03 14:48:52 +01:00

ROS Wrapper for DeepLab

This is a package for using DeepLab models with ROS. DeepLab is a state-of-the-art deep learning architecture for semantic image segmentation, where the goal is to assign semantic labels (e.g., person, dog, cat and so on) to every pixel in the input image. For more information about DeepLab, please visit this link.

Code for running inference is based on the following Colab notebook.

Citing

If you use the code for your research, please cite this work as:

@misc{grinvald2018deeplabros,  
  author={Margarita Grinvald},
  title={ROS Wrapper for DeepLab},
  year={2018}
  publisher = {GitHub},
  journal = {GitHub repository},
  howpublished = {\url{https://github.com/ethz-asl/deeplab_ros}},
}

Getting started

Clone this repository to the src folder of your catkin workspace, build your workspace and source it.

cd <catkin_ws>/src
git clone git@github.com:ethz-asl/deeplab_ros.git
catkin build
source <catkin_ws>/devel/setup.bash

Example usage

An example launch file is included processing a sequence from the Freiburg RGB-D SLAM Dataset.

cd <catkin_ws>/src/deeplab_ros
chmod +x scripts/download_freiburg_rgbd_example_bag.sh 
scripts/download_freiburg_rgbd_example_bag.sh
roslaunch deeplab_ros freiburg.launch

ROS node

Parameters:

  • ~rgb_input [string]

    Topic name of the input RGB stream.

    Default: "/camera/rgb/image_color"

  • ~model [string]

    Name of the backbone network used for inference. List of available models: {"mobilenetv2_coco_voctrainaug", "mobilenetv2_coco_voctrainval", "xception_coco_voctrainaug", "xception_coco_voctrainval"}. If the specified model file doesn't exist, the node automatically downloads the file.

    Default: "mobilenetv2_coco_voctrainaug"

  • ~visualize [bool]

    If true, the segmentation result overlaid on top of the input RGB image is published to the ~segmentation_viz topic.

    Default: true

Topics subscribed:

  • topic name specified by parameter ~rgb_input (default: /camera/rgb/image_color) [sensor_mgs/Image]

    Input RGB image to be processed.

Topics published:

  • ~segmentation [sensor_mgs/Image]

    Segmentation result.

  • ~segmentation_viz [sensor_mgs/Image]

    Visualization-friendly segmentation result color coded with the PASCAL VOC 2012 color map overlaid on top of the input RGB image.