ROS2Logger is a custom ROS 2 logging utility that makes structured experiment logging painless.
- Create a ROS 2 workspace with a
src/directory. - Clone
ROS2Loggerandtest_loggerrepos intosrc/:git clone git@github.com:evannsm/ROS2Logger.git git clone git@github.com:evannsm/test_logger.git
- Build the workspace (symbolic links preferred):
colcon build --symlink-install
- Run
test_loggerto see ROS2Logger in action!ros2 run test_logger test_logger --log-file logX.log
- Custom log data types
- Append values like a list
- Supports scalar sequences and sequences of vectors
- Automatic shutdown hooks
- On node exit (normal or error), automatically collects all log-type variables from your node
- Column ordering
- Columns in the log file are sorted by:
- Your provided ordering integer
- Alphabetical order (for ties)
- Columns in the log file are sorted by:
- Data directory creation
- Creates a
/data_analysisfolder alongside the ROS 2 node that invoked the logger
- Creates a
- Built-in analysis tools
- Populates
/data_analysiswith:DataAnalysis.ipynbnotebook (and autilities.pymodule) containing:- RMSE computation
- Plotting utilities
- PDF export for Overleaf/LaTeX
/data_analysis/log_filessubdirectory for logs
- Populates
Note:
By default, the logger requirestime,x,y,z, andyawto be present to ensure minimum dataset completeness for quadrotor experiments.
You can modify this requirement in the code.