Skip to content

Add landmark rocks, more moon base buildings, and a 30x30 m drivable area to lunar_sim for slam_toolbox mapping - #1107

Draft
bkanator wants to merge 1 commit into
mainfrom
feat/18069-lunar-base-layout
Draft

bkanator wants to merge 1 commit into
mainfrom
feat/18069-lunar-base-layout

Conversation

@bkanator

@bkanator bkanator commented Oct 16, 2026 •

Copy link
Copy Markdown

[written by AI]

Refs PickNikRobotics/moveit_pro#24242
Refs PickNikRobotics/moveit_pro#18069

This makes lunar_sim a scene slam_toolbox can map well enough for AMCL to localize against in #18069, while keeping it realistic and drivable. Before, the planar lidars saw four round boulders and a small base on a 20x20 m area, and band-lap drives exposed traps the costmaps could not see: a crater the rover rocked in, a landing pad it rolled over on, and gaps at the edge it wedged in.

  • 30x30 m drivable area: generate_band_terrain.py adds a 5 m band around the cratered centre with the centre's own terrain recipe, as 2 cm collision strips and visual strips, with no tiling. It ends in a berm whose crest stands 0.62 m above its foot, derived from the lidar mounts so the front plane sees it and the rear plane clears it. Its 0.4 m inner face lets the front lidar see it 0.28 m past its foot, so no free-looking strip opens beside edge objects. Where nothing stands near the edge, its foot wanders up to 0.6 m outward, so each 30 m side gives scan matching segments to lock onto. The far horizon and stars are kept.
  • Landmarks: generate_landmarks.py places 40 angular ejecta rocks, a mesa and seven band blocks in place of the round boulders and the lander blast berm. Each one either rolls under the rover (at most 0.10 m) or reaches the front plane and stays 0.1 m from the rear plane on every side, and tall ones keep a 1.2 m lane.
  • Moon base: ten bodies. A rover garage, a fission power unit and a logistics module are new, and the solar array and antenna move into the band. Parts the front lidar cannot see that reach past the parts it can stand at most 0.10 m above the ground beside them: the landing pad, antenna foundation, solar feet and power pad are lowered, the lander's legs drop vertically from a knee above the scan plane, and the habitat's door sill sits under its frame.
  • Terrain the rover can drive out of: crater rim-to-floor relief is capped at 0.15 m, and the 200 small rocks sit at most 0.10 m proud. The cap requantised the 8-bit centre heightmap (under 1 mm per sample), so the open-loop Dead Reckon Square closure moved from 1.28 to 1.38 m and its baseline is re-recorded.
  • Costmaps: each scan feeds its own obstacle layer, so a rear ray passing over a rock only the front plane reaches no longer clears it.
  • Checks: test_husky_mujoco_geometry.py checks band tiling and seams, the berm height, every landmark and small rock against the roll-over and scan-plane rules, and the far horizon under the band. validate_moon_base.py rasterises each body to check its low parts.

The sun moves to (-14.73, -6.38, 8.35) so shadows cover the whole area.

How it was tested

  • colcon test lunar_sim + lunar_sim_behaviors: 100 tests, 0 failures, 13 unconditional skips (interactive Objectives), including the Nav2 goal integration test.
  • Both validators pass. Each new rule fails on the geometry it replaced (old pad, splayed legs, threshold, rock seating, a flattened berm strip).
  • Band lap of 11 Nav2 goals around the 10-12 m ring with slam_toolbox (5 m range, front scan; not part of this PR): on the two laps of this scene, every goal was reached with no physics instability, and position RMS against ground truth was 1.04 and 0.98 m for slam_toolbox against 1.67 and 0.71 m for wheel+IMU odometry. Laps during review ranged from 0.69 to 3.98 m for slam_toolbox.
  • On an idle GTX 1080 Ti against main: front camera 2.35 → 3.02 ms per frame, scene camera 3.06 → 3.69 ms, physics 95 → 99 µs per step, +28 MiB GPU memory.

Release notes

  • Enhancement: lunar_sim has a 30x30 m drivable area ringed by a berm the lidars see, angular landmark rocks, and more moon base buildings, giving slam_toolbox and the costmaps more to map and localize against; craters, rocks and low base parts are sized so the rover can drive over them or see them.

Follow-ups

  • slam_toolbox accuracy varies lap to lap (one lap drifted 16° in yaw early); tuning belongs with the map and AMCL work in #18069.
  • A keep-out for Nav2 goals within about 0.3 m of the berm's foot, where a wheel can reach the face before the footprint reaches the marked cell.

