Benchmarking toolset that can plot trajectories and compute metrics such as RMSE for VISLAM algorithms.
Spectacular AI recordings (format documented here) can include both the recording-time VISLAM output poses and reference/ground-truth tracks in data.jsonl.
Place the recording folders in a common folder, say sessions/, for example like this:
sessions
├── session01
│ ├── vio_config.yaml
│ ├── calibration.json
│ ├── data.jsonl
│ └── data.mkv
└── session02
├── vio_config.yaml
├── calibration.json
├── data.jsonl
└── data.mkv
Benchmark by running:
pip install numpy scipy matplotlib
python run.py -dataDir sessions -useRecordingOutput -metricSet globalThe results and plots are created under output/<timestamp>/:
figures-global.png: Plots the VISLAMglobalPoseand reference/ground-truth trajectories in local ENU (East-North-Up) coordinates in meters.metrics.jsonandinfo.json:metrics.jsoncontains the computed metrics for each session andinfo.jsoncontains run metadata and aggregate metrics averaged across sessions. Position errors are reported in meters:RMSE,MAE,median,p95,max, anddrift(end-point error).
See all available options and metric sets with python run.py --help.
Precomputed VISLAM output trajectories and ground truth poses can also be placed in separate output.jsonl and groundtruth.jsonl files in each session folder. An example dataset is included in examples/two_sessions:
python run.py -dataDir examples/two_sessions -metricSet globalThe run.py script can also compute output trajectories by replaying recorded sensor data using the public Spectacular AI SDK:
pip install spectacularAI numpy scipy matplotlib
python run.py -dataDir sessions -metricSet globalShared vio_config.yaml and calibration.json files can also be placed in the parent sessions/ folder instead of individual session folders.
Different metric sets can be selected with -metricSet (multiple sets can be separated by commas):
global: Compares VISLAMglobalPoseoutputs and reference tracks in WGS84 coordinates (converted to local ENU coordinates) directly without aligning the trajectories.full: Compares local VISLAMpositionoutputs against reference tracks after aligning the trajectories by translation and rotation around the z-axis (gravity direction).
Based on https://github.com/AaltoML/vio_benchmark.
This repository is licensed under Apache 2.0 (see LICENSE).