From 490c24616b3a5b4b7500a19378d36dcde52d2c68 Mon Sep 17 00:00:00 2001 From: duongtd Date: Thu, 23 Jul 2026 15:21:53 +0700 Subject: [PATCH] otimal --- config/config/costmap_common_params.yaml | 2 +- config/config/costmap_params.yaml | 6 ++++-- config/config/obstacle_layer_params.yaml | 2 +- config/config/voxel_layer_params.yaml | 23 ++++++++++++++++++++- config/costmap_common_params.yaml | 2 +- launch/depth_local_costmap_test.launch | 26 +++++++++++++++++++++++- 6 files changed, 54 insertions(+), 7 deletions(-) diff --git a/config/config/costmap_common_params.yaml b/config/config/costmap_common_params.yaml index 46466b8..d9abf8a 100644 --- a/config/config/costmap_common_params.yaml +++ b/config/config/costmap_common_params.yaml @@ -30,7 +30,7 @@ obstacles: marking: true inf_is_valid: false frustum_clearing_enabled: true - frustum_clearing_pixel_step: 8 + frustum_clearing_pixel_step: 4 frustum_min_range: 0.20 frustum_max_range: 3.5 observation_persistence: 0.0 diff --git a/config/config/costmap_params.yaml b/config/config/costmap_params.yaml index 21abc8e..d6ca2e7 100644 --- a/config/config/costmap_params.yaml +++ b/config/config/costmap_params.yaml @@ -1,7 +1,9 @@ robot_costmap_2d: # Derived from pnkx_nav_core/config/costmap_local_params.yaml. - # NUC path is intentional for the user's local test workspace. - library_path: /home/robotics/DuongTD/dev_ws/devel/lib/libplugins.so + # Machine-specific absolute path: must point at the libplugins.so built in + # THIS machine's workspace (contains obstacle decay + ray dithering). + # NUC: /home/robotics/DuongTD/dev_ws/devel/lib/libplugins.so + library_path: /home/duongtd/T800_ws/devel/lib/libplugins.so global_frame: odom robot_base_frame: base_link rolling_window: true diff --git a/config/config/obstacle_layer_params.yaml b/config/config/obstacle_layer_params.yaml index 0fcde92..85c0c72 100644 --- a/config/config/obstacle_layer_params.yaml +++ b/config/config/obstacle_layer_params.yaml @@ -30,7 +30,7 @@ obstacle_layer: marking: true inf_is_valid: false frustum_clearing_enabled: true - frustum_clearing_pixel_step: 8 + frustum_clearing_pixel_step: 4 frustum_min_range: 0.20 frustum_max_range: 3.5 observation_persistence: 0.0 diff --git a/config/config/voxel_layer_params.yaml b/config/config/voxel_layer_params.yaml index bf3b622..4ec7884 100644 --- a/config/config/voxel_layer_params.yaml +++ b/config/config/voxel_layer_params.yaml @@ -8,9 +8,30 @@ voxel_layer: unknown_threshold: 15.0 mark_threshold: 0 combination_method: 1 + # Camera-only ghost handling: LETHAL cells not re-observed for this many + # seconds are freed. Covers cells frustum clearing can never reach (outside + # the current FOV, occlusion shadows). 0 disables (default). Only enable on + # camera-only costmaps: decay clears obstacles the sensor cannot see. + obstacle_decay_time: 4.0 + # Clearing rays stop this far [m] before the measured surface. Negative + # keeps the legacy 2 * resolution behaviour (0.10 m at res 0.05). + frustum_skip_distance: 0.05 + # Full-column clearing: per depth-image pixel column, the nearest return in + # the height band certifies the beam free and wipes whole voxel columns + # along it. Removes marked voxels the per-pixel 3D rays cannot reach + # (above the vertical FOV at close range). Measurement-driven: keeps + # obstacles outside the FOV untouched (no decay). + frustum_column_clearing: true + # Height band [m]; floor returns below min do not shorten the beam. + # max < 0: use max_obstacle_height. + column_clear_min_height: 0.10 + column_clear_max_height: -1.0 + # Full columns only cleared beyond this distance [m] (vertical FOV must + # cover the whole band). Negative: auto from camera intrinsics + mount pose. + column_cover_distance: -1.0 publish_voxel_map: true frustum_clearing_enabled: false - frustum_clearing_pixel_step: 8 + frustum_clearing_pixel_step: 4 frustum_min_range: 0.20 frustum_max_range: 3.5 frustum_depth_camera_topic: /camera/depth/data diff --git a/config/costmap_common_params.yaml b/config/costmap_common_params.yaml index 46466b8..d9abf8a 100644 --- a/config/costmap_common_params.yaml +++ b/config/costmap_common_params.yaml @@ -30,7 +30,7 @@ obstacles: marking: true inf_is_valid: false frustum_clearing_enabled: true - frustum_clearing_pixel_step: 8 + frustum_clearing_pixel_step: 4 frustum_min_range: 0.20 frustum_max_range: 3.5 observation_persistence: 0.0 diff --git a/launch/depth_local_costmap_test.launch b/launch/depth_local_costmap_test.launch index 49c0928..857b119 100644 --- a/launch/depth_local_costmap_test.launch +++ b/launch/depth_local_costmap_test.launch @@ -12,6 +12,23 @@ + + + + + + + + + + - + @@ -62,6 +79,13 @@ + + + + + + +