Fix PhysX collision filtering in direct tasks - #6855
Conversation
Apply per-environment collision groups for manual direct-workflow cloning on every PhysX simulation device. Without these groups, CUDA replicas collide across environments and joint efforts become ineffective. Add a Cartpole regression that verifies every cloned articulation accelerates consistently under a constant effort. Fixes isaac-sim#5302
Greptile SummaryThis PR extends explicit inter-environment collision filtering from CPU-only execution to every PhysX simulation device in manually cloned direct-workflow tasks, while leaving non-PhysX backends unchanged.
Confidence Score: 5/5The PR appears safe to merge, with no concrete changed-code failure established. The collision-filtering calls are consistently restricted to PhysX, preserve identified shared collider paths, and the new regression exercises the affected CUDA replication path with compatible action and articulation data shapes. Important Files Changed
Flowchart%%{init: {'theme': 'neutral'}}%%
flowchart LR
A[Spawn environment 0 assets] --> B[Build clone plan]
B --> C[Replicate environments]
C --> D{Physics backend contains physx?}
D -- Yes --> E[Filter collisions between environment replicas]
D -- No --> F[Leave backend behavior unchanged]
E --> G[Register cloned assets with scene]
F --> G
Reviews (1): Last reviewed commit: "Fix PhysX collision filtering in direct ..." | Re-trigger Greptile |
There was a problem hiding this comment.
Isaac Lab Review Bot
Reviewed the backend-based collision-filtering change across all 11 manual direct-workflow cloning paths, including the newly added calls in handover and reorient environments, plus the Cartpole regression and changelog fragment. The patch consistently extends filtering from CPU-only execution to every PhysX device while leaving Newton paths unchanged.
- Design and architecture: Collision filtering remains immediately after
cloner.replicate()and before scene registration. Gating onscene.physics_backendrather than the simulation device aligns the behavior with the PhysX replication mechanism without altering Newton execution. - API: No public signatures, exports, configuration fields, or defaults change. Existing filtering calls preserve their global terrain or ground paths, while newly added calls use the ground prims spawned by their environments or an empty global path list where no ground is spawned.
- Implementation: The changed setup paths and their ground or terrain prims were traced across all 11 environment files. The Cartpole test directly exercises CUDA PhysX replicas under constant effort and checks both acceleration and cross-environment consistency. Non-blocking tradeoffs are the test's intentional
cuda:0dependency and the pre-existing argument-freefilter_collisions()call in Factory, which is now also exercised on CUDA PhysX.
No blocking issues. No inline issue met the actionable-evidence threshold; the assessment above records the review feedback.
Automated review; human maintainers own approval decisions.
Record the per-environment collision groups introduced by the direct-task filtering fix so rendering correctness tests validate the intended stage.
| @@ -0,0 +1,49 @@ | |||
| # Copyright (c) 2022-2026, The Isaac Lab Project Developers (https://github.com/isaac-sim/IsaacLab/blob/main/CONTRIBUTORS.md). | |||
There was a problem hiding this comment.
Is this test necessary? I think there are other tests (test_environments) that already provide this coverage
AntoineRichard
left a comment
There was a problem hiding this comment.
Agree with @StafaH on the test
Description
Fixes #5302.
Fixes #6853.
Manual direct-workflow tasks call the cloner after spawning their assets, but most of them only authored per-environment collision groups on CPU—or did not author them at all. The PhysX replication path currently uses USD collision filtering instead of PhysX environment IDs, so CUDA replicas could collide across environments and constrain articulated joints despite valid effort targets.
This change:
The deterministic 4,096-environment reproduction now reports identical cart velocity in every environment after 20 steps at 100 N:
Type of change
Screenshots
Not applicable.
Validation
10^-6 m/s.uv run isaaclab -fuv run --no-sync python tools/changelog/cli.py check issue-5302-baseChecklist
CONTRIBUTORS.md.