Claude agent checks

  • code-reviewer
    • No P0/P1 on the final commit. P2s fixed: stale baseline figures in moon_base_validation.md and the README, a stale error message, a validator ray miss now fails closed. Kept: the roll-over limit and scan-plane reader are repeated in the validator and test, which run in a container without scipy and so cannot import the generators.
  • platform-architect-bot
    • P1 fixed: the berm sat below the front plane, so the rover could climb off the collision ground unseen. P2s fixed: shared scan planes and 8-bit reader, exposure faults returned instead of raised, far generator reads the centre's z range from the scene, shadow coverage of the south-west corner.
  • roboticist-bot
    • P1s fixed: the rear scan cleared front-only landmarks (one obstacle layer per scan), and the low-parts check used bounding boxes (now true geometry; lander legs and door sill reshaped). P2 taken: berm wobble. P2 deferred: goal keep-out from the berm foot.
  • frontend-noah-bot — SKIPPED: no frontend code.
  • security-auditor — SKIPPED: no trust boundary, credentials, or network surface.
  • compatibility-bot — SKIPPED: example config only, no public API surface.
  • documentation-bot
    • Stale baseline figures fixed. No public doc made false; mobile_base_support.md already says lunar_sim does not run Nav2, which is #24067's to fix.
  • licensing-privacy-bot — SKIPPED: all meshes and heightmaps are generated in-repo; nothing vendored or copied.
  • sonar-bot
    • example_ws has no Sonar analysis. Predicted findings fixed: low-parts check split into helpers, one scene path constant, composite asserts split.
  • test-runner
    • lunar_sim + lunar_sim_behaviors 100 tests, 0 failures, 13 skipped.

🤖 Generated with Claude Code

@coderabbitai

coderabbitai Bot commented Oct 16, 2026 •

Copy link
Copy Markdown

Important

Draft PR not reviewed

Draft PRs are not automatically reviewed by default.

  • Trigger a manual review

To automatically review draft PRs, update your CodeRabbit configuration:

reviews:
  auto_review:
    drafts: true
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Tip

🎯 Customize your risk assessments

Guide how CodeRabbit assesses merge risk and security architecture risk. Highlight sensitive changes and explain your security boundaries using Merge Risk Instructions and Security Risk Instructions in your review settings. Security architecture risk assessments require the Advanced plan or above.

✅ Automatic approvals, with your rules

Let CodeRabbit approve pull requests once required threads are resolved, pre-merge checks pass, and your risk limits are met. Enable Automatic approvals in review settings, with overrides for teams or file paths.

@github-actions

Copy link
Copy Markdown

MoveIt Pro Example WS - Objectives Integration Test Report

  • lab_sim
    • ❌ jazzy: no report produced — see run logs
  • hangar_sim
    • ❌ jazzy: no report produced — see run logs

@bkanator
bkanator force-pushed the feat/18069-lunar-base-layout branch from 5d7fb80 to bc9e920 Compare October 22, 2026 19:25
@github-actions

Copy link
Copy Markdown

MoveIt Pro Example WS - Objectives Integration Test Report

  • lab_sim
    • ❌ jazzy: no report produced — see run logs
  • hangar_sim
    • ❌ jazzy: no report produced — see run logs

@bkanator
bkanator force-pushed the feat/18068-lunar-nav branch from d2eb834 to 8e3a87f Compare October 23, 2026 11:36
@bkanator
bkanator force-pushed the feat/18069-lunar-base-layout branch from bc9e920 to cf11b43 Compare October 23, 2026 11:36
@github-actions

Copy link
Copy Markdown

MoveIt Pro Example WS - Objectives Integration Test Report

@bkanator
bkanator force-pushed the feat/18068-lunar-nav branch from 8e3a87f to 01b6b05 Compare October 29, 2026 01:16
@bkanator
bkanator force-pushed the feat/18069-lunar-base-layout branch 2 times, most recently from b505726 to a06d5de Compare October 29, 2026 01:17
@github-actions

Copy link
Copy Markdown

MoveIt Pro Example WS - Objectives Integration Test Report

@github-actions

Copy link
Copy Markdown

MoveIt Pro Example WS - Objectives Integration Test Report

Base automatically changed from feat/18068-lunar-nav to main November 3, 2026 00:07
…30x30 m drivable area

Give slam_toolbox and the costmaps a scene they can map and localize against: a 5 m band around the cratered centre ending in a berm the front lidar sees, angular landmark rocks that roll under the rover or clear both scan planes, three more moon base buildings, and terrain, rocks and base parts the rover can either see or drive over. Each costmap scan gets its own obstacle layer so the rear scan no longer clears what only the front one sees.

Co-Authored-By: Claude Code <noreply@anthropic.com>
@bkanator
bkanator force-pushed the feat/18069-lunar-base-layout branch from a06d5de to 107731f Compare November 3, 2026 22:43
@bkanator bkanator changed the title Add boulders, a blast berm, and moon base equipment to lunar_sim as lidar landmarks Add landmark rocks, more moon base buildings, and a 30x30 m drivable area to lunar_sim for slam_toolbox mapping Nov 3, 2026
@github-actions

github-actions Bot commented Nov 3, 2026

Copy link
Copy Markdown

MoveIt Pro Example WS - Objectives Integration Test Report

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant