Skip to main content
Version: 11.0

metrical pipeline

Purpose

  • Run a series of commands in sequence
  • Store common pipeline configurations in version control

Usage

metrical pipeline <CONFIG>

Description

Pipeline Schema

The full JSON schema for pipelines can be found in the MetriCal Sensor Calibration Utilities repository on GitLab.

A pipeline is a series of commands that are run in sequence. These commands are just modes that have been serialized into JSON and stored in a file. This allows you to store common workflows in version control and run them with a single command.

Here's an example of a pipeline configuration file:

{
"commands": [
{
"init": {
"input_data_path": "fixtures/data_as.bag",
"output_json": "/tmp/dummy_output_config.json",
"plex_path": null,
"preset_device": [],
"topic_to_model": [
["*cam*", "opencv_radtan"],
["*lidar*", "no_offset"]
]
}
},
{
"calibrate": {
"cache_dir": "cached_data",
"cache_filtered_data": false,
"disable_filter": false,
"disable_ore_inference": false,
"input_data_path": "fixtures/data_as.bag",
"is_interactive": false,
"max_iterations": 200,
"object_space_path": "fixtures/obj.json",
"output_json": "results.json",
"plex_path": "fixtures/plex.json",
"preserve_input_constraints": false,
"render_socket": null,
"should_render": false,
"stillness_threshold": 1,
"topic_to_component": []
}
}
],
"license": null,
"report_path": null
}

As you can see, it's just the CLI arguments for each mode serialized into JSON! Pretty easy, huh? And no, you can't have a pipeline for your pipeline; pipeline is the only command that isn't serialized. Sorry, all you recursion fans.

Note that commands will be run in the order they are listed in the commands array. A failed command will stop the entire pipeline and return the error.

Arguments

<CONFIG>

The configuration file describing the pipeline.

Examples

1. Run a pipeline

metrical pipeline my_pipeline.json