Update scene packages: recooked office/supermarket + lowpoly_tdm#2815
Update scene packages: recooked office/supermarket + lowpoly_tdm#2815Nabla7 wants to merge 5 commits into
Conversation
Packages recooked with the scene-cooking pipeline (cook_version 4: per-target visuals, objects.json). Adds the lowpoly_tdm map: floors split into flat-top boxes, ceiling skipped, 2x scale. Main's runtime already loads this format; split out of #2544 so the data lands first.
Codecov Report❌ Patch coverage is
@@ Coverage Diff @@
## main #2815 +/- ##
==========================================
- Coverage 72.02% 71.98% -0.05%
==========================================
Files 957 963 +6
Lines 84684 85582 +898
Branches 7689 7832 +143
==========================================
+ Hits 60991 61603 +612
- Misses 21648 21930 +282
- Partials 2045 2049 +4
Flags with carried forward coverage won't be shown. Click here to find out more.
... and 12 files with indirect coverage changes 🚀 New features to boost your workflow:
|
The legacy mujoco_process sim (used by go2's --simulation mujoco) could only load the baked-in data/mujoco_sim rooms. Route --scene-package through it so the cooked packages this PR ships (office, supermarket, lowpoly_tdm) work there too, without waiting for the MujocoSimModule migration. - model.py: load_scene() resolves a scene package to its wrapper.xml; get_assets()/load_model() accept extra asset dirs for the hull meshes - mujoco_process.py: per-package default spawn (office's default start pos lands outside the recooked geometry); --mujoco-start-pos still overrides - catalog.py: register lowpoly_tdm - mujoco_connection.py: pre-pull scene_packages LFS before the sim subprocess so extraction doesn't eat its ready timeout Verified: go1 walking policy stands 3s sim-time in office (-2.0, 1.6) and lowpoly_tdm (default spawn); no-package path unchanged.
| _SCENE_PACKAGE_SPAWNS: dict[str, tuple[float, float]] = { | ||
| "dimos_office": (-2.0, 1.6), | ||
| } |
There was a problem hiding this comment.
Missing spawn override for
lowpoly_tdm
The lowpoly_tdm map is cooked at 2× scale, meaning world coordinates are shifted relative to the default spawn. If the global mujoco_start_pos default (likely the origin) falls inside the scaled geometry, the robot will spawn clipped into a wall or floor. The test command in the PR description uses lowpoly_tdm without --start-pos, so a missing entry here silently falls back to the default coordinates. Consider adding a known-good entry for lowpoly_tdm (and optionally supermarket) if the default origin doesn't clear all geometry.
| for asset_dir in extra_asset_dirs: | ||
| mjx_env.update_assets(assets, epath.Path(str(asset_dir)), "*.obj") |
There was a problem hiding this comment.
Texture assets not loaded from scene package directories
get_assets only pulls *.obj from extra_asset_dirs. If any cooked MJCF scene file references texture files (e.g. *.png) relative to its own directory, those textures won't be in the assets dict and MuJoCo will fail to resolve them at load time. This is fine for purely collision-hull packages, but worth keeping in mind if future packages include visual textures in the MJCF.
Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!
Cooked scene packages put their collision hulls in geom group 3, which default MjvOption hides — the depth-camera lidar saw only the person mesh (group 0). Enable group 3 for the renderers and the viewer. Verified: lidar_front depth coverage in the office goes from 17 to 9760 of 14400 pixels.
The go1/g1 robot MJCFs keep their collision capsules in group 3 too, so enabling it unconditionally would render them in legacy rooms for no benefit. Scope it to scene-package runs, which need it to see the scene.
Problem
The scene-cooking PR (#2544) carried the recooked office/supermarket packages inside its diff, coupling ~1.6 GB of data to a code review. And there's a new scene to ship.
Solution
Data-only PR that lands ahead of #2544 (main's runtime already loads this package format — verified with main's loader):
dimos_officeandsupermarketrecooked with the scene-cooking pipeline (cook_version 4: per-target visuals,objects.jsonpicking sidecar).lowpoly_tdm— a small low-poly test map. Cooked at 2x scale with a hand-tuned sidecar: the floors mesh is split into per-plate flat-top boxes (walkable, no hull seams) and the map's ceiling plate is skipped. Source: "LOWPOLY FPS TDM GAME MAP" by ResoForge.data/.lfs/scene_packages.tar.gz, regenerated via./bin/lfs_push).#2544 no longer touches this archive.
How to Test
Contributor License Agreement
🤖 Generated with Claude Code