Ask Your Question

How to export key frames and camera poses using RTABMAP automatically

asked 2018-02-08 03:12:04 -0500

Cole gravatar image


I am using RTABMAP for 3D mapping. But I need to write shell script to run the SLAM and export key frame images and poses. Is there any method to export them without using mouse click operation at the window?

Thanks ahead.

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted

answered 2018-02-09 16:12:58 -0500

matlabbe gravatar image

With ROS, you may create a node calling service /rtabmap/get_map_data (with parameters global:=true, optimized:=true and graphOnly:=false) to get the full map with image data rtabmap_ros/MapData. The graph will have all the optimized poses and nodes contain data for each node in the graph, including compressed images. The images were compressed using OpenCV cv::imencode(), so they can be decompressed using cv::imdecode() (it may also work in OpenCV Python).

For the standalone, if you are processing a directory of images, you may look at the console tool rtabmap-rgbd_dataset for example. The poses are exported in this example at the end. To extract images, we would have to modify the code to iterate over the signatures and get the compressed images.


edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools


Asked: 2018-02-08 03:12:04 -0500

Seen: 370 times

Last updated: Feb 09 '18