Skip to content

Commit beb0ed7

Browse files
tby-udelpre-commit-ci[bot]
authored andcommitted
refactor(multi_object_tracker): rework parameters (autowarefoundation#7333)
* Refractored the parameters, build the schema file, updated the readme file. Signed-off-by: Boyang <tby@udel.edu> * style(pre-commit): autofix --------- Signed-off-by: Boyang <tby@udel.edu> Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> Signed-off-by: Y.Hisaki <yhisaki31@gmail.com>
1 parent 62d3468 commit beb0ed7

File tree

5 files changed

+339
-32
lines changed

5 files changed

+339
-32
lines changed

perception/multi_object_tracker/README.md

Lines changed: 7 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -65,41 +65,16 @@ Multiple inputs are pre-defined in the input channel parameters (described below
6565

6666
### Input Channel parameters
6767

68-
Available input channels are defined in [input_channels.param.yaml](config/input_channels.param.yaml).
69-
70-
| Name | Type | Description |
71-
| --------------------------------- | ------------------------------------------------ | ------------------------------------- |
72-
| `<channel>` | | the name of channel |
73-
| `<channel>.topic` | `autoware_perception_msgs::msg::DetectedObjects` | detected objects |
74-
| `<channel>.can_spawn_new_tracker` | `bool` | a switch allow to spawn a new tracker |
75-
| `<channel>.optional.name` | `std::string` | channel name for analysis |
76-
| `<channel>.optional.short_name` | `std::string` | short name for visualization |
68+
{{ json_to_markdown("perception/multi_object_tracker/schema/input_channels.schema.json") }}
7769

7870
### Core Parameters
7971

80-
Node parameters are defined in [multi_object_tracker_node.param.yaml](config/multi_object_tracker_node.param.yaml) and association parameters are defined in [data_association_matrix.param.yaml](config/data_association_matrix.param.yaml).
81-
82-
#### Node parameters
83-
84-
| Name | Type | Description |
85-
| --------------------------- | ------ | --------------------------------------------------------------------------------------------------------------------------- |
86-
| `***_tracker` | string | EKF tracker name for each class |
87-
| `world_frame_id` | double | object kinematics definition frame |
88-
| `enable_delay_compensation` | bool | if True, tracker use timers to schedule publishers and use prediction step to extrapolate object state at desired timestamp |
89-
| `publish_rate` | double | Timer frequency to output with delay compensation |
90-
| `publish_processing_time` | bool | enable to publish debug message of process time information |
91-
| `publish_tentative_objects` | bool | enable to publish tentative tracked objects, which have lower confidence |
92-
| `publish_debug_markers` | bool | enable to publish debug markers, which indicates association of multi-inputs, existence probability of each detection |
93-
94-
#### Association parameters
95-
96-
| Name | Type | Description |
97-
| ------------------- | ------ | ------------------------------------------- |
98-
| `can_assign_matrix` | double | Assignment table for data association |
99-
| `max_dist_matrix` | double | Maximum distance table for data association |
100-
| `max_area_matrix` | double | Maximum area table for data association |
101-
| `min_area_matrix` | double | Minimum area table for data association |
102-
| `max_rad_matrix` | double | Maximum angle table for data association |
72+
{{ json_to_markdown("perception/multi_object_tracker/schema/multi_object_tracker_node.schema.json") }}
73+
{{ json_to_markdown("perception/multi_object_tracker/schema/data_association_matrix.schema.json") }}
74+
75+
#### Simulation parameters
76+
77+
{{ json_to_markdown("perception/multi_object_tracker/schema/simulation_tracker.schema.json") }}
10378

10479
## Assumptions / Known limits
10580

Lines changed: 74 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,74 @@
1+
{
2+
"$schema": "http://json-schema.org/draft-07/schema#",
3+
"title": "Parameters for Data Association Matrix",
4+
"type": "object",
5+
"definitions": {
6+
"data_association_matrix": {
7+
"type": "object",
8+
"properties": {
9+
"can_assign_matrix": {
10+
"type": "array",
11+
"description": "Assignment table for data association.",
12+
"items": {
13+
"type": "integer"
14+
}
15+
},
16+
"max_dist_matrix": {
17+
"type": "array",
18+
"description": "Maximum distance table for data association.",
19+
"items": {
20+
"type": "number"
21+
}
22+
},
23+
"max_area_matrix": {
24+
"type": "array",
25+
"description": "Maximum area table for data association.",
26+
"items": {
27+
"type": "number"
28+
}
29+
},
30+
"min_area_matrix": {
31+
"type": "array",
32+
"description": "Minimum area table for data association.",
33+
"items": {
34+
"type": "number"
35+
}
36+
},
37+
"max_rad_matrix": {
38+
"type": "array",
39+
"description": "Maximum angle table for data association.",
40+
"items": {
41+
"type": "number"
42+
}
43+
},
44+
"min_iou_matrix": {
45+
"type": "array",
46+
"description": "A matrix that represents the minimum Intersection over Union (IoU) limit allowed for assignment.",
47+
"items": {
48+
"type": "number"
49+
}
50+
}
51+
},
52+
"required": [
53+
"can_assign_matrix",
54+
"max_dist_matrix",
55+
"max_area_matrix",
56+
"min_area_matrix",
57+
"max_rad_matrix",
58+
"min_iou_matrix"
59+
]
60+
}
61+
},
62+
"properties": {
63+
"/**": {
64+
"type": "object",
65+
"properties": {
66+
"ros__parameters": {
67+
"$ref": "#/definitions/data_association_matrix"
68+
}
69+
},
70+
"required": ["ros__parameters"]
71+
}
72+
},
73+
"required": ["/**"]
74+
}
Lines changed: 80 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,80 @@
1+
{
2+
"$schema": "http://json-schema.org/draft-07/schema#",
3+
"title": "Parameters for Input Channels",
4+
"type": "object",
5+
"definitions": {
6+
"input_channel": {
7+
"type": "object",
8+
"properties": {
9+
"topic": {
10+
"type": "string",
11+
"description": "The ROS topic name for the input channel."
12+
},
13+
"can_spawn_new_tracker": {
14+
"type": "boolean",
15+
"description": "Indicates if the input channel can spawn new trackers."
16+
},
17+
"optional": {
18+
"type": "object",
19+
"properties": {
20+
"name": {
21+
"type": "string",
22+
"description": "The name of the input channel."
23+
},
24+
"short_name": {
25+
"type": "string",
26+
"description": "The short name of the input channel."
27+
}
28+
}
29+
}
30+
},
31+
"required": ["topic", "can_spawn_new_tracker"]
32+
}
33+
},
34+
"properties": {
35+
"/**": {
36+
"type": "object",
37+
"properties": {
38+
"ros__parameters": {
39+
"type": "object",
40+
"properties": {
41+
"input_channels": {
42+
"type": "object",
43+
"properties": {
44+
"detected_objects": { "$ref": "#/definitions/input_channel" },
45+
"lidar_clustering": { "$ref": "#/definitions/input_channel" },
46+
"lidar_centerpoint": { "$ref": "#/definitions/input_channel" },
47+
"lidar_centerpoint_validated": { "$ref": "#/definitions/input_channel" },
48+
"lidar_apollo": { "$ref": "#/definitions/input_channel" },
49+
"lidar_apollo_validated": { "$ref": "#/definitions/input_channel" },
50+
"lidar_pointpainitng": { "$ref": "#/definitions/input_channel" },
51+
"lidar_pointpainting_validated": { "$ref": "#/definitions/input_channel" },
52+
"camera_lidar_fusion": { "$ref": "#/definitions/input_channel" },
53+
"detection_by_tracker": { "$ref": "#/definitions/input_channel" },
54+
"radar": { "$ref": "#/definitions/input_channel" },
55+
"radar_far": { "$ref": "#/definitions/input_channel" }
56+
},
57+
"required": [
58+
"detected_objects",
59+
"lidar_clustering",
60+
"lidar_centerpoint",
61+
"lidar_centerpoint_validated",
62+
"lidar_apollo",
63+
"lidar_apollo_validated",
64+
"lidar_pointpainitng",
65+
"lidar_pointpainting_validated",
66+
"camera_lidar_fusion",
67+
"detection_by_tracker",
68+
"radar",
69+
"radar_far"
70+
]
71+
}
72+
},
73+
"required": ["input_channels"]
74+
}
75+
},
76+
"required": ["ros__parameters"]
77+
}
78+
},
79+
"required": ["/**"]
80+
}
Lines changed: 116 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,116 @@
1+
{
2+
"$schema": "http://json-schema.org/draft-07/schema#",
3+
"title": "Parameters for Multi Object Tracker Node",
4+
"type": "object",
5+
"definitions": {
6+
"multi_object_tracker_node": {
7+
"type": "object",
8+
"properties": {
9+
"car_tracker": {
10+
"type": "string",
11+
"description": "Tracker model for car class.",
12+
"default": "multi_vehicle_tracker"
13+
},
14+
"truck_tracker": {
15+
"type": "string",
16+
"description": "Tracker model for truck class.",
17+
"default": "multi_vehicle_tracker"
18+
},
19+
"bus_tracker": {
20+
"type": "string",
21+
"description": "Tracker model for bus class.",
22+
"default": "multi_vehicle_tracker"
23+
},
24+
"trailer_tracker": {
25+
"type": "string",
26+
"description": "Tracker model for trailer class.",
27+
"default": "multi_vehicle_tracker"
28+
},
29+
"pedestrian_tracker": {
30+
"type": "string",
31+
"description": "Tracker model for pedestrian class.",
32+
"default": "pedestrian_and_bicycle_tracker"
33+
},
34+
"bicycle_tracker": {
35+
"type": "string",
36+
"description": "Tracker model for bicycle class.",
37+
"default": "pedestrian_and_bicycle_tracker"
38+
},
39+
"motorcycle_tracker": {
40+
"type": "string",
41+
"description": "Tracker model for motorcycle class.",
42+
"default": "pedestrian_and_bicycle_tracker"
43+
},
44+
"publish_rate": {
45+
"type": "number",
46+
"description": "Timer frequency to output with delay compensation.",
47+
"default": 10.0
48+
},
49+
"world_frame_id": {
50+
"type": "string",
51+
"description": "Object kinematics definition frame.",
52+
"default": "map"
53+
},
54+
"enable_delay_compensation": {
55+
"type": "boolean",
56+
"description": "If True, tracker use timers to schedule publishers and use prediction step to extrapolate object state at desired timestamp.",
57+
"default": false
58+
},
59+
"publish_processing_time": {
60+
"type": "boolean",
61+
"description": "Enable to publish debug message of process time information.",
62+
"default": false
63+
},
64+
"publish_tentative_objects": {
65+
"type": "boolean",
66+
"description": "Enable to publish tentative tracked objects, which have lower confidence.",
67+
"default": false
68+
},
69+
"publish_debug_markers": {
70+
"type": "boolean",
71+
"description": "Enable to publish debug markers, which indicates association of multi-inputs, existence probability of each detection.",
72+
"default": false
73+
},
74+
"diagnostics_warn_delay": {
75+
"type": "number",
76+
"description": "Delay threshold for warning diagnostics in seconds.",
77+
"default": 0.5
78+
},
79+
"diagnostics_error_delay": {
80+
"type": "number",
81+
"description": "Delay threshold for error diagnostics in seconds.",
82+
"default": 1.0
83+
}
84+
},
85+
"required": [
86+
"car_tracker",
87+
"truck_tracker",
88+
"bus_tracker",
89+
"trailer_tracker",
90+
"pedestrian_tracker",
91+
"bicycle_tracker",
92+
"motorcycle_tracker",
93+
"publish_rate",
94+
"world_frame_id",
95+
"enable_delay_compensation",
96+
"publish_processing_time",
97+
"publish_tentative_objects",
98+
"publish_debug_markers",
99+
"diagnostics_warn_delay",
100+
"diagnostics_error_delay"
101+
]
102+
}
103+
},
104+
"properties": {
105+
"/**": {
106+
"type": "object",
107+
"properties": {
108+
"ros__parameters": {
109+
"$ref": "#/definitions/multi_object_tracker_node"
110+
}
111+
},
112+
"required": ["ros__parameters"]
113+
}
114+
},
115+
"required": ["/**"]
116+
}
Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
{
2+
"$schema": "http://json-schema.org/draft-07/schema#",
3+
"title": "Parameters for Simulation Tracker Node",
4+
"type": "object",
5+
"definitions": {
6+
"simulation_tracker_node": {
7+
"type": "object",
8+
"properties": {
9+
"car_tracker": {
10+
"type": "string",
11+
"description": "Tracker model for car class.",
12+
"default": "pass_through_tracker"
13+
},
14+
"truck_tracker": {
15+
"type": "string",
16+
"description": "Tracker model for truck class.",
17+
"default": "pass_through_tracker"
18+
},
19+
"bus_tracker": {
20+
"type": "string",
21+
"description": "Tracker model for bus class.",
22+
"default": "pass_through_tracker"
23+
},
24+
"pedestrian_tracker": {
25+
"type": "string",
26+
"description": "Tracker model for pedestrian class.",
27+
"default": "pass_through_tracker"
28+
},
29+
"bicycle_tracker": {
30+
"type": "string",
31+
"description": "Tracker model for bicycle class.",
32+
"default": "pass_through_tracker"
33+
},
34+
"motorcycle_tracker": {
35+
"type": "string",
36+
"description": "Tracker model for motorcycle class.",
37+
"default": "pass_through_tracker"
38+
}
39+
},
40+
"required": [
41+
"car_tracker",
42+
"truck_tracker",
43+
"bus_tracker",
44+
"pedestrian_tracker",
45+
"bicycle_tracker",
46+
"motorcycle_tracker"
47+
]
48+
}
49+
},
50+
"properties": {
51+
"/**": {
52+
"type": "object",
53+
"properties": {
54+
"ros__parameters": {
55+
"$ref": "#/definitions/simulation_tracker_node"
56+
}
57+
},
58+
"required": ["ros__parameters"]
59+
}
60+
},
61+
"required": ["/**"]
62+
}

0 commit comments

Comments
 (0)