0
$\begingroup$

Rosanswers logo

What tools have people developed and use for rosbag analysis?

I know of rqt_bag (which is an absolutely awesome tool), which allows you to browse the topics in a concise timeline, and using that in conjunction with rqt_plot to plot data. However, it's still a little cumbersome to extract data for more detailed analysis.

I've created a small package using numpy that will parse a rosbag given a set of topic paths (consisting of fields and optionally indices, much like extracting data for plotting) and return simple multi-variable data sets for ease of plotting and analysis, which includes interpolating data sets so that they are on a time scale (with the same spacing). This allows basic errors to be computed. If you also published the same data, you can use this to potentially see delays between the different publishers. You can always run the conversion, then save the final datasets to Matlab to plot and examine as well. Really easy to do in Spyder.

Will upload the package in a bit.

EDIT: Googled and saw Pandas from this presentation: https://speakerdeck.com/nzjrs/managing-complex-experiments-automation-and-analysis-using-robot-operating-system Looks interesting, will start looking at this.


Originally posted by eacousineau on ROS Answers with karma: 174 on 2013-10-16

Post score: 3

$\endgroup$

2 Answers 2

0
$\begingroup$

Rosanswers logo

If you are interested in using pandas. I have a simple somewhat inefficient python package to get a bag file into a pandas dataframe indexed by the bag record time.

https://github.com/aktaylor08/ros_pandas


Originally posted by aktaylor08 with karma: 56 on 2014-06-13

This answer was ACCEPTED on the original site

Post score: 4


Original comments

Comment by eacousineau on 2014-06-18:
Thanks! I'll check that out.

Comment by xaedes on 2014-09-19:
This is awesome. To get a dataframe with a common time index (no interleaved data) use this on top of ros_pandas: http://pastebin.com/hJFR7HbA

$\endgroup$
0
$\begingroup$

Rosanswers logo

I think you bring up a good point that there isn't really a centralized place to find out about working with recorded data. There are of course the wiki pages for rqt_bag/rqt_plot/rosbag, but those are specific to those tools. For example, I needed to export video from a bag and the relevant wiki page wasn't sufficient, so I had to write my own tool to export variable framerate video (https://github.com/OSUrobotics/bag2video). I bet somebody else has already done this, but couldn't find anything. Countless times, I've also had to write one-off scripts to export data as mat files.

Anyway, a wiki page with a more comprehensive list of tools for working with recorded data could be very useful.


Originally posted by Dan Lazewatsky with karma: 9115 on 2013-10-16

This answer was NOT ACCEPTED on the original site

Post score: 1

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.