Skip to content

Commit eb7c134

Browse files
committed
refractored the parameters, build the schema files, updated readme
Signed-off-by: Boyang <tby@udel.edu>
1 parent 34eeca4 commit eb7c134

39 files changed

+652
-279
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
/**:
2+
ros__parameters:
3+
# weight files
4+
encoder_onnx_path: "$(var model_path)/pts_voxel_encoder_centerpoint.onnx"
5+
encoder_engine_path: "$(var model_path)/pts_voxel_encoder_centerpoint.engine"
6+
head_onnx_path: "$(var model_path)/pts_backbone_neck_head_centerpoint.onnx"
7+
head_engine_path: "$(var model_path)/pts_backbone_neck_head_centerpoint.engine"
8+
trt_precision: fp16
9+
post_process_params:
10+
# post-process params
11+
circle_nms_dist_threshold: 0.5
12+
iou_nms_target_class_names: ["CAR"]
13+
iou_nms_search_distance_2d: 10.0
14+
iou_nms_threshold: 0.1
15+
score_threshold: 0.35
16+
yaw_norm_thresholds: [0.3, 0.3, 0.3, 0.3, 0.0]
17+
densification_params:
18+
world_frame_id: map
19+
num_past_frames: 1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
/**:
2+
ros__parameters:
3+
# weight files
4+
encoder_onnx_path: "$(var model_path)/pts_voxel_encoder_$(var model_name).onnx"
5+
encoder_engine_path: "$(var model_path)/pts_voxel_encoder_$(var model_name).engine"
6+
head_onnx_path: "$(var model_path)/pts_backbone_neck_head_$(var model_name).onnx"
7+
head_engine_path: "$(var model_path)/pts_backbone_neck_head_$(var model_name).engine"
8+
trt_precision: fp16
9+
post_process_params:
10+
# post-process params
11+
circle_nms_dist_threshold: 0.5
12+
iou_nms_target_class_names: ["CAR"]
13+
iou_nms_search_distance_2d: 10.0
14+
iou_nms_threshold: 0.1
15+
score_threshold: 0.35
16+
yaw_norm_thresholds: [0.3, 0.3, 0.3, 0.3, 0.0]
17+
densification_params:
18+
world_frame_id: map
19+
num_past_frames: 1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,113 @@
1+
{
2+
"$schema": "http://json-schema.org/draft-07/schema#",
3+
"title": "Parameters for Lidar Centerpoint Node",
4+
"type": "object",
5+
"definitions": {
6+
"centerpoint_base": {
7+
"type": "object",
8+
"properties": {
9+
"encoder_onnx_path": {
10+
"type": "string",
11+
"description": "Path to VoxelFeatureEncoder ONNX file.",
12+
"default": ""
13+
},
14+
"encoder_engine_path": {
15+
"type": "string",
16+
"description": "Path to VoxelFeatureEncoder TensorRT Engine file.",
17+
"default": ""
18+
},
19+
"head_onnx_path": {
20+
"type": "string",
21+
"description": "Path to DetectionHead ONNX file.",
22+
"default": ""
23+
},
24+
"head_engine_path": {
25+
"type": "string",
26+
"description": "Path to DetectionHead TensorRT Engine file.",
27+
"default": ""
28+
},
29+
"trt_precision": {
30+
"type": "string",
31+
"description": "TensorRT inference precision.",
32+
"default": "fp16",
33+
"enum": ["fp32", "fp16"]
34+
},
35+
"post_process_params": {
36+
"type": "object",
37+
"properties": {
38+
"score_threshold": {
39+
"type": "number",
40+
"description": "A threshold value of existence probability score, all of objects with score less than this threshold are ignored.",
41+
"default": 0.35,
42+
"minimum": 0.0,
43+
"maximum": 1.0
44+
},
45+
"yaw_norm_thresholds": {
46+
"type": "array",
47+
"description": "An array of distance threshold values of norm of yaw [rad].",
48+
"default": [0.3, 0.3, 0.3, 0.3, 0.0],
49+
"minimum": 0.0,
50+
"maximum": 1.0
51+
},
52+
"circle_nms_dist_threshold": {
53+
"type": "number",
54+
"description": "",
55+
"default": 0.5,
56+
"minimum": 0.0,
57+
"maximum": 1.0
58+
},
59+
"iou_nms_target_class_names": {
60+
"type": "array",
61+
"description": "An array of class names to be target in NMS.",
62+
"default": ["CAR"],
63+
"uniqueItems": true
64+
},
65+
"iou_nms_search_distance_2d": {
66+
"type": "number",
67+
"description": "A maximum distance value to search the nearest objects.",
68+
"default": 10.0,
69+
"minimum": 0.0
70+
},
71+
"iou_nms_threshold": {
72+
"type": "number",
73+
"description": "A threshold value of NMS using IoU score.",
74+
"default": 0.1,
75+
"minimum": 0.0,
76+
"maximum": 1.0
77+
}
78+
}
79+
},
80+
"densification_params": {
81+
"type": "object",
82+
"description": "Parameters for pointcloud densification.",
83+
"properties": {
84+
"world_frame_id": {
85+
"type": "string",
86+
"description": "A name of frame id where world coordinates system is defined with respect to.",
87+
"default": "map"
88+
},
89+
"num_past_frames": {
90+
"type": "integer",
91+
"description": "A number of past frames to be considered as same input frame.",
92+
"default": 1,
93+
"minimum": 0
94+
}
95+
}
96+
}
97+
},
98+
"required": ["post_process_params", "densification_params"]
99+
}
100+
},
101+
"properties": {
102+
"/**": {
103+
"type": "object",
104+
"properties": {
105+
"ros__parameters": {
106+
"$ref": "#/definitions/centerpoint"
107+
}
108+
},
109+
"required": ["ros__parameters"]
110+
}
111+
},
112+
"required": ["/**"]
113+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,98 @@
1+
{
2+
"$schema": "http://json-schema.org/draft-07/schema#",
3+
"title": "Parameters for Centerpoint Sigma ML model",
4+
"type": "object",
5+
"definitions": {
6+
"centerpoint_sigma_ml_package": {
7+
"type": "object",
8+
"properties": {
9+
"model_params": {
10+
"type": "object",
11+
"description": "Parameters for model configuration.",
12+
"properties": {
13+
"class_names": {
14+
"type": "array",
15+
"description": "An array of class names will be predicted.",
16+
"default": ["CAR", "TRUCK", "BUS", "BICYCLE", "PEDESTRIAN"],
17+
"items": {
18+
"type": "string"
19+
},
20+
"uniqueItems": true
21+
},
22+
"point_feature_size": {
23+
"type": "integer",
24+
"description": "A number of channels of point feature layer.",
25+
"default": 4
26+
},
27+
"max_voxel_size": {
28+
"type": "integer",
29+
"description": "A maximum size of voxel grid.",
30+
"default": 40000
31+
},
32+
"point_cloud_range": {
33+
"type": "array",
34+
"description": "An array of distance ranges of each class, this must have same length with `class_names`.",
35+
"default": [-76.8, -76.8, -4.0, 76.8, 76.8, 6.0],
36+
"items": {
37+
"type": "number"
38+
}
39+
},
40+
"voxel_size": {
41+
"type": "array",
42+
"description": "An array of voxel grid sizes for PointPainting, this must have same length with `paint_class_names`.",
43+
"default": [0.32, 0.32, 10.0],
44+
"items": {
45+
"type": "number"
46+
}
47+
},
48+
"downsample_factor": {
49+
"type": "integer",
50+
"description": "A scale factor of downsampling points.",
51+
"default": 1,
52+
"minimum": 1
53+
},
54+
"encoder_in_feature_size": {
55+
"type": "integer",
56+
"description": "A size of encoder input feature channels.",
57+
"default": 9
58+
},
59+
"has_variance": {
60+
"type": "boolean",
61+
"description": "Flag indicating if the model includes variance estimation.",
62+
"default": false
63+
},
64+
"has_twist": {
65+
"type": "boolean",
66+
"description": "Flag indicating if the model includes twist estimation.",
67+
"default": false
68+
}
69+
},
70+
"required": [
71+
"class_names",
72+
"point_feature_size",
73+
"max_voxel_size",
74+
"point_cloud_range",
75+
"voxel_size",
76+
"downsample_factor",
77+
"encoder_in_feature_size",
78+
"has_variance",
79+
"has_twist"
80+
]
81+
}
82+
},
83+
"required": ["model_params"]
84+
}
85+
},
86+
"properties": {
87+
"/**": {
88+
"type": "object",
89+
"properties": {
90+
"ros__parameters": {
91+
"$ref": "#/definitions/centerpoint_sigma_ml_package"
92+
}
93+
},
94+
"required": ["ros__parameters"]
95+
}
96+
},
97+
"required": ["/**"]
98+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,136 @@
1+
{
2+
"$schema": "http://json-schema.org/draft-07/schema#",
3+
"title": "Parameters for Lidar Centerpoint Tiny Node",
4+
"type": "object",
5+
"definitions": {
6+
"centerpoint_tiny": {
7+
"type": "object",
8+
"properties": {
9+
"encoder_onnx_path": {
10+
"type": "string",
11+
"description": "Path to VoxelFeatureEncoder ONNX file.",
12+
"default": ""
13+
},
14+
"encoder_engine_path": {
15+
"type": "string",
16+
"description": "Path to VoxelFeatureEncoder TensorRT Engine file.",
17+
"default": ""
18+
},
19+
"head_onnx_path": {
20+
"type": "string",
21+
"description": "Path to DetectionHead ONNX file.",
22+
"default": ""
23+
},
24+
"head_engine_path": {
25+
"type": "string",
26+
"description": "Path to DetectionHead TensorRT Engine file.",
27+
"default": ""
28+
},
29+
"trt_precision": {
30+
"type": "string",
31+
"description": "TensorRT inference precision.",
32+
"default": "fp16",
33+
"enum": ["fp32", "fp16"]
34+
},
35+
"post_process_params": {
36+
"type": "object",
37+
"properties": {
38+
"score_threshold": {
39+
"type": "number",
40+
"description": "A threshold value of existence probability score, all of objects with score less than this threshold are ignored.",
41+
"default": 0.35,
42+
"minimum": 0.0,
43+
"maximum": 1.0
44+
},
45+
"yaw_norm_thresholds": {
46+
"type": "array",
47+
"description": "An array of distance threshold values of norm of yaw [rad].",
48+
"default": [0.3, 0.3, 0.3, 0.3, 0.0],
49+
"items": {
50+
"type": "number",
51+
"minimum": 0.0,
52+
"maximum": 1.0
53+
}
54+
},
55+
"circle_nms_dist_threshold": {
56+
"type": "number",
57+
"description": "The distance threshold for circle NMS.",
58+
"default": 0.5,
59+
"minimum": 0.0,
60+
"maximum": 1.0
61+
},
62+
"iou_nms_target_class_names": {
63+
"type": "array",
64+
"description": "An array of class names to be target in NMS.",
65+
"default": ["CAR"],
66+
"items": {
67+
"type": "string"
68+
},
69+
"uniqueItems": true
70+
},
71+
"iou_nms_search_distance_2d": {
72+
"type": "number",
73+
"description": "A maximum distance value to search the nearest objects.",
74+
"default": 10.0,
75+
"minimum": 0.0
76+
},
77+
"iou_nms_threshold": {
78+
"type": "number",
79+
"description": "A threshold value of NMS using IoU score.",
80+
"default": 0.1,
81+
"minimum": 0.0,
82+
"maximum": 1.0
83+
}
84+
},
85+
"required": [
86+
"score_threshold",
87+
"yaw_norm_thresholds",
88+
"circle_nms_dist_threshold",
89+
"iou_nms_target_class_names",
90+
"iou_nms_search_distance_2d",
91+
"iou_nms_threshold"
92+
]
93+
},
94+
"densification_params": {
95+
"type": "object",
96+
"description": "Parameters for pointcloud densification.",
97+
"properties": {
98+
"world_frame_id": {
99+
"type": "string",
100+
"description": "A name of frame id where world coordinates system is defined with respect to.",
101+
"default": "map"
102+
},
103+
"num_past_frames": {
104+
"type": "integer",
105+
"description": "A number of past frames to be considered as same input frame.",
106+
"default": 1,
107+
"minimum": 0
108+
}
109+
},
110+
"required": ["world_frame_id", "num_past_frames"]
111+
}
112+
},
113+
"required": [
114+
"encoder_onnx_path",
115+
"encoder_engine_path",
116+
"head_onnx_path",
117+
"head_engine_path",
118+
"trt_precision",
119+
"post_process_params",
120+
"densification_params"
121+
]
122+
}
123+
},
124+
"properties": {
125+
"/**": {
126+
"type": "object",
127+
"properties": {
128+
"ros__parameters": {
129+
"$ref": "#/definitions/centerpoint_tiny"
130+
}
131+
},
132+
"required": ["ros__parameters"]
133+
}
134+
},
135+
"required": ["/**"]
136+
}

0 commit comments

Comments
 (0)