Gazebo | Ignition | Community
Ask Your Question

What is the best way to record "ground truth" data during a simulation?

asked 2021-12-07 15:52:11 -0600

shonigmann gravatar image

What is the best way to record "ground truth" data during a simulation at each simulation timestep, ideally in an "exportable" format like .csv? Is there a generic approach that would work across different variables of interest (model pose, velocity, accelerations, joint states, contact forces/torques), or would each type of value require individual instrumentation/configuration?

All of the methods I've found have fallen a bit short of my expectations.

  • The record logging utility works reasonably well, and can be started/stopped from the command line which is nice, but I've only been able to get pose data (issue here)
  • Gazebo's plotting utility has a nice intuitive interface and can export data in a .csv format, but to my knowledge doesn't have a programmatic interface for more systematic data collection, and appears to be limited to 10s of data
  • Gazebo ROS Plugins offer a number of sensor plugins (GPS, Force Torque, Joint State) that can monitor different aspects of the states of models, which could then be monitored and compiled into a data log (perhaps using something like plot juggler), but each model needs to be configured manually with multiple plugins before starting, and I'm not sure how "lock-step" the data published to ROS would be with the simulation.

Am I missing anything obvious? I feel like this should be pretty common functionality, so I am surprised that I haven't found a good existing approach. Thanks!

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted

answered 2021-12-14 15:41:26 -0600

shonigmann gravatar image

I didn't end up finding any existing functionality that did what I needed, so I ended up biting the bullet and making a plugin that logs the state information of selected joints and links to a .csv file. The plugin can be found on github, here in case anyone else needs similar functionality in the future.

edit flag offensive delete link more
Login/Signup to Answer

Question Tools



Asked: 2021-12-07 15:52:11 -0600

Seen: 247 times

Last updated: Dec 14 '21