-
Notifications
You must be signed in to change notification settings - Fork 668
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor(multi_object_tracker): rework parameters (#7333)
* Refractored the parameters, build the schema file, updated the readme file. Signed-off-by: Boyang <[email protected]> * style(pre-commit): autofix --------- Signed-off-by: Boyang <[email protected]> Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
- Loading branch information
1 parent
0c4db04
commit d5c95ae
Showing
5 changed files
with
339 additions
and
32 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
74 changes: 74 additions & 0 deletions
74
perception/multi_object_tracker/schema/data_association_matrix.schema.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,74 @@ | ||
{ | ||
"$schema": "http://json-schema.org/draft-07/schema#", | ||
"title": "Parameters for Data Association Matrix", | ||
"type": "object", | ||
"definitions": { | ||
"data_association_matrix": { | ||
"type": "object", | ||
"properties": { | ||
"can_assign_matrix": { | ||
"type": "array", | ||
"description": "Assignment table for data association.", | ||
"items": { | ||
"type": "integer" | ||
} | ||
}, | ||
"max_dist_matrix": { | ||
"type": "array", | ||
"description": "Maximum distance table for data association.", | ||
"items": { | ||
"type": "number" | ||
} | ||
}, | ||
"max_area_matrix": { | ||
"type": "array", | ||
"description": "Maximum area table for data association.", | ||
"items": { | ||
"type": "number" | ||
} | ||
}, | ||
"min_area_matrix": { | ||
"type": "array", | ||
"description": "Minimum area table for data association.", | ||
"items": { | ||
"type": "number" | ||
} | ||
}, | ||
"max_rad_matrix": { | ||
"type": "array", | ||
"description": "Maximum angle table for data association.", | ||
"items": { | ||
"type": "number" | ||
} | ||
}, | ||
"min_iou_matrix": { | ||
"type": "array", | ||
"description": "A matrix that represents the minimum Intersection over Union (IoU) limit allowed for assignment.", | ||
"items": { | ||
"type": "number" | ||
} | ||
} | ||
}, | ||
"required": [ | ||
"can_assign_matrix", | ||
"max_dist_matrix", | ||
"max_area_matrix", | ||
"min_area_matrix", | ||
"max_rad_matrix", | ||
"min_iou_matrix" | ||
] | ||
} | ||
}, | ||
"properties": { | ||
"/**": { | ||
"type": "object", | ||
"properties": { | ||
"ros__parameters": { | ||
"$ref": "#/definitions/data_association_matrix" | ||
} | ||
}, | ||
"required": ["ros__parameters"] | ||
} | ||
}, | ||
"required": ["/**"] | ||
} |
80 changes: 80 additions & 0 deletions
80
perception/multi_object_tracker/schema/input_channels.schema.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,80 @@ | ||
{ | ||
"$schema": "http://json-schema.org/draft-07/schema#", | ||
"title": "Parameters for Input Channels", | ||
"type": "object", | ||
"definitions": { | ||
"input_channel": { | ||
"type": "object", | ||
"properties": { | ||
"topic": { | ||
"type": "string", | ||
"description": "The ROS topic name for the input channel." | ||
}, | ||
"can_spawn_new_tracker": { | ||
"type": "boolean", | ||
"description": "Indicates if the input channel can spawn new trackers." | ||
}, | ||
"optional": { | ||
"type": "object", | ||
"properties": { | ||
"name": { | ||
"type": "string", | ||
"description": "The name of the input channel." | ||
}, | ||
"short_name": { | ||
"type": "string", | ||
"description": "The short name of the input channel." | ||
} | ||
} | ||
} | ||
}, | ||
"required": ["topic", "can_spawn_new_tracker"] | ||
} | ||
}, | ||
"properties": { | ||
"/**": { | ||
"type": "object", | ||
"properties": { | ||
"ros__parameters": { | ||
"type": "object", | ||
"properties": { | ||
"input_channels": { | ||
"type": "object", | ||
"properties": { | ||
"detected_objects": { "$ref": "#/definitions/input_channel" }, | ||
"lidar_clustering": { "$ref": "#/definitions/input_channel" }, | ||
"lidar_centerpoint": { "$ref": "#/definitions/input_channel" }, | ||
"lidar_centerpoint_validated": { "$ref": "#/definitions/input_channel" }, | ||
"lidar_apollo": { "$ref": "#/definitions/input_channel" }, | ||
"lidar_apollo_validated": { "$ref": "#/definitions/input_channel" }, | ||
"lidar_pointpainitng": { "$ref": "#/definitions/input_channel" }, | ||
"lidar_pointpainting_validated": { "$ref": "#/definitions/input_channel" }, | ||
"camera_lidar_fusion": { "$ref": "#/definitions/input_channel" }, | ||
"detection_by_tracker": { "$ref": "#/definitions/input_channel" }, | ||
"radar": { "$ref": "#/definitions/input_channel" }, | ||
"radar_far": { "$ref": "#/definitions/input_channel" } | ||
}, | ||
"required": [ | ||
"detected_objects", | ||
"lidar_clustering", | ||
"lidar_centerpoint", | ||
"lidar_centerpoint_validated", | ||
"lidar_apollo", | ||
"lidar_apollo_validated", | ||
"lidar_pointpainitng", | ||
"lidar_pointpainting_validated", | ||
"camera_lidar_fusion", | ||
"detection_by_tracker", | ||
"radar", | ||
"radar_far" | ||
] | ||
} | ||
}, | ||
"required": ["input_channels"] | ||
} | ||
}, | ||
"required": ["ros__parameters"] | ||
} | ||
}, | ||
"required": ["/**"] | ||
} |
116 changes: 116 additions & 0 deletions
116
perception/multi_object_tracker/schema/multi_object_tracker_node.schema.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,116 @@ | ||
{ | ||
"$schema": "http://json-schema.org/draft-07/schema#", | ||
"title": "Parameters for Multi Object Tracker Node", | ||
"type": "object", | ||
"definitions": { | ||
"multi_object_tracker_node": { | ||
"type": "object", | ||
"properties": { | ||
"car_tracker": { | ||
"type": "string", | ||
"description": "Tracker model for car class.", | ||
"default": "multi_vehicle_tracker" | ||
}, | ||
"truck_tracker": { | ||
"type": "string", | ||
"description": "Tracker model for truck class.", | ||
"default": "multi_vehicle_tracker" | ||
}, | ||
"bus_tracker": { | ||
"type": "string", | ||
"description": "Tracker model for bus class.", | ||
"default": "multi_vehicle_tracker" | ||
}, | ||
"trailer_tracker": { | ||
"type": "string", | ||
"description": "Tracker model for trailer class.", | ||
"default": "multi_vehicle_tracker" | ||
}, | ||
"pedestrian_tracker": { | ||
"type": "string", | ||
"description": "Tracker model for pedestrian class.", | ||
"default": "pedestrian_and_bicycle_tracker" | ||
}, | ||
"bicycle_tracker": { | ||
"type": "string", | ||
"description": "Tracker model for bicycle class.", | ||
"default": "pedestrian_and_bicycle_tracker" | ||
}, | ||
"motorcycle_tracker": { | ||
"type": "string", | ||
"description": "Tracker model for motorcycle class.", | ||
"default": "pedestrian_and_bicycle_tracker" | ||
}, | ||
"publish_rate": { | ||
"type": "number", | ||
"description": "Timer frequency to output with delay compensation.", | ||
"default": 10.0 | ||
}, | ||
"world_frame_id": { | ||
"type": "string", | ||
"description": "Object kinematics definition frame.", | ||
"default": "map" | ||
}, | ||
"enable_delay_compensation": { | ||
"type": "boolean", | ||
"description": "If True, tracker use timers to schedule publishers and use prediction step to extrapolate object state at desired timestamp.", | ||
"default": false | ||
}, | ||
"publish_processing_time": { | ||
"type": "boolean", | ||
"description": "Enable to publish debug message of process time information.", | ||
"default": false | ||
}, | ||
"publish_tentative_objects": { | ||
"type": "boolean", | ||
"description": "Enable to publish tentative tracked objects, which have lower confidence.", | ||
"default": false | ||
}, | ||
"publish_debug_markers": { | ||
"type": "boolean", | ||
"description": "Enable to publish debug markers, which indicates association of multi-inputs, existence probability of each detection.", | ||
"default": false | ||
}, | ||
"diagnostics_warn_delay": { | ||
"type": "number", | ||
"description": "Delay threshold for warning diagnostics in seconds.", | ||
"default": 0.5 | ||
}, | ||
"diagnostics_error_delay": { | ||
"type": "number", | ||
"description": "Delay threshold for error diagnostics in seconds.", | ||
"default": 1.0 | ||
} | ||
}, | ||
"required": [ | ||
"car_tracker", | ||
"truck_tracker", | ||
"bus_tracker", | ||
"trailer_tracker", | ||
"pedestrian_tracker", | ||
"bicycle_tracker", | ||
"motorcycle_tracker", | ||
"publish_rate", | ||
"world_frame_id", | ||
"enable_delay_compensation", | ||
"publish_processing_time", | ||
"publish_tentative_objects", | ||
"publish_debug_markers", | ||
"diagnostics_warn_delay", | ||
"diagnostics_error_delay" | ||
] | ||
} | ||
}, | ||
"properties": { | ||
"/**": { | ||
"type": "object", | ||
"properties": { | ||
"ros__parameters": { | ||
"$ref": "#/definitions/multi_object_tracker_node" | ||
} | ||
}, | ||
"required": ["ros__parameters"] | ||
} | ||
}, | ||
"required": ["/**"] | ||
} |
62 changes: 62 additions & 0 deletions
62
perception/multi_object_tracker/schema/simulation_tracker.schema.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
{ | ||
"$schema": "http://json-schema.org/draft-07/schema#", | ||
"title": "Parameters for Simulation Tracker Node", | ||
"type": "object", | ||
"definitions": { | ||
"simulation_tracker_node": { | ||
"type": "object", | ||
"properties": { | ||
"car_tracker": { | ||
"type": "string", | ||
"description": "Tracker model for car class.", | ||
"default": "pass_through_tracker" | ||
}, | ||
"truck_tracker": { | ||
"type": "string", | ||
"description": "Tracker model for truck class.", | ||
"default": "pass_through_tracker" | ||
}, | ||
"bus_tracker": { | ||
"type": "string", | ||
"description": "Tracker model for bus class.", | ||
"default": "pass_through_tracker" | ||
}, | ||
"pedestrian_tracker": { | ||
"type": "string", | ||
"description": "Tracker model for pedestrian class.", | ||
"default": "pass_through_tracker" | ||
}, | ||
"bicycle_tracker": { | ||
"type": "string", | ||
"description": "Tracker model for bicycle class.", | ||
"default": "pass_through_tracker" | ||
}, | ||
"motorcycle_tracker": { | ||
"type": "string", | ||
"description": "Tracker model for motorcycle class.", | ||
"default": "pass_through_tracker" | ||
} | ||
}, | ||
"required": [ | ||
"car_tracker", | ||
"truck_tracker", | ||
"bus_tracker", | ||
"pedestrian_tracker", | ||
"bicycle_tracker", | ||
"motorcycle_tracker" | ||
] | ||
} | ||
}, | ||
"properties": { | ||
"/**": { | ||
"type": "object", | ||
"properties": { | ||
"ros__parameters": { | ||
"$ref": "#/definitions/simulation_tracker_node" | ||
} | ||
}, | ||
"required": ["ros__parameters"] | ||
} | ||
}, | ||
"required": ["/**"] | ||
} |