voxel-layer

Extend ObstacleLayer with a 3D voxel grid for volumetric raycasting.

18|2|Updated Apr 20, 2026
One-click install
npx skills add https://github.com/wimblerobotics/ros2-copilot-skills --skill voxel-layer
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: voxel-layer
Source: https://github.com/wimblerobotics/ros2-copilot-skills/tree/main/voxel-layer
Command: npx skills add https://github.com/wimblerobotics/ros2-copilot-skills --skill voxel-layer

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

VoxelLayer extends ObstacleLayer with a 3D voxel grid for proper volumetric raycasting. It enables accurate obstacle clearing across height dimensions when using depth sensors or 3D LiDAR.

Core Features & Use Cases

  • 3D voxel grid per (x, y) cell with z_voxels and z_resolution to capture height variation and enable 3D raycasting.
  • 3D raycasting for simultaneous clearance across multiple height layers, improving accuracy for elevated obstacles or shelves.
  • Configurable parameters including z_voxels, z_resolution, origin_z, and mark_threshold to tune reporting, memory usage, and sensitivity.
  • Use cases: depth cameras or 3D lidar on robots requiring height-aware clearing, handling objects at different elevations, and verifying clearance with upper voxels in RViz.

Quick Start

Configure your local_costmap by enabling voxel_layer and set z_voxels, z_resolution, and origin_z to match your sensor setup.

Frequently Asked Questions about voxel-layer

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I configure 3D obstacle clearing for a Nav2 costmap using depth cameras?

To configure 3D obstacle clearing, enable the voxel layer in your local_costmap and set z_voxels, z_resolution, and origin_z to match your depth camera setup. This enables volumetric raycasting across multiple height layers for accurate clearance of elevated obstacles.

Why does my Nav2 costmap fail to clear overhanging obstacles detected by 3D LiDAR?

Standard obstacle layers lack 3D raycasting, causing overhanging obstacles to persist in the costmap. A voxel layer applies volumetric raycasting across z_voxels to properly clear elevated geometry and overhanging structures detected by 3D LiDAR.

What is 3D raycasting in a voxel grid and how does it improve robot navigation?

3D raycasting in a voxel grid performs simultaneous clearance across multiple height layers within each costmap cell. It improves robot navigation by accurately clearing elevated obstacles and verifying vertical clearance when using height-varying sensors like depth cameras.

What are the memory implications of increasing z_voxels in a 3D costmap configuration?

Increasing z_voxels expands the 3D voxel grid height per costmap cell, which directly increases memory consumption. You must balance z_voxels and z_resolution against your sensor's vertical range to manage memory usage while maintaining sufficient height-aware obstacle detection.

Can I use a voxel layer with 2D LiDAR for robot obstacle avoidance?

A voxel layer is designed for height-varying sensors like depth cameras and 3D LiDAR rather than 2D LiDAR. For 2D LiDAR obstacle avoidance, standard 2D costmap layers are more appropriate and avoid unnecessary 3D voxel grid memory overhead.

How do I tune mark_threshold for 3D obstacle sensitivity in a voxel costmap?

You tune mark_threshold in the voxel costmap to adjust how many sensor observations are required before marking a 3D voxel as an obstacle. Lowering it increases sensitivity to detected obstacles, while raising it filters out transient noise.