Repository navigation
Conversation
|
Hi @M-Colley, I independently tested a similar constant-recomputation graph cache and measured a 10.75% end-to-end PPO throughput improvement with 4096 MicroDuck environments. I noticed the overlap with this PR and would be happy to contribute the benchmark and regression coverage.
The common benchmark configuration was:
@kevinzakka, would these end-to-end results be useful for evaluating this approach? |
|
Thanks for measuring it end to end, @zjjott. The numbers in the description cover only the recomputation and expansion costs, so a training-throughput figure is what this PR was missing. Was that run on this branch (428defa) or on your own cache? If it was yours, the same MicroDuck setup on 428defa would show whether this PR gives the same gain. On tests:
If your tests cover something else, for example the event manager's recomputation in a full task, I'm happy to take them as a PR against |
|
Closing in favor of #1333, which ports the |
Constant recomputation currently launches from Python on every domain-randomization call, and an unchanged field-expansion request still rebuilds simulation graphs. Lazily cache one CUDA graph per recomputation level, invalidate it whenever simulation graphs are rebuilt, and retain graphs/sensor contexts when storage and metadata are unchanged. CPU execution keeps the direct path; the none level is a no-op.
Tests change per-world mass and physical state across repeated replays, compare against uncaptured execution, and verify graph invalidation after storage replacement.
make checkand five focused tests passed with the unchanged MuJoCo/Warp 3.16 pair. All 19 combined Linux checks passed across Python 3.10–3.14 and a fresh dependency resolve: https://github.com/M-Colley/mjlab/actions/runs/40094203866. The corresponding CUDA cases also passed with the 3.17 pair.A synchronized alternating-order RTX 4050 microbenchmark with 512 worlds measured median set_const_0 at 13.31 ms for direct launches versus 0.969 ms for cached replay over 15 samples. Unchanged expansion measured 34.29 ms before and 0.207 ms after in separate runs. Contacts were disabled (zero overflow); these are local recomputation/setup costs under host load, not end-to-end training throughput. First opened in the fork: M-Colley#3.