Skip to content

Accelerate and strengthen asset tests [9/13] - #8149

Closed
AntoineRichard wants to merge 6 commits into
isaac-sim:developfrom
AntoineRichard:antoiner/asset-tests-p16-physx-deformable
Closed

AntoineRichard wants to merge 6 commits into
isaac-sim:developfrom
AntoineRichard:antoiner/asset-tests-p16-physx-deformable

Conversation

@AntoineRichard

@AntoineRichard AntoineRichard commented Sep 29, 2026 •

Copy link
Copy Markdown
Collaborator

Description

Part 9/13 of the asset-test series (tracker: #7282). Scope: PhysX deformable and surface gripper. No dependencies.

What changed

Deformables. On develop, the whole PhysX deformable suite is skipped because it intermittently aborted in CI, so none of its 12 tests run. This PR replaces it with one CUDA scene of locally authored meshes: a five-node, two-tetrahedron volume body and a four-node surface body, two environments each, each with its own bound material. Both meshes are authored with their simulation topology, so no mesher or collision cooking runs. The tests check:

  • view and material discovery, and nodal buffer shapes;
  • that only volumes carry kinematic targets, and that the surface target write raises its error;
  • partial nodal-state writes that preserve environment 0 in the PhysX view;
  • the transformed default nodal state, read back from the PhysX view;
  • volume kinematic targets holding environment 0 while environment 1 moves;
  • the CPU rejection, matched by its error message.

Five consecutive local runs passed. Because the old suite was disabled for CI aborts, please watch the first CI runs.

Surface gripper. The gripper and two stacked cubes are authored locally instead of loading the Nucleus test_gripper.usd articulation:

  • Open/close seam: kept with the same assertions and the existing CI skip, because the SurfaceGripperView initialization can deadlock in CI.
  • CUDA rejection: checked on the local fixture.
  • New unit/test_physx_surface_gripper.py: runs in CI with a recording view. It checks that only open/close commands are submitted and that partial property updates keep the selector order.

CI does not validate the locally authored gripper. The open/close test is skipped whenever CI, GITHUB_ACTIONS or GITLAB_CI is set, as on develop, and the CUDA rejection raises on the first line of initialization, before any prim is resolved. The gripper authoring is exercised only by local runs of the open/close test, which pass on this branch.

Disposition

The deformable tests never ran on develop (all 12 skipped), so that part only adds coverage. They depended on cooked cuboid meshes; the new probes do not. The last column lists cases that were latent on develop and are not carried over.

Removed develop test Keeper Proof / latent cases not carried over
test_initialization (deformable, 4 material cases) test_deformable_initialization (volume) skipped on develop; not carried: a material shared by path (material_physx_view.count == 1), no material (material_physx_view is None), one-instance scene
test_initialization_surface_deformable test_deformable_initialization (surface) skipped on develop; none
test_initialization_on_device_cpu same test skipped on develop; now matches the error message
test_set_nodal_state test_deformable_nodal_state_writes skipped on develop; mutation: full-environment nodal positions not written. Not carried: five write/reset() cycles with settling steps
test_set_nodal_state_with_applied_transform (4 cases) test_deformable_nodal_state_writes (transformed default state) skipped on develop; same mutation. Not carried: the 50-step settle after reset()
test_set_kinematic_targets test_volume_kinematic_targets_hold_selected_nodes skipped on develop; not carried: five reset() cycles; the hold runs 5 steps instead of 20
test_close_and_open_command same test, local gripper same assertions; CI skip kept
test_raise_error_if_not_cpu same test, local gripper same assertion

Devices and CI selection

  • The deformable scene runs on CUDA (PhysX deformables require it); the CPU rejection test runs on CPU. The gripper open/close test runs on CPU and the rejection test on CUDA, as on develop.
  • Every deformable test carries @pytest.mark.isaacsim_ci; both gripper tests keep it, as on develop.

Timing

Warm Warp cache, repository orchestrator (pytest tools), one process per file, second of two runs, RTX 5090. develop is 09b1d54; this branch is 69e38f9.

Times are the per-file process wall times the orchestrator reports, including interpreter and Kit startup.

File develop This branch
test_deformable_object.py 2.2 s (0 run, 12 skipped) 3.3 s (4 tests)
test_surface_gripper.py 5.7 s (2 tests) 3.5 s (2 tests)
unit/test_physx_surface_gripper.py (new) — 1.5 s (1 test)
Total 7.9 s 8.3 s

The deformable file now runs 4 tests where develop ran none; the surface-gripper file is 2.2 s faster without the Nucleus asset.

Type of change

  • Test-suite redesign (no production change)

Release backport

  • Backport this pull request to the active release branch after it merges into develop

Checklist

Docker and GPU tests run on demand. Push the commits you want tested, then
comment run-ci on the pull request.

  • I have read and understood the contribution guidelines
  • I have run the pre-commit checks with uv run isaaclab --format
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have validated the changed behavior with focused coverage and applied the test-audit criteria to any test changes
  • I have added a changelog fragment under source/<pkg>/changelog.d/ for every touched package (do not edit CHANGELOG.rst or bump package versions — CI handles that)
  • I have added my name to the CONTRIBUTORS.md or my name already exists there

Replace the disabled deformable suite with one scene of surface and
volume meshes authored with their simulation topology, so no mesher or
collision cooking runs. Check view and material discovery, partial nodal
writes, the transformed default state, kinematic targets, the surface
target rejection, and the CPU rejection.
Author the gripper and its two cubes locally instead of loading a
Nucleus articulation, keep the CI skip for the real open/close seam, and
check the command filtering and partial property payloads with a
recording view so they are covered in CI.
@AntoineRichard
AntoineRichard requested a review from a team September 29, 2026 12:48
@github-actions github-actions Bot added the isaac-lab Related to Isaac Lab team label Sep 29, 2026
@greptile-apps

greptile-apps Bot commented Sep 29, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerConfidence Score: 4/5

[Medium risk] Rewrites deformable object test suite with new structure.

The PR is not ready to merge because CI will deselect all three new CUDA tests.

Findings

  1. P1 CUDA tests are deselected ▶
  2. P2 Transformed state is not stepped ▶

Summary

The PR replaces a disabled deformable-object suite with locally authored volume and surface meshes and tests for initialization, nodal writes, kinematic targets, and CPU rejection.

  • CI currently selects only the CPU test, so the new CUDA coverage will not run there.
  • The transformed-state assertion does not check behavior after simulation advances.

Reviews (1) · Last reviewed commit: "Cover PhysX deformables with locally aut..."

)
root_pos_w = cube_object.data.root_pos_w.torch
assert torch.all(root_pos_w[1:, 2] < default_root_pos[1:, 2])
def test_deformable_initialization(deformable_scene: _DeformableScene):

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 CUDA tests are deselected. The CI orchestrator runs this file with -m isaacsim_ci, but only the CPU test has that marker. All three new CUDA tests are therefore deselected in CI, leaving the deformable coverage this PR intends to restore unrun.

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!

