From d957c83fc09969da537a013a94391388dcb9a5dd Mon Sep 17 00:00:00 2001 From: badai nguyen <94814556+badai-nguyen@users.noreply.github.com> Date: Fri, 26 Apr 2024 19:56:39 +0900 Subject: [PATCH 1/2] refactor(centerpoint, pointpainting): rearrange ML model and package params (#915) * chore: separate param files Signed-off-by: badai-nguyen * chore: fix launch Signed-off-by: badai-nguyen * chore: rearrange param Signed-off-by: badai-nguyen * style(pre-commit): autofix * refactor: rearrange param file Signed-off-by: badai-nguyen * chore: move densification_params Signed-off-by: badai-nguyen * style(pre-commit): autofix * fix(centerpoint): align param namespace with pointpainting Signed-off-by: badai-nguyen * fix: param Signed-off-by: badai-nguyen * fix: remove build_only from yaml Signed-off-by: badai-nguyen --------- Signed-off-by: badai-nguyen Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> --- .../lidar_model/centerpoint.param.yaml | 31 ++++++--------- .../lidar_model/centerpoint_tiny.param.yaml | 27 ------------- .../detection_class_remapper.param.yaml | 38 ------------------- .../lidar_model/pointpainting.param.yaml | 24 +++--------- 4 files changed, 18 insertions(+), 102 deletions(-) delete mode 100644 autoware_launch/config/perception/object_recognition/detection/lidar_model/centerpoint_tiny.param.yaml delete mode 100644 autoware_launch/config/perception/object_recognition/detection/lidar_model/detection_class_remapper.param.yaml mode change 100755 => 100644 autoware_launch/config/perception/object_recognition/detection/lidar_model/pointpainting.param.yaml diff --git a/autoware_launch/config/perception/object_recognition/detection/lidar_model/centerpoint.param.yaml b/autoware_launch/config/perception/object_recognition/detection/lidar_model/centerpoint.param.yaml index 38c57285e5..0777ddb92b 100644 --- a/autoware_launch/config/perception/object_recognition/detection/lidar_model/centerpoint.param.yaml +++ b/autoware_launch/config/perception/object_recognition/detection/lidar_model/centerpoint.param.yaml @@ -1,27 +1,20 @@ /**: ros__parameters: - class_names: ["CAR", "TRUCK", "BUS", "BICYCLE", "PEDESTRIAN"] - point_feature_size: 4 - max_voxel_size: 40000 - point_cloud_range: [-76.8, -76.8, -4.0, 76.8, 76.8, 6.0] - voxel_size: [0.32, 0.32, 10.0] - downsample_factor: 1 - encoder_in_feature_size: 9 - # post-process params - circle_nms_dist_threshold: 0.5 - iou_nms_target_class_names: ["CAR"] - iou_nms_search_distance_2d: 10.0 - iou_nms_threshold: 0.1 - yaw_norm_thresholds: [0.3, 0.3, 0.3, 0.3, 0.0] - score_threshold: 0.35 - has_variance: false - has_twist: false - trt_precision: fp16 - densification_num_past_frames: 1 - densification_world_frame_id: map # weight files encoder_onnx_path: "$(var model_path)/pts_voxel_encoder_$(var model_name).onnx" encoder_engine_path: "$(var model_path)/pts_voxel_encoder_$(var model_name).engine" head_onnx_path: "$(var model_path)/pts_backbone_neck_head_$(var model_name).onnx" head_engine_path: "$(var model_path)/pts_backbone_neck_head_$(var model_name).engine" + trt_precision: fp16 + post_process_params: + # post-process params + circle_nms_dist_threshold: 0.5 + iou_nms_target_class_names: ["CAR"] + iou_nms_search_distance_2d: 10.0 + iou_nms_threshold: 0.1 + yaw_norm_thresholds: [0.3, 0.3, 0.3, 0.3, 0.0] + score_threshold: 0.35 + densification_params: + world_frame_id: map + num_past_frames: 1 diff --git a/autoware_launch/config/perception/object_recognition/detection/lidar_model/centerpoint_tiny.param.yaml b/autoware_launch/config/perception/object_recognition/detection/lidar_model/centerpoint_tiny.param.yaml deleted file mode 100644 index 35e11e61e9..0000000000 --- a/autoware_launch/config/perception/object_recognition/detection/lidar_model/centerpoint_tiny.param.yaml +++ /dev/null @@ -1,27 +0,0 @@ -/**: - ros__parameters: - class_names: ["CAR", "TRUCK", "BUS", "BICYCLE", "PEDESTRIAN"] - point_feature_size: 4 - max_voxel_size: 40000 - point_cloud_range: [-76.8, -76.8, -4.0, 76.8, 76.8, 6.0] - voxel_size: [0.32, 0.32, 10.0] - downsample_factor: 2 - encoder_in_feature_size: 9 - # post-process params - circle_nms_dist_threshold: 0.5 - iou_nms_target_class_names: ["CAR"] - iou_nms_search_distance_2d: 10.0 - iou_nms_threshold: 0.1 - yaw_norm_thresholds: [0.3, 0.3, 0.3, 0.3, 0.0] - score_threshold: 0.35 - has_variance: false - has_twist: false - trt_precision: fp16 - densification_num_past_frames: 1 - densification_world_frame_id: map - - # weight files - encoder_onnx_path: "$(var model_path)/pts_voxel_encoder_$(var model_name).onnx" - encoder_engine_path: "$(var model_path)/pts_voxel_encoder_$(var model_name).engine" - head_onnx_path: "$(var model_path)/pts_backbone_neck_head_$(var model_name).onnx" - head_engine_path: "$(var model_path)/pts_backbone_neck_head_$(var model_name).engine" diff --git a/autoware_launch/config/perception/object_recognition/detection/lidar_model/detection_class_remapper.param.yaml b/autoware_launch/config/perception/object_recognition/detection/lidar_model/detection_class_remapper.param.yaml deleted file mode 100644 index baea087c96..0000000000 --- a/autoware_launch/config/perception/object_recognition/detection/lidar_model/detection_class_remapper.param.yaml +++ /dev/null @@ -1,38 +0,0 @@ -/**: - ros__parameters: - allow_remapping_by_area_matrix: - # NOTE(kl): We turn all vehicles into trailers if they go over 3x12 [m^2]. - # NOTE(kl): We turn cars into trucks if they have an area between 2.2 x 5.5 and 3.0 * 12.0 [m^2] - # row: original class. column: class to remap to - #UNKNOWN, CAR, TRUCK, BUS, TRAILER, MOTORBIKE, BICYCLE,PEDESTRIAN - [0, 0, 0, 0, 0, 0, 0, 0, #UNKNOWN - 0, 0, 1, 0, 1, 0, 0, 0, #CAR - 0, 0, 0, 0, 1, 0, 0, 0, #TRUCK - 0, 0, 0, 0, 1, 0, 0, 0, #BUS - 0, 0, 0, 0, 0, 0, 0, 0, #TRAILER - 0, 0, 0, 0, 0, 0, 0, 0, #MOTORBIKE - 0, 0, 0, 0, 0, 0, 0, 0, #BICYCLE - 0, 0, 0, 0, 0, 0, 0, 0] #PEDESTRIAN - - min_area_matrix: - #UNKNOWN, CAR, TRUCK, BUS, TRAILER, MOTORBIKE, BICYCLE, PEDESTRIAN - [ 0.000, 0.000, 0.000, 0.000, 0.000, 0.000, 0.000, 0.000, #UNKNOWN - 0.000, 0.000, 12.100, 0.000, 36.000, 0.000, 0.000, 0.000, #CAR - 0.000, 0.000, 0.000, 0.000, 36.000, 0.000, 0.000, 0.000, #TRUCK - 0.000, 0.000, 0.000, 0.000, 36.000, 0.000, 0.000, 0.000, #BUS - 0.000, 0.000, 0.000, 0.000, 0.000, 0.000, 0.000, 0.000, #TRAILER - 0.000, 0.000, 0.000, 0.000, 0.000, 0.000, 0.000, 0.000, #MOTORBIKE - 0.000, 0.000, 0.000, 0.000, 0.000, 0.000, 0.000, 0.000, #BICYCLE - 0.000, 0.000, 0.000, 0.000, 0.000, 0.000, 0.000, 0.000] #PEDESTRIAN - - - max_area_matrix: - #UNKNOWN, CAR, TRUCK, BUS, TRAILER, MOTORBIKE, BICYCLE, PEDESTRIAN - [ 0.000, 0.000, 0.000, 0.000, 0.000, 0.000, 0.000, 0.000, #UNKNOWN - 0.000, 0.000, 36.000, 0.000, 999.999, 0.000, 0.000, 0.000, #CAR - 0.000, 0.000, 0.000, 0.000, 999.999, 0.000, 0.000, 0.000, #TRUCK - 0.000, 0.000, 0.000, 0.000, 999.999, 0.000, 0.000, 0.000, #BUS - 0.000, 0.000, 0.000, 0.000, 0.000, 0.000, 0.000, 0.000, #TRAILER - 0.000, 0.000, 0.000, 0.000, 0.000, 0.000, 0.000, 0.000, #MOTORBIKE - 0.000, 0.000, 0.000, 0.000, 0.000, 0.000, 0.000, 0.000, #BICYCLE - 0.000, 0.000, 0.000, 0.000, 0.000, 0.000, 0.000, 0.000] #PEDESTRIAN diff --git a/autoware_launch/config/perception/object_recognition/detection/lidar_model/pointpainting.param.yaml b/autoware_launch/config/perception/object_recognition/detection/lidar_model/pointpainting.param.yaml old mode 100755 new mode 100644 index 53ac6f4caf..de46b6dd74 --- a/autoware_launch/config/perception/object_recognition/detection/lidar_model/pointpainting.param.yaml +++ b/autoware_launch/config/perception/object_recognition/detection/lidar_model/pointpainting.param.yaml @@ -1,33 +1,21 @@ /**: ros__parameters: - trt_precision: fp16 encoder_onnx_path: "$(var model_path)/pts_voxel_encoder_$(var model_name).onnx" encoder_engine_path: "$(var model_path)/pts_voxel_encoder_$(var model_name).engine" head_onnx_path: "$(var model_path)/pts_backbone_neck_head_$(var model_name).onnx" head_engine_path: "$(var model_path)/pts_backbone_neck_head_$(var model_name).engine" - - model_params: - class_names: ["CAR", "TRUCK", "BUS", "BICYCLE", "PEDESTRIAN"] - paint_class_names: ["CAR", "BICYCLE", "PEDESTRIAN"] - point_feature_size: 7 # x, y, z, time-lag and car, pedestrian, bicycle - max_voxel_size: 40000 - point_cloud_range: [-121.6, -76.8, -3.0, 121.6, 76.8, 5.0] - voxel_size: [0.32, 0.32, 8.0] - downsample_factor: 1 - encoder_in_feature_size: 12 - yaw_norm_thresholds: [0.3, 0.3, 0.3, 0.3, 0.0] - has_variance: false - has_twist: false - densification_params: - world_frame_id: "map" - num_past_frames: 0 + trt_precision: fp16 post_process_params: # post-process params circle_nms_dist_threshold: 0.3 iou_nms_target_class_names: ["CAR"] iou_nms_search_distance_2d: 10.0 iou_nms_threshold: 0.1 - score_threshold: 0.35 + score_threshold: 0.45 + yaw_norm_thresholds: [0.3, 0.3, 0.3, 0.3, 0.0] + densification_params: + world_frame_id: "map" + num_past_frames: 1 omp_params: # omp params num_threads: 1 From 06b271e62577e2849f2b9605b56de440959b6083 Mon Sep 17 00:00:00 2001 From: Yoshi Ri Date: Fri, 26 Apr 2024 19:58:14 +0900 Subject: [PATCH 2/2] feat(probabilistic_occupancy_grid_map): add downsample filter option to ogm creation (#962) * feat(probabilistic_occupancy_grid_map): add downsample filter option to ogm creation Signed-off-by: yoshiri * chore: do not use pointcloud filter when downsample is true Signed-off-by: yoshiri * Update autoware_launch/config/perception/occupancy_grid_map/multi_lidar_pointcloud_based_occupancy_grid_map.param.yaml Co-authored-by: Yukihiro Saito --------- Signed-off-by: yoshiri Co-authored-by: Yukihiro Saito --- ...lti_lidar_pointcloud_based_occupancy_grid_map.param.yaml | 6 +++++- .../pointcloud_based_occupancy_grid_map.param.yaml | 4 ++++ 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/autoware_launch/config/perception/occupancy_grid_map/multi_lidar_pointcloud_based_occupancy_grid_map.param.yaml b/autoware_launch/config/perception/occupancy_grid_map/multi_lidar_pointcloud_based_occupancy_grid_map.param.yaml index f9a1c4f930..878bea4cd8 100644 --- a/autoware_launch/config/perception/occupancy_grid_map/multi_lidar_pointcloud_based_occupancy_grid_map.param.yaml +++ b/autoware_launch/config/perception/occupancy_grid_map/multi_lidar_pointcloud_based_occupancy_grid_map.param.yaml @@ -12,6 +12,10 @@ map_length_x: 150.0 # [m] map_length_y: 150.0 # [m] + # downsample input pointcloud + downsample_input_pointcloud: true + downsample_voxel_size: 0.25 # [m] + # each grid map parameters ogm_creation_config: height_filter: @@ -20,7 +24,7 @@ max_height: 2.0 enable_single_frame_mode: true # use sensor pointcloud to filter obstacle pointcloud - filter_obstacle_pointcloud_by_raw_pointcloud: true + filter_obstacle_pointcloud_by_raw_pointcloud: false grid_map_type: "OccupancyGridMapFixedBlindSpot" OccupancyGridMapFixedBlindSpot: diff --git a/autoware_launch/config/perception/occupancy_grid_map/pointcloud_based_occupancy_grid_map.param.yaml b/autoware_launch/config/perception/occupancy_grid_map/pointcloud_based_occupancy_grid_map.param.yaml index 8077bdec50..a87e8b95a0 100644 --- a/autoware_launch/config/perception/occupancy_grid_map/pointcloud_based_occupancy_grid_map.param.yaml +++ b/autoware_launch/config/perception/occupancy_grid_map/pointcloud_based_occupancy_grid_map.param.yaml @@ -8,6 +8,10 @@ min_height: -1.0 max_height: 2.0 + # downsample input pointcloud + downsample_input_pointcloud: true + downsample_voxel_size: 0.125 # [m] + enable_single_frame_mode: false # use sensor pointcloud to filter obstacle pointcloud filter_obstacle_pointcloud_by_raw_pointcloud: false