Groundtruth Extractor¶
The gndtruth_extractor controller plugin doesn’t actually control the vehicle in anyway. Instead it is used as a utility to dump specified vehicle components to file.
File Type |
Output Type |
|---|---|
JSON |
“json” |
JSON.gz |
“json.gz” |
MessagePack |
“msgpack” |
MessagePack.gz |
“msgpack.gz” |
Note
The filename is taken literally, i.e., no file-extensions are added automatically.
Example¶
See the following file used in the tests: optional/vtd/tests/controller_gndtruth.json:
{
"version": "4",
"controllers": [
{
"binding": "gndtruth_extractor",
"vehicle": "default",
"args": {
"output_type": "json.gz",
"components": [
"cloe::gndtruth_lane_sensor",
"cloe::default_world_sensor",
"sysut::video_objects",
"sysut::front_radar_objects",
"sysut::rear_radar_objects"
]
}
}
]
}
Given the following configuration:
{
"components": [
"cloe::gndtruth_lane_sensor"
]
}
Then this would be the output if JSON is used:
{
"components": {
"cloe::gndtruth_lane_sensor": {
"etc": "..."
}
}
}
The content of the output depends on the YAML and the respective simulation tool and therefore is not part of this documentation.
Defaults¶
The following help can be viewed with cloe-engine usage gndtruth_extractor:
Name: gndtruth_extractor
Type: controller
Path: ~/.conan/data/cloe-plugin-gndtruth-extractor/0.23.0/cloe/develop/package/2de4bf77c73ae74c023ce41bfefbe300c8a251a4/lib/cloe/controller_gndtruth_extractor.so
Usage: {
"components": "array of string :: array of components to be extracted",
"output_file": "string :: file path to write groundtruth output to",
"output_type": "string :: type of output file to write"
}
Defaults: {
"components": [],
"output_file": "",
"output_type": "json.gz"
}
JSON Schema¶
The following can be viewed with cloe-engine usage --json gndtruth_extractor:
{
"$id": "~/.conan/data/cloe-plugin-gndtruth-extractor/0.23.0/cloe/develop/package/2de4bf77c73ae74c023ce41bfefbe300c8a251a4/lib/cloe/controller_gndtruth_extractor.so",
"$schema": "http://json-schema.org/draft-07/schema#",
"additionalProperties": false,
"description": "extracts information from the simulation",
"properties": {
"components": {
"description": "array of components to be extracted",
"items": {
"type": "string"
},
"type": "array"
},
"output_file": {
"description": "file path to write groundtruth output to",
"type": "string"
},
"output_type": {
"description": "type of output file to write",
"enum": [
"json.bz2",
"json.gz",
"json.zip",
"json",
"msgpack.bz2",
"msgpack.gz",
"msgpack.zip",
"msgpack"
],
"type": "string"
}
},
"title": "gndtruth_extractor",
"type": "object"
}