Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

All the script rely on the class DebugData in "scripts/util/parser.py". This design makes it easy to make adjustments in case the file format changes. However, if you modify the internal data structure of DebugData (e.g. change the name of one of its member variables) you will have to modify the scripts that access to that data. Check the class documentation in the code for more information. Note that DebugData can be used to parse only the debug file produced by ca2, not the one written by the simulator.

...

  1. Open "plot_trajectory.py".
  2. Use your editor's search feature (usually CTRL+F) to find the string "TODO". You should find a code section titled "TODO configure which info to plot".
  3. Assign to variables graphX_vals the arrays containing the info you want to be plotted. The array will likely be a member variable of the class DebugData defined in "scripts/util/parser.py" or one of the *_*sim_vals arrays defined inside plot_trajectory.py that represent the data extracted from the simulator debug file. Check the code documentation in DebugData and plot_trajectory.py (section "SIMULATOR DEBUG VARIABLES") for details. Of course you can print another array-like structure as long as it as the same length of lab_data.time.

The little red crosses show the value of the specified attribute at the current step.

...