Repository navigation
Description
Proposal
Update Newton RigidObjectCollection path matching so it does not merge specific body paths into a broad wildcard. _build_combined_pattern() should not turn sibling paths such as /World/envs/env_*/Object_A, /World/envs/env_*/Object_B, and /World/envs/env_*/Object_C into /World/envs/env_*/* when that pattern can also match other rigid bodies.
The fix should make the Newton view bind only the configured collection bodies, or raise a clear error when exact matching is not possible.
Motivation
The current wildcard merge can include unrelated rigid bodies in the Newton ArticulationView. This breaks the collection's env/body counts and causes a runtime shape error.
Reproduction:
./isaaclab.sh -p scripts/demos/multi_asset.py --visualizer newton --physics newton_mjwarp --num_envs 1024The same failure also reproduces with --visualizer none, so the issue is not specific to the Newton GL visualizer.
Observed failure:
RuntimeError: The size of tensor a (1706) must match the size of tensor b (1024) at non-singleton dimension 0
The demo reset expects num_envs == 1024, but Newton reports num_instances == 1706 for the collection:
scene.env_origins: (1024, 3)
root_view.count: 5120
body_link_pose_w: (1024, 5, 7)
default_body_pose: (1706, 3, 7)
collection.num_bodies: 3
collection.num_instances: 1706
Configured collection paths:
/World/envs/env_.*/Object_A
/World/envs/env_.*/Object_B
/World/envs/env_.*/Object_C
Current combined pattern:
/World/envs/env_*/*
That pattern matches five bodies per env:
/World/envs/env_<i>/Robot/base
/World/envs/env_<i>/Object
/World/envs/env_<i>/Object_A
/World/envs/env_<i>/Object_B
/World/envs/env_<i>/Object_C
Only the last three belong to the collection.
Build Info
- Isaac Lab Version: On top of Support Multi-Back for Demo Scripts (Part 2) and Unify Code Structure #6140
- Isaac Lab Contrib Version: 0.4.4
- Isaac Lab Newton Version: 0.15.2
- Isaac Sim Version: 6.0.0-alpha.212
Checklist
- I have checked that there is no similar issue in the repo (required)
Activity
AntoineRichard commentedon Jun 12, 2026
Thanks! Yes this is a known limitation of the selection API. As soon as newton-physics/newton#3071 lands and they modify the bare fnmatch with this new system in the main pattern matching method, we will be able to modify the newton collection code to send list of patterns. @adenzler-nvidia for viz.
yusufdxb commentedon Sep 29, 2026
I reproduced this issue on current
develop(eb6617c) with the Newton backend. With collection membersObject_AandObject_Band an unrelated rigid bodyObject_Targetin the same environment, the merged pattern/World/Env_*/Object_*matches three bodies per world and initialization fails. With members at different depths (Object_A,Shelf/Object_B), the combined pattern cannot be built at all.Newton 1.6.0, the pinned version, now accepts a list of patterns in
ArticulationView. I have a small tested patch that implements the approach @AntoineRichard suggested above: pass the member patterns directly and remove_build_combined_pattern. It includes regression tests for both cases.@StafaH, are you already working on this? If not, are you okay with me opening the PR?
StafaH commentedon Sep 29, 2026
Sure, feel free to open a PR for this and we can take a look
Match Newton rigid object collection bodies exactly (isaac-sim#8175)