Fix Viser rendering for simulation axis markers - #511
Merged
Conversation
Export SimulationManager axis markers as frame overlays with their world poses and dimensions. Keep them visible in headless mode and cover the exporter/backend behavior with regression tests.
Greptile SummaryThis PR exports active simulation axis markers as backend-neutral frame overlays so Viser can render their world pose and dimensions.
Confidence Score: 5/5The PR appears safe to merge. No blocking failure remains.
|
| Filename | Overview |
|---|---|
| embodichain/lab/sim/sim_manager.py | Records active axis marker handles, arena ownership, and display dimensions for backend-neutral export. |
| embodichain/lab/visualization/scene_exporter.py | Converts registered axis markers into uniquely identified frame overlays and merges them with caller overlays. |
| tests/visualization/test_scene_exporter.py | Verifies headless marker export, pose and dimensions, and collision handling with caller-owned frame IDs. |
| tests/visualization/test_viser_backend.py | Verifies that marker frame overlays reach Viser with the expected path, pose, dimensions, and visibility. |
Reviews (2): Last reviewed commit: "fix(visualization): avoid marker overlay..." | Re-trigger Greptile
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
This PR exports coordinate-frame markers created through
SimulationManager.draw_marker()as backend-neutral frame overlays so they render in Viser with the correct world pose, axis length, and radius.In headless Viser runs, native DexSim axis handles report
is_visible() == Falseeven when the marker was requested for display. The exporter now treats registered marker groups as visible untilremove_marker()removes them, preventing target frames from being hidden while preserving marker lifecycle behavior.Dependencies: None.
Issue: None.
Type of change
Screenshots
/worldcoordinate frame was visible; simulation target markers were hidden.coordinated_placement.pydisplays both support-pan and placing-bread target frames at their expected poses.Validation
conda run -n open black --check --diff --color ./— 904 files unchangedconda run -n open pytest -q tests/visualization/test_scene_exporter.py tests/visualization/test_viser_backend.py tests/sim/test_sim_manager.py— 48 passedconda run --no-capture-output -n open python scripts/tutorials/atomic_action/coordinated_placement.py --viser --viser-port 8769 --diagnose_plan— axis stage reached successfullyChecklist
black .command to format the code base.