ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
0

Extract single message from large rosbag

asked 2023-05-11 03:38:17 -0500

lio94 gravatar image

Hi,

I have a rosbag collected from a SLAM algo that I left to run overnight, which publishes an incrementally updated map as a PointCloud2 message.

I would like to extract only the last message (final map), so that I can convert it to a PCD file with pcl_ros.

I find myself unable to find a way to perform such a simple operation.

Any tips?

edit retag flag offensive close merge delete

2 Answers

Sort by ยป oldest newest most voted
0

answered 2023-06-27 20:59:22 -0500

The diagnostic_analysis package can convert a log of diagnostics data into a series of CSV files. Robot logs are recorded with rosbag, and can be processed offline using the scripts in this package.

edit flag offensive delete link more
0

answered 2023-05-11 04:04:48 -0500

Hamid Didari gravatar image

You can write a Python scrip to extract msgs from a rosbag.

https://wiki.ros.org/rosbag/Code%20API

edit flag offensive delete link more

Question Tools

1 follower

Stats

Asked: 2023-05-11 03:38:17 -0500

Seen: 61 times

Last updated: May 11 '23