Skip to content

Initialize OVPhysX joint-wrench bindings before render cloning - #9333

Merged
r-schmitt merged 4 commits into
isaac-sim:mainfrom
r-schmitt:dev/rschmitt/early_joint_wrench_binding
Dec 3, 2026
Merged

r-schmitt merged 4 commits into
isaac-sim:mainfrom
r-schmitt:dev/rschmitt/early_joint_wrench_binding

Conversation

@r-schmitt

@r-schmitt r-schmitt commented Dec 1, 2026 •

Copy link
Copy Markdown
Collaborator

Reduce shared OVStage startup work for Isaac-Reorient-Cube-Shadow-Camera-Direct by resolving joint-wrench bindings through explicit articulation paths from the clone plan.

Remove the separate binding-readiness event and prepare native physics consumers directly during OVPhysX runtime initialization. Assets, contact sensors, and joint-wrench sensors initialize after native cloning and warmup, before deferred render copies and public PHYSICS_READY callbacks.

  • Remove PhysicsManager.binding_init_event, SensorBase.initialize_event, and the OVPhysX binding event.
  • Keep PHYSICS_READY as the public readiness event, preserving existing callback priorities and owned-stage initialization order.
  • Track consumers through weak references, honor callback deregistration, and retain idempotent initialization.
  • Prepare late-created consumers on subsequent non-soft resets and reinitialize consumers after runtime rebuilds.
  • Complete and seal deferred render copies before public readiness callbacks can write stage data.
  • Use the upstream public expand_env_pattern helper for joint-wrench path resolution.

Validation

  • 73 focused tests passed on current main with OVPhysX 0.8.1, covering lifecycle handling, joint-wrench/contact sensors, rigid-object collections, and deformables.
  • Verified shared-stage consumers initialize before public callbacks, including callbacks at priority −1000.
  • Verified late-created consumers, runtime rebuilds, and soft-reset behavior.
  • Seeded shared-main versus PR captures produced bitwise-identical RGB, policy observations, and wrench values.
  • Formatting, lint, changelog checks, and git diff --check passed.

Local legacy / main / PR comparison

Main revision: 467b3457
PR revision: 47049eac

All three arms used the same machine and library versions:

  • AMD Ryzen Threadripper PRO 3975WX
  • RTX PRO 6000 Blackwell Workstation Edition, driver 615.71.09
  • OVPhysX 0.8.1.45833638316
  • OVRTX 0.7.0.1794596436
  • OVStage 0.4.0.1794520352

Workload: 1,225 environments, 64×64 RGB cameras, 50 warmup steps, and 100 measured simulation steps.

Each arm received one excluded application warmup, followed by three unprofiled repetitions in balanced order. Application caches were retained.

Measurement Legacy on main Shared OVStage on main Shared OVStage with PR
Startup KPI — median 17.172 s 17.713 s 17.485 s
Startup KPI — mean 17.155 s 17.832 s 17.509 s
Initial reset-return observation — median 21.405 s 28.967 s 23.077 s
Wrench initialization — diagnostic 155.85 ms 159.09 ms 7.59 ms

The PR’s startup median was 1.3% lower than shared main and 1.8% above legacy main.

Release backport

  • Backport to release/3.1.0 after this pull request merges into main.

@r-schmitt
r-schmitt requested a review from a team December 1, 2026 20:14
@github-actions github-actions Bot added the isaac-lab Related to Isaac Lab team label Dec 1, 2026
@r-schmitt

Copy link
Copy Markdown
Collaborator Author

run-ci ovstage

@isaaclab-bot isaaclab-bot Bot added ci:run-ovstage Run the opt-in OVStage rendering correctness lane and removed ci:run-ovstage Run the opt-in OVStage rendering correctness lane labels Dec 1, 2026
@greptile-apps

greptile-apps Bot commented Dec 1, 2026 •

Copy link
Copy Markdown
Contributor

Confidence Score: 5/5RetriggerView in Greptile

[Medium impact] The PR appears safe to merge; no actionable defects were found.

Summary

Removes the separate binding-readiness event while keeping PHYSICS_READY as the public readiness event.

  • Shared-stage physics consumers are ready before public callbacks run.
  • Joint-wrench sensors select articulations from clone-plan paths.

The previous-review range was not used because its merge base differs from the current PR’s merge base. The full PR was reviewed. No actionable issues were found. Tests were inspected but not run.

