diff --git a/launch/tier4_perception_launch/config/obstacle_segmentation/ground_segmentation/ground_segmentation.param.yaml b/launch/tier4_perception_launch/config/obstacle_segmentation/ground_segmentation/ground_segmentation.param.yaml index 33addb108dded..e3bef09e52b47 100644 --- a/launch/tier4_perception_launch/config/obstacle_segmentation/ground_segmentation/ground_segmentation.param.yaml +++ b/launch/tier4_perception_launch/config/obstacle_segmentation/ground_segmentation/ground_segmentation.param.yaml @@ -19,5 +19,5 @@ global_slope_max_angle_deg: 10.0 local_slope_max_angle_deg: 30.0 split_points_distance_tolerance: 0.2 - split_height_distance: 0.2 - use_virtual_ground_point: False + split_height_distance: 0.3 + use_virtual_ground_point: True diff --git a/perception/ground_segmentation/src/scan_ground_filter_nodelet.cpp b/perception/ground_segmentation/src/scan_ground_filter_nodelet.cpp index 20deb7a785c0f..a85fb5d120b73 100644 --- a/perception/ground_segmentation/src/scan_ground_filter_nodelet.cpp +++ b/perception/ground_segmentation/src/scan_ground_filter_nodelet.cpp @@ -178,6 +178,10 @@ void ScanGroundFilterComponent::classifyPointCloud( } else { calculate_slope = true; } + if (is_point_close_to_prev) { + height_from_gnd = p->orig_point->z - ground_cluster.getAverageHeight(); + radius_distance_from_gnd = p->radius - ground_cluster.getAverageRadius(); + } if (calculate_slope) { // far from the previous point