Skip to content

CLI

CamCalib installs a single entry point, camcalib, with seven subcommands. Everything is config-driven — flags select what to run, the YAML says how.

Terminal window
camcalib --help
SubcommandPurpose
calibrateRun calibration
camCamera-only calibration from a CamRunConfig YAML
cam-imuJoint camera–IMU calibration
apply-calibApply a calibration to a raw bag → corrected bag
roundtripcalibrate → apply-calib → recalibrate → PASS/FAIL report
runRun calibration, dispatching on the config type
analyzeAnalyse calibration results

Camera calibration from a config file.

Terminal window
camcalib calibrate --config config.yaml
FlagDescription
--config, -cPath to the calibration config YAML

Config schema: Configuration.

Camera-only calibration driven by a CamRunConfig YAML — the run-oriented variant, used by the batch and regression harnesses.

Terminal window
camcalib cam --config example_cam_run.yaml
FlagDescription
--config, -cPath to the CamRunConfig YAML

Joint camera–IMU calibration: extrinsics T_CtoI, time offset td, rolling-shutter readout, IMU intrinsics, and biases.

Terminal window
camcalib cam-imu --config cam_imu.yaml
FlagDescription
--config, -cPath to the cam-IMU config YAML
--bagOverride the input bag from the config

List several sequences under input.bags and each is calibrated into its own discoverable bag<NN>/cam_imu.json — a whole dataset family from one config. See Camera–IMU calibration.

Apply a saved cam-IMU calibration back onto a raw ROS1 bag and re-record it calibration-corrected.

Terminal window
camcalib apply-calib -c recalib.yaml
camcalib apply-calib --calib cam_imu.json --in raw.bag --out corrected.bag
FlagDescription
-c, --configConfig bundling calib / input / output
--calibCalibration result to apply
--inRaw input bag
--outOutput bag; defaults to <bag>.corrected.bag
--mapExplicit topic→sensor map. Rarely needed — the calib records each sensor’s source topic, so the mapping is auto-derived
--keep-biasDo not remove the static bias
--undistortAlso undistort images

What it corrects and why: Corrected-dataset export.

End-to-end validation: calibrate, apply the calibration to its own bag, recalibrate the corrected bag, and report PASS/FAIL. Exits non-zero on FAIL, so it works in CI.

Terminal window
camcalib roundtrip -c cam_imu.yaml
FlagDescription
-c, --configCam-IMU config to validate
--outReport output path
--bagOverride the input bag
--keep-correctedKeep the corrected bag (auto-deleted otherwise)
--keep-biasPass through to apply-calib

What PASS means: Round-trip validation.

Runs a calibration, dispatching on the config type so you do not have to pick the subcommand yourself.

Terminal window
camcalib run --config any_config.yaml
FlagDescription
--config, -cAny CamCalib config

Analyse existing calibration results.

Terminal window
camcalib analyze --results results/regression/dataset/run/
FlagDescription
--results, -rResults directory to analyse

Not subcommands, but part of the everyday surface:

ScriptPurpose
scripts/run_regression_tests.pyManifest-driven batch runner. --level benchmark --parallel 8, --only <dataset>
scripts/run_quick_regression.pySix-run subset, roughly ten minutes
scripts/compare_baseline.pyCompare current results against a saved baseline
scripts/save_baseline.pySave a new baseline, with a comparison report
scripts/visualize_result.pyPost-hoc Rerun 3D viewer for a result directory
python -m camcalib.analysis.regenerate_htmlRebuild HTML reports from saved YAML + detection cache
studies/calib_video_real.pyRender a calibration MP4 (--sim, --recover, --rig-view)

More detail in Evaluation & metrics.