Diagram

%%{init: {'theme': 'neutral'}}%%
flowchart TD
  A[Attach native physics and clone] --> B[Run warmup]
  B --> C[Publish MODEL_INIT]
  C --> D{Borrowed stage?}
  D -->|Yes| E[Prepare registered physics consumers]
  E --> F[Acquire scene-data bindings]
  F --> G[Complete and seal deferred render copies]
  D -->|No| H[Publish PHYSICS_READY]
  G --> H
  H --> I[Run public callbacks in priority order]
Loading

Reviews (2) · Last reviewed commit: "expand_env_pattern" · Reviewed by Greptile

@isaaclab-review-bot isaaclab-review-bot Bot left a comment

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.

Isaac Lab Review Bot

Needs attention: Style consistency (1). Other reviewed categories look good.

  • PR description: The title and body match the diff and report workload, hardware, backends, counts, repetitions, and startup metrics; add exact revisions, commands, software environment, and warmup procedure to make the performance comparison reproducible.
  • Design and architecture: Architecture looks good.
  • Scope and over-engineering: No over-engineering issues.
  • API: API changes look good.
  • Compatibility and deprecation: No breaking changes identified.
  • Implementation: Implementation looks good.
  • Style consistency: The test docstring claims consumer access before render cloning, but the callback only checks is_initialized; describe readiness at the binding event instead.
  • Test quality: Test quality looks good.

Minor fixes needed. Posted 1 inline finding.

Automated review; human maintainers own approval decisions.

"""Sensor initializes on sim reset and exposes correctly-shaped buffers."""
@pytest.mark.parametrize("device,shared", [("cuda:0", True), ("cpu", False)])
def test_initialization_and_shapes(sim, device, shared):
"""Binding-ready consumers can use the initialized sensor before rendering copies."""

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.

🟡 Warning · Style Consistency — Match the readiness assertion

The callback checks is_initialized; it does not use sensor data before rendering copies. Describe the readiness check rather than claiming consumer access.

@ooctipus ooctipus left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

will try find alternative as discussed offline

@r-schmitt
r-schmitt force-pushed the dev/rschmitt/early_joint_wrench_binding branch from 10f26f1 to 789fcf6 Compare December 2, 2026 14:23
@github-actions github-actions Bot added the documentation Improvements or additions to documentation label Dec 2, 2026
@r-schmitt r-schmitt changed the title init ovphysx joint-wrench bindings before shared ovstage render cloning remove PhysicsManager.binding_init_event Dec 2, 2026
@r-schmitt

Copy link
Copy Markdown
Collaborator Author

run-ci ovstage

@isaaclab-bot isaaclab-bot Bot added ci:run-ovstage Run the opt-in OVStage rendering correctness lane and removed ci:run-ovstage Run the opt-in OVStage rendering correctness lane labels Dec 2, 2026
@r-schmitt
r-schmitt requested a review from ooctipus December 2, 2026 15:05
@r-schmitt

Copy link
Copy Markdown
Collaborator Author

run-ci ovstage

@isaaclab-bot isaaclab-bot Bot added ci:run-ovstage Run the opt-in OVStage rendering correctness lane and removed ci:run-ovstage Run the opt-in OVStage rendering correctness lane labels Dec 2, 2026
@ooctipus ooctipus changed the title remove PhysicsManager.binding_init_event Initialize physics consumers through standard readiness Dec 2, 2026
@ooctipus

ooctipus commented Dec 2, 2026

Copy link
Copy Markdown
Collaborator

run-ci ovstage

@ooctipus ooctipus changed the title Initialize physics consumers through standard readiness Initialize OVPhysX joint-wrench bindings before render cloning Dec 3, 2026
@r-schmitt
r-schmitt force-pushed the dev/rschmitt/early_joint_wrench_binding branch from 06cfd52 to b1c0c08 Compare December 3, 2026 01:07
@r-schmitt

Copy link
Copy Markdown
Collaborator Author

run-ci ovstage

@isaaclab-bot isaaclab-bot Bot added ci:run-ovstage Run the opt-in OVStage rendering correctness lane and removed ci:run-ovstage Run the opt-in OVStage rendering correctness lane labels Dec 3, 2026
@r-schmitt
r-schmitt enabled auto-merge (squash) December 3, 2026 01:11
@r-schmitt
r-schmitt merged commit c1f10c3 into isaac-sim:main Dec 3, 2026
139 of 192 checks passed
@r-schmitt
r-schmitt deleted the dev/rschmitt/early_joint_wrench_binding branch December 3, 2026 01:43
kellyguo11 pushed a commit to kellyguo11/IsaacLab-public that referenced this pull request Dec 3, 2026
…-sim#9333)

Reduce shared OVStage startup work for
`Isaac-Reorient-Cube-Shadow-Camera-Direct` by resolving joint-wrench
bindings through explicit articulation paths from the clone plan.

Remove the separate binding-readiness event and prepare native physics
consumers directly during OVPhysX runtime initialization. Assets,
contact sensors, and joint-wrench sensors initialize after native
cloning and warmup, before deferred render copies and public
`PHYSICS_READY` callbacks.

- Remove `PhysicsManager.binding_init_event`,
`SensorBase.initialize_event`, and the OVPhysX binding event.
- Keep `PHYSICS_READY` as the public readiness event, preserving
existing callback priorities and owned-stage initialization order.
- Track consumers through weak references, honor callback
deregistration, and retain idempotent initialization.
- Prepare late-created consumers on subsequent non-soft resets and
reinitialize consumers after runtime rebuilds.
- Complete and seal deferred render copies before public readiness
callbacks can write stage data.
- Use the upstream public `expand_env_pattern` helper for joint-wrench
path resolution.

## Validation

- 73 focused tests passed on current main with OVPhysX 0.8.1, covering
lifecycle handling, joint-wrench/contact sensors, rigid-object
collections, and deformables.
- Verified shared-stage consumers initialize before public callbacks,
including callbacks at priority −1000.
- Verified late-created consumers, runtime rebuilds, and soft-reset
behavior.
- Seeded shared-main versus PR captures produced bitwise-identical RGB,
policy observations, and wrench values.
- Formatting, lint, changelog checks, and `git diff --check` passed.

### Local legacy / main / PR comparison

Main revision: `467b3457`
PR revision: `47049eac`

All three arms used the same machine and library versions:

- AMD Ryzen Threadripper PRO 3975WX
- RTX PRO 6000 Blackwell Workstation Edition, driver 615.71.09
- OVPhysX `0.8.1.45833638316`
- OVRTX `0.7.0.1794596436`
- OVStage `0.4.0.1794520352`

Workload: 1,225 environments, 64×64 RGB cameras, 50 warmup steps, and
100 measured simulation steps.

Each arm received one excluded application warmup, followed by three
unprofiled repetitions in balanced order. Application caches were
retained.

| Measurement | Legacy on main | Shared OVStage on main | Shared OVStage
with PR |
| --- | ---: | ---: | ---: |
| Startup KPI — median | 17.172 s | 17.713 s | 17.485 s |
| Startup KPI — mean | 17.155 s | 17.832 s | 17.509 s |
| Initial reset-return observation — median | 21.405 s | 28.967 s |
23.077 s |
| Wrench initialization — diagnostic | 155.85 ms | 159.09 ms | 7.59 ms |

The PR’s startup median was **1.3% lower than shared main** and **1.8%
above legacy main**.

## Release backport

- [x] <!-- backport-active-release --> Backport to `release/3.1.0` after
this pull request merges into `main`.

(cherry picked from commit c1f10c3)
kellyguo11 added a commit that referenced this pull request Dec 3, 2026
…ion (#9368)

## Description

Backport fourteen merged PRs to `release/3.1.0`:

| Original PR | Change |
| --- | --- |
| #9359 | Let CI recover after Warp and OVRTX cache eviction; allow
cold-cache demo startup. |
| #9292 | Detect UTF-8 and BOM-marked UTF-16 YAML input and write UTF-8
independently of the system locale. |
| #9346 | Update the Isaac Sim CI image digest to `6745f1725c9b`. |
| #9334 | Bind cloned deformable state and materials in clone-plan
environment order. |
| #9172 | Update and pin setup-uv and cache actions in performance CI. |
| #9062 | Resolve ray-caster mounts through shared frame views and fix
Kuka-Allegro camera mounts and missed-ray clipping. |
| #9247 | Use floating-point digital-filter coefficients when
configuration literals are integers. |
| #9285 | Support scalar shapes in uniform, triangular, and log-uniform
random sampling. |
| #9333 | Initialize OVPhysX physics consumers and joint-wrench bindings
before deferred render cloning. |
| #9366 | Add the success-guided reset sampling paper citation to the
NIST package docstring. |
| #9369 | Mark ARM64 OptiX rendering tests as expected failures without
starting the unsupported runtime. |
| #9365 | Fix documented GR00T N1.7 installation with explicit tyro and
Git LFS/source-override handling. |
| #9270 | Upgrade Newton, MuJoCo/MuJoCo Warp 4.1, Warp 1.20, USD
schemas, and LEAPP, with required runtime and converter compatibility
changes. |
| #9317 | Preserve convex-hull collider types when constructing the
implicit MPM solver. |

Cherry-picked with `-x`, preserving one commit per source PR. The first
six were applied in merge order (#9334, #9062, #9292, #9359, #9346,
#9172), followed by #9247, #9285, #9333, #9366, #9369, #9365, #9270, and
#9317. All fourteen applied without conflicts or manual edits. Every
stable patch ID matches its original merge commit. Original
documentation, regression tests, and changelog fragments are preserved.

### Compatibility

These are the original PRs in full, including their compatibility
changes and version markers:

- #9292: legacy locale-encoded YAML must be converted to UTF-8.
- #9062: ray casters require an existing mount frame; the old
Newton/OVPhysX synthetic mounting behavior is removed. The shared
FrameView transform API is added. Kuka-Allegro missed rays now clip at
2.5 m, changing observations seen by previously trained policies.
- #9333: removes unreleased internal binding-event plumbing; public
`PhysicsEvent.PHYSICS_READY` subscriptions and callback priorities
remain supported. This includes the lifecycle changes from the original
PR.

- #9270: upgrades core dependencies and includes breaking API removals.
Actuators use `command_interface` / `command_interface_state` and
`drive`; Newton sensors use solver observables. Removed options include
`MujocoCollisionCfg.solmix`, `MJWarpSolverCfg.update_data_interval` /
`ls_parallel`, and `KaminoPADMMCfg.compl_tolerance`;
`soft_contact_margin` becomes `soft_contact_gap`. Native MuJoCo CPU
simulation requires one world. The temporary MJCF converter patch and
original migration documentation are included. ARM OptiX requires an
R590+ driver; #9369 retains the expected failure on current ARM CI.

## Type of change

- Release backport: bug fixes, dependency upgrades, compatibility
changes, CI updates, tests, and documentation.

## Validation

Latest combined head: `1a2304c75`. The branch includes a merge of
release tip `7cfe2659f` in `9f60679bc`; existing changes from that merge
are preserved.

### Final combined-head checks

- Full repository formatting/lint, changelog validation against
`upstream/release/3.1.0`, and `git diff --check upstream/release/3.1.0`
passed at `1a2304c75`.
- #9317 applied without conflicts and its stable patch ID matches the
original. Its required Newton revision
`838ddf544927333559af894dfba0edb1a9efba04` is already locked through
#9270.
- Focused MPM tests were attempted with `uv run --no-sync python -m
pytest source/isaaclab_newton/test/physics/test_newton_solvers.py -k mpm
-q`; collection is blocked by the missing `isaaclab_newton` installation
in this macOS environment. The CUDA regression requires
supported-platform CI.

### Earlier thirteen-backport checks

- Full repository formatting/lint passed:
`ISAACLAB_CHANGELOG_BASE_REF=upstream/release/3.1.0 uv run --no-sync
isaaclab --format`.
- Changelog validation against `upstream/release/3.1.0` and `git diff
--check upstream/release/3.1.0` passed.
- #9270 applied without conflicts and its stable patch ID matches the
original. Its original dependency lock, wheel overrides, runtime
adaptations, tests, golden image, and changelog fragments are preserved.
- Root dependency metadata: **13 passed**; wheel-builder metadata: **14
passed**, using `uv run --no-sync python -m pytest` on the corresponding
CLI test files.
- Reset-state buffers: **7 passed, 1 skipped** in the existing macOS
environment. This environment still has Warp **1.17.0**, so this result
does not validate the new Warp 1.20 runtime.
- Confirmed the lock selects Warp 1.20.0, MuJoCo/MuJoCo Warp 4.1.0,
Newton USD schemas 0.8.0, and Newton revision
`838ddf544927333559af894dfba0edb1a9efba04`.
- Updated dependency installation, GPU simulation/rendering, and a clean
docs build remain unvalidated locally. Earlier runtime test results
below predate #9270 and do not establish compatibility with the upgraded
dependencies.

### Earlier twelve-backport checks

- Full repository formatting/lint, changelog validation against
`upstream/release/3.1.0`, and `git diff --check upstream/release/3.1.0`
passed at `26293b3bc`.
- #9365 applied without conflicts and its stable patch ID matches the
original. It changes only the GR00T installation documentation;
`pyproject.toml` and `uv.lock` are unchanged by this cherry-pick.
- The updated installation command block passed `bash -n`. External
GR00T installation and training were not rerun locally.
- Clean docs validation remains outstanding on a supported platform, as
detailed below.

### Earlier eleven-backport checks

- Full repository formatting/lint, changelog validation against
`upstream/release/3.1.0`, and `git diff --check upstream/release/3.1.0`
passed at `2a7783ebe`.
- #9369 applied without conflicts and its stable patch ID matches the
original.
- Evaluated the actual OptiX xfail decorator for `aarch64`, `arm64`,
`x86_64`, and `AMD64`: only ARM64 enables `xfail(run=False)`; Newton
Warp tests retain no xfail marker.
- GPU rendering was not rerun locally.

### Earlier ten-backport checks

The following checks passed at `97dc765f9`, before the test-marker-only
#9369 cherry-pick:

- Full repository formatting/lint checks passed:
`ISAACLAB_CHANGELOG_BASE_REF=upstream/release/3.1.0 uv run --no-sync
isaaclab --format`.
- Changelog check passed: `uv run --no-sync python
tools/changelog/cli.py check upstream/release/3.1.0 --include-worktree`.
- `git diff --check upstream/release/3.1.0` passed.
- All ten stable patch IDs match their source commits.
- Tensor processors: **13 passed**, using `uv run --no-sync python -m
pytest source/isaaclab/test/utils/test_tensor_processors.py -q`.
- Direct CPU checks passed for scalar, batched, and empty requests in
uniform, triangular, and log-uniform sampling, plus integer-coefficient
digital-filter unit-delay behavior. The scalar-sampling and
integer-coefficient bugs were reproduced before these fixes were added.
- The existing uv interpreter and imported core package were verified to
point at this checkout.

### Earlier six-backport checks

The following passed at `2afdfd8be`, before the four additional
cherry-picks, using `uv run --no-sync python -m pytest <file> -q`, one
file per process:

- YAML I/O: **8 passed**.
- Clone-plan algebra: **32 passed, 5 skipped**.
- Ray-caster kernels: **17 passed**.

### Remaining validation

- Validation used the existing uv environment on macOS because normal uv
resolution rejects this platform; the committed lockfile supports Linux
and Windows only.
- A clean docs build was attempted for the initial six-backport head
with `uv run --no-sync isaaclab --docs`; its nested uv invocation was
blocked by that platform restriction. The expanded documentation changes
still need a supported-platform build.
- GPU/OVPhysX/Newton simulation integration, including the #9333
lifecycle changes, and cold-cache demos have not been rerun locally for
this combined backport.
- No complete CI result is claimed for the latest combined head.

## Checklist

- [x] Read the contribution guidelines.
- [x] Run full repository formatting and lint checks.
- [x] Preserve original documentation, tests, and package changelog
fragments.
- [x] Verify all fourteen cherry-picks match the original patches.
- [x] Run focused locally supported checks.
- [ ] Complete clean docs and GPU integration validation on supported
platforms.

---------

Signed-off-by: Sylvester Kaczmarek <[email protected]>
Co-authored-by: ooctipus <[email protected]>
Co-authored-by: YuTeh Shen <[email protected]>
Co-authored-by: Claude Opus 5.5 <[email protected]>
Co-authored-by: Sylvester Kaczmarek <[email protected]>
Co-authored-by: hujc <[email protected]>
Co-authored-by: isaaclab-bot[bot] <282401363+isaaclab-bot[bot]@users.noreply.github.com>
Co-authored-by: fanes <[email protected]>
Co-authored-by: Richard Schmitt <[email protected]>
Co-authored-by: Mateo Guaman Castro <[email protected]>
Co-authored-by: Junnosuke Kamohara <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation isaac-lab Related to Isaac Lab team

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants