Why does rqt_bag often fail to plot data?
Rosbag and rqt_bag are fantastic diagnostic tools. But I've found that the plotting function in rqt_bag is unbelievably buggy. Roughly 60% of the time, the data simply doesn't show up when I try to plot it, for example:
Notice that the "altitude" variable is ticked, yet nothing is being displayed on the plot. The plotting function can mess up in other ways too, e.g.
- The data may plot correctly but the red line indicating the position in the rosbag file will freeze or disappear altogther
- The whole plot may freeze, even the raw numbers in the window to the right of the plot
- The plot itself may experience a graphical glitch where two plots overlap slightly (I haven't been able to re-create this one sorry)
These problems are very inconsistent - sometimes restarting rqt_bag makes the plot display properly and sometimes it doesn't. Like I said, any given time I start rqt_bag there is only a 40% chance of everything displaying properly, regardless of which rosbag file I am trying to play. Often when rqt_bag bugs out, a few error messages get printed to terminal, here are some of them:
- Error message after plot data doesn't appear
- Different error message after plot data doesn't appear
- Error 2
- Error message after plotting plugin freezes completely
- Error message after trying to plot latitude (NavSatFix msg)
Has anyone else experienced this or know how to fix it? I'm not sure if this is a bug, corruption in the rosbag file or something I've unknowingly done to mess up the plugin.
Here is a link to one of the bags I'm using: https://www.dropbox.com/s/qmwyrmg13zj... If no-one else experiences the same behavior then my problem is likely to do with my setup.
I haven't had most of these issues but I also wrote most of the rqt_bag plot plugin, so I'm more prone to look past its faults. If you can provide a bag file that replicates these issues I can try to reproduce them.
Unfortunately these errors occur regardless of the file I'm trying to play, which makes me think that it's something to do with my setup. I've edited my question to add some of the error messages I've seen. Hopefully they'll mean more to you than they do to me. I'll keep investigating the problem.
I've tried this with a few bag files that I had around and can't reproduce the error you describe.
What's the best way for me to send you a bag file? if it works fine for you then we can at least rule out the bag files being the cause of the problem. Also see if the error messages I'm adding mean anything to you. And thanks for the help ahendrix, I really appreciate it.
If you don't want to attach bag files to this question, you can email them to me: namniart@gmail.com (or upload them somewhere and email a link)
Attaching a file doesn't seem to be working for me so I've added a link to one of the bag files I'm using in the question.
I'm able to reproduce a few of the issues you describe if I play back a bag file and toggle the plot on or off at the same time. I suspect some kind of threading bug in rqt_bag
Do you see these problems with the bag file I linked to in the question or your own? It may be related to the volume of data I'm dealing with. I've noticed that rqt_bag becomes much less responsive when I'm playing large bag files (100+ MB, 30+ min)