Comment on lines +230 to +231
volume.write_nodal_state_to_sim_index(nodal_state)
torch.testing.assert_close(volume.data.root_pos_w.torch, nodal_pos.mean(dim=1))

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Transformed state is not stepped. The root-position assertion immediately follows the write and reads a mean derived from the just-written nodal buffer. Without a simulation step and a post-step check, this test cannot catch a regression in how PhysX handles the rotated state during simulation.

@AntoineRichard
AntoineRichard marked this pull request as draft September 29, 2026 12:54
Apply the body schemas where they are authored, type and document the authoring helper, and annotate the tests and the scene fixture.
Also drop a comment that narrated the simulation step.
The transformed default-state write is now checked against the PhysX
nodal positions instead of the Lab buffer it just wrote. The CPU
rejection matches its error message, and every test carries the Isaac
Sim CI marker.
@AntoineRichard AntoineRichard changed the title Accelerate and strengthen asset tests [16/24] Accelerate and strengthen asset tests [9/13] Sep 29, 2026
@StafaH

StafaH commented Oct 3, 2026

Copy link
Copy Markdown
Collaborator

Closing because the combined PR #7282 has merged. This split PR is superseded by #7282 and is no longer needed.

@StafaH StafaH closed this Oct 3, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

isaac-lab Related to Isaac Lab team

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants