Skip to content

feat: add Newton CUDA graph owner knob - #1605

Merged
TATP-233 merged 2 commits into
mainfrom
feat/issue-1604-newton-cuda-graph-owner
Sep 17, 2026
Merged

TATP-233 merged 2 commits into
mainfrom
feat/issue-1604-newton-cuda-graph-owner

Conversation

@TATP-233

@TATP-233 TATP-233 commented Sep 17, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • Add the explicit EnvCfg.newton_use_cuda_graph owner knob with bool validation and factory forwarding.
  • Enable Newton CUDA graph replay by default for the Newton backend and all current Newton task owners; eager fallback remains owned by UniSim for ineligible drivers or capture failures.
  • Require unisim-core>=1.6.0 in the standard and ROCm dependency profiles and update both lockfiles.
  • Update bilingual backend docs, routing/config coverage, and the IsaacGym fixed-variant drift fixture for the stricter 1.6.0 kinematics scan.

Consumes the published unisim-core 1.6.0 release (unilabsim/unisim#144, released through #147).

Validation

  • uv run pytest -q tests/base/backend/test_newton_backend_options.py tests/base/test_isaacgym_fixed_variants.py tests/envs/locomotion/g1/test_g1_owner_contract.py tests/scripts/test_train_scripts.py::test_offpolicy_flashsac_g1_motion_tracking_task_composes - 7 passed, 33 deselected
  • uv lock --check
  • ROCm lock resolution/check using the mirrored pyproject.rocm.toml and uv.rocm.lock
  • make check
  • make test-all - 1491 passed, 27 skipped, 598 deselected; benchmark smoke 34/34 module mode and 35/35 script mode
  • Sphinx HTML build with autodoc disabled
  • Full-budget A/B evidence on RTX 4090 was recorded at feat: add Newton CUDA graph owner knob #1605 using unisim Work: 显式化 registry 默认 backend 语义,禁止依赖注册顺序 #144 head 3402c8f: +48.57% final SPS, -35.77% wall time, reward parity.

Drives #1604.

@TATP-233

Copy link
Copy Markdown
Collaborator Author

Full-budget FlashSAC Newton validation completed on the current owner-knob head (800a8f7c), using an editable install of unilabsim/unisim#144 at 3402c8f.

Environment: RTX 4090, Warp reports CUDA mempool enabled. The graph run emitted no fallback warning. Both runs used seed 1, 2048 environments, 25000 iterations, AMP, and the canonical g1_motion_tracking Newton owner. The graph run disabled playback so the comparison covers the training loop.

Metric Eager baseline CUDA graph Delta
Final SPS 34,953.0 51,928.9 +48.57%
Training wall time 1,553.85 s 998.03 s -35.77%
Final mean reward 26.4967 29.1227 +2.6259
Best mean reward 34.1479 34.2186 +0.0706
Completed iterations 25,000 / 25,000 25,000 / 25,000 status completed

Command:

uv run --no-sync train --algo flashsac --task g1_motion_tracking --sim newton \
  env.newton_use_cuda_graph=true training.no_play=true

Artifacts:

  • Eager: logs/flash_sac/G1MotionTrackingSAC/2026-09-17_14-26-19_newton/run_summary.json
  • Graph: logs/flash_sac/G1MotionTrackingSAC/2026-09-17_17-58-25_newton/run_summary.json

The graph snapshot records env.newton_use_cuda_graph: true, 51,400,704 total env steps, final reward 29.1227, and best reward 34.2186.

@TATP-233
TATP-233 marked this pull request as ready for review September 17, 2026 11:11
@TATP-233
TATP-233 merged commit 3487325 into main Sep 17, 2026
8 of 14 checks passed
@TATP-233
TATP-233 deleted the feat/issue-1604-newton-cuda-graph-owner branch September 17, 2026 11:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant