Skip to content

Added Rendering Benchmark - #7702

Merged
mataylor-nvidia merged 6 commits into
isaac-sim:developfrom
daniela-hase:dev/render-benchmark
Sep 11, 2026
Merged

mataylor-nvidia merged 6 commits into
isaac-sim:developfrom
daniela-hase:dev/render-benchmark

Conversation

@daniela-hase

Copy link
Copy Markdown
Collaborator

Description

Adds a rendering benchmark for comparing OVRTX and Newton/Warp renderer performance on an animated Franka + Sektion-cabinet scene, plus the plumbing needed to measure it.

  • scripts/benchmarks/benchmark_renderer.py: sweeps a declarative list of renderer profiles (OVRTX old/new pipeline × shading presets, Newton BVH constructor combinations) under nsys, parses
    per-frame render times from the exported NVTX ranges, and reports pixels/second plus median/mean/min/max/stdev either as a table or as JSON.
  • source/isaaclab/isaaclab/renderers/render_context.py: adds a backend-agnostic NVTX range (RENDER_PROFILE_SCOPE) around RenderContext.render_into_camera's renderer call, gated by the
    ISAACLAB_RENDER_PROFILE env var so it has no effect (and no device-sync cost) in normal runs.
  • source/isaaclab_tasks/isaaclab_tasks/core/render_benchmark/: a new direct-workflow task, Isaac-RenderBenchmark-Franka-Cabinet, with no policy or reward — all articulated joints (Franka +
    cabinet drawers/doors) are driven by a deterministic sinusoid so every frame has moving geometry to render. Supports newton_mjwarp/physx physics presets and
    rgb/albedo/depth/simple_shading_* camera presets.

Type of change

  • New feature (non-breaking change which adds functionality)

Release backport

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

Checklist

  • I have read and understood the contribution guidelines
  • I have run the pre-commit checks with ./isaaclab.sh --format
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • I have added a changelog fragment under source/<pkg>/changelog.d/ for every touched package
  • I have added my name to the CONTRIBUTORS.md or my name already exists there

@greptile-apps

greptile-apps Bot commented Sep 9, 2026

Copy link
Copy Markdown
Contributor

Greptile Summary

This PR adds a renderer benchmark driver, a backend-neutral NVTX timing scope, and a deterministic Franka/cabinet benchmark environment.

  • Sweeps OVRTX and Newton renderer configurations under Nsight Systems and reports timing statistics and pixel throughput.
  • Adds opt-in synchronized render profiling around the common renderer call.
  • Registers a direct-workflow task with deterministic articulated motion and multiple rendering/physics presets.
  • The benchmark scene currently clones substantially overlapping ground meshes, which can invalidate renderer comparisons.

Confidence Score: 4/5

The PR should not merge until the cloned overlapping ground geometry is corrected so benchmark results represent the intended scene.

Every environment clones a 50 m ground despite only 3 m spacing, causing many coplanar meshes to overlap and skew renderer workload as the environment count grows; the pose documentation also misstates the configured quaternion rotations.

Files Needing Attention: source/isaaclab_tasks/isaaclab_tasks/core/render_benchmark/render_benchmark_env_cfg.py; source/isaaclab_tasks/isaaclab_tasks/core/render_benchmark/render_benchmark_env.py

Important Files Changed

Filename Overview
scripts/benchmarks/benchmark_renderer.py Adds profile selection, Nsight Systems execution/export, NVTX timing parsing, and table/JSON reporting.
source/isaaclab/isaaclab/renderers/render_context.py Adds an environment-gated, synchronized NVTX scope around the backend renderer call.
source/isaaclab_tasks/isaaclab_tasks/core/render_benchmark/render_benchmark_env.py Builds and animates the benchmark scene, including cloning the oversized per-environment ground.
source/isaaclab_tasks/isaaclab_tasks/core/render_benchmark/render_benchmark_env_cfg.py Defines renderer, physics, camera, asset, and lighting presets, but configures overlapping grounds and inaccurately documents asset rotations.
scripts/benchmarks/test/test_benchmark_renderer.py Covers pure timing-parser, record-building, scope-name, and CLI behavior.
source/isaaclab_tasks/test/core/test_render_benchmark_cfg.py Verifies task registration and preset resolution without requiring a GPU.

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart TD
    A[benchmark_renderer.py selects profile] --> B[Launch runtime under nsys]
    B --> C[Create Franka/cabinet environments]
    C --> D[Animate articulation targets]
    D --> E[Read tiled-camera output]
    E --> F[RenderContext updates scene state]
    F --> G[NVTX-scoped renderer.render]
    G --> H[Renderer output readback]
    H --> I[Export nsys report to SQLite]
    I --> J[Parse per-frame NVTX ranges]
    J --> K[Report timing and pixel throughput]
Loading

Reviews (1): Last reviewed commit: "Added Rendering Benchmark" | Re-trigger 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

The renderer benchmark, profiling scope, and direct task are structurally coherent, but the camera and light quaternions use the wrong component order, producing a scene view and lighting direction that differ from the documented benchmark setup. The new public CLI options also violate the repository’s snake_case convention.

  • Design and architecture: The backend-agnostic NVTX scope and preset-driven benchmark task provide a reasonable comparison path across OVRTX and Newton. Correct the camera and light orientations so both backends exercise the intended, consistently framed and lit scene.
  • API: The profiling constant and environment-gated behavior are additive, and render_into_camera preserves its signature and update/render/read sequence. Rename the newly introduced hyphenated CLI options to snake_case before they become an established compatibility surface.
  • Implementation: The camera offset and distant-light orientation tuples are documented and authored as (x, y, z, w), while the relevant Isaac Lab interfaces consume (w, x, y, z). Reorder both tuples and update their documentation; otherwise the camera points away from the intended workspace and the lighting does not match the claimed direction.

Minor fixes needed. Posted 3 actionable findings inline.

Automated review; human maintainers own approval decisions.

env["OVRTX_rtx_minimal_useMinimalPipeline"] = "1" if profile["settings"]["min-pipe"] else "0"

if renderer == NEWTON_RENDERER:
env["NEWTON_BVH_SCENE"] = profile["settings"]["tlas"]

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.

Env var names are duplicated between here and render_benchmark_env_cfg.py (NEWTON_BVH_SCENE, NEWTON_BVH_GEOMETRY, NEWTON_USE_CUDA_GRAPH) with no shared constant. A typo/rename on one side would silently fall back to the default on the other instead of erroring. Consider defining these names once (e.g. in a shared module) and importing them in both places.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

Do we really need (or usually do) consts for environment variables across very different places?

I can do it if wanted, but am not sure if I like it :) Should I do it?

import sys
from pathlib import Path

PROFILES = [

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.

This list has ~6 near-identical OVRTX dicts and ~6 near-identical Newton dicts, hand-copied and varying only min-pipe/tlas/blas. Consider generating it with itertools.product over the shading-mode/pipe-flag and tlas/blas combos instead — hand-copying makes it easy to leave a field stale (e.g. forget to flip min-pipe) when adding a new variant.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

I find it much easier to read this way - and I am not sure if I agree on the argument of hand-copying making it easy to leave a field stale. I think the same could happen if it is built with itertools or similar.

@daniela-hase
daniela-hase enabled auto-merge (squash) September 10, 2026 21:25
@mataylor-nvidia

Copy link
Copy Markdown
Contributor

run-ci

@isaaclab-bot isaaclab-bot Bot added ci:run-docker Trigger the on-demand Docker and GPU CI workflow and removed ci:run-docker Trigger the on-demand Docker and GPU CI workflow labels Sep 10, 2026
@daniela-hase
daniela-hase enabled auto-merge (squash) September 10, 2026 21:50
The repository convention, enforced by
test_registered_task_physx_presets_keep_auto_selection_explicit, reserves
the `physx` preset name for the automatic selector (PhysxAutoCfg, resolved
to a concrete backend at launch) and `isaacsim_physx` for the concrete
Isaac Sim PhysX configuration. RenderBenchmarkPhysicsCfg bound `physx`
directly to PhysxCfg, so registering the task failed that check.

Rename the concrete config to `isaacsim_physx` and expose `physx` as the
PhysxAutoCfg selector wrapping it, and update the task's own preset test
to match.
@mataylor-nvidia

Copy link
Copy Markdown
Contributor

run-ci

@isaaclab-bot isaaclab-bot Bot added ci:run-docker Trigger the on-demand Docker and GPU CI workflow and removed ci:run-docker Trigger the on-demand Docker and GPU CI workflow labels Sep 11, 2026
The render benchmark and the Shadow Hand camera benchmark exist to measure
rendering throughput, not to train policies, so they do not belong beside the
trainable task families. Collect them under a new `benchmark` package that may
depend on `core` and `contrib` while neither depends on it.

Task ids are unchanged. The Shadow Hand benchmark configuration moves out of
`contrib.reorient.config.shadow_hand`, and its registration moves with it, so
`contrib` no longer registers a task whose config lives elsewhere.
@mataylor-nvidia

Copy link
Copy Markdown
Contributor

run-ci

1 similar comment
@mataylor-nvidia

Copy link
Copy Markdown
Contributor

run-ci

@mataylor-nvidia
mataylor-nvidia enabled auto-merge (squash) September 11, 2026 20:38
@isaaclab-bot isaaclab-bot Bot added ci:run-docker Trigger the on-demand Docker and GPU CI workflow and removed ci:run-docker Trigger the on-demand Docker and GPU CI workflow labels Sep 11, 2026
@mataylor-nvidia
mataylor-nvidia merged commit 487b5ca into isaac-sim:develop Sep 11, 2026
53 checks passed
mataylor-nvidia added a commit to mataylor-nvidia/IsaacLab that referenced this pull request Sep 14, 2026
Follows how isaac-sim#7702 handled ISAACLAB_RENDER_PROFILE: the timer is simply
always on rather than gated behind a flag. Doing the same for
ISAACLAB_PHYSICS_PROFILE removes the reason for everything --mode was
carrying. Every log now has physics timings, so the parser no longer
tracks whether a frame has them, the table no longer chooses its columns
per run, and the test log writer no longer makes physics optional.

The scene switch stays on BENCHMARK_MODE, read directly the way the
profile env vars are. Both modes report physics, render, and total; the
mode decides what the physics number means, not whether there is one.
pbarejko pushed a commit that referenced this pull request Sep 23, 2026
# Description

Follow-up to #7702. Added direct-pose and actuator-driven workloads to
the canonical Franka cabinet renderer benchmark, with physics and render
timings available through the benchmark API and persisted reports.

- `BENCHMARK_MODE=render` (default) writes the analytic joint pose after
physics and before the camera read. `BENCHMARK_MODE=physics_render` sets
actuator targets before physics. Both modes still step physics.
- Direct posing requires lazy sensor updates. With Isaac RTX, it also
rejects visualizers that pump the Kit app before the pose write; use
`--visualizer none` or `physics_render`.
- Runtime benchmarks collect synchronized scopes after warmup when the
task has a non-`None` `benchmark_mode` and the corresponding
`ISAACLAB_PHYSICS_PROFILE` / `ISAACLAB_RENDER_PROFILE` flag is enabled.
Temporary wrappers restore the original methods on success or failure,
so subsequent runs do not inherit profiling overhead or duplicate
samples.
- Schema **1.4 remains unchanged**. `BenchmarkResult.bundle.extra`,
schema JSON, and OmniPerf output include per-call mean, standard
deviation, maximum [ms], and call count under `physics_*` and
`render_*`. Disabled scopes add no keys, and distributed metadata is
preserved.
- Ordered raw samples remain in local `profile_timings.json`, outside
`output_paths`. The renderer sweep groups physics calls by rendered
frame and reports render, physics, and combined statistics without
scraping logs. Invalid profiling output errors propagate.

```bash
uv run python scripts/benchmarks/benchmark_renderer.py 'newton_*'
BENCHMARK_MODE=physics_render uv run python scripts/benchmarks/benchmark_renderer.py 'newton_*'
```

Scope timing synchronizes the device and changes execution overlap, so
profiled runs are diagnostics. API/OmniPerf summaries cover all captured
calls; the sweep additionally removes padding frames and reports
per-frame statistics.

Migration: collect scope timings through the runtime benchmark; normal
simulations no longer install render timers from the profiling flag.
Read scalar summaries from `bundle.extra` or raw `timings_ms` pairs from
the local profiling file. The old
`isaaclab.renderers.render_context.RENDER_PROFILE_SCOPE` import remains
available with a deprecation warning; use
`isaaclab.benchmark.stepping.RENDER_PROFILE_SCOPE`.

## Validation

- Benchmark, renderer orchestration, task configuration, sweep, and
runtime smoke tests: 398 passed, 1 skipped.
- Regression tests failed before the fixes and passed afterward for
profiling restoration, the deprecated scope import, and invalid
direct-pose rendering configurations.
- Real Newton GPU sweeps passed in both modes with 1 environment, 3
measured frames, and 64×64 resolution. Reported statistics were
independently checked against raw samples.
- Formatting and changelog checks passed against the current `develop`
base.
- Sphinx documentation built without warnings or errors using `uv run
--isolated --extra dev -- make -C docs current-docs` with
`SPHINXOPTS='-D viewcode_follow_imported_members=0'` to omit imported
source-code links.

## Type of change

- New feature
- Bug fix
- Breaking change: render profiling moved from normal simulation runs
into the runtime benchmark
- Documentation update

## Release backport

- [x] <!-- backport-active-release --> Backport this pull request to the
active release branch after it merges into `develop`

## Checklist

- [x] I have read and understood the contribution guidelines
- [x] I have run the pre-commit checks with `uv run isaaclab -f`
- [x] I have made corresponding changes to the documentation
- [x] My changes generate no new warnings
- [x] I have added tests that prove my fix is effective or that my
feature works
- [x] I have added a changelog fragment under
`source/<pkg>/changelog.d/` for every touched package
- [x] My name already exists in `CONTRIBUTORS.md`
isaaclab-bot Bot pushed a commit that referenced this pull request Sep 23, 2026
# Description

Follow-up to #7702. Added direct-pose and actuator-driven workloads to
the canonical Franka cabinet renderer benchmark, with physics and render
timings available through the benchmark API and persisted reports.

- `BENCHMARK_MODE=render` (default) writes the analytic joint pose after
physics and before the camera read. `BENCHMARK_MODE=physics_render` sets
actuator targets before physics. Both modes still step physics.
- Direct posing requires lazy sensor updates. With Isaac RTX, it also
rejects visualizers that pump the Kit app before the pose write; use
`--visualizer none` or `physics_render`.
- Runtime benchmarks collect synchronized scopes after warmup when the
task has a non-`None` `benchmark_mode` and the corresponding
`ISAACLAB_PHYSICS_PROFILE` / `ISAACLAB_RENDER_PROFILE` flag is enabled.
Temporary wrappers restore the original methods on success or failure,
so subsequent runs do not inherit profiling overhead or duplicate
samples.
- Schema **1.4 remains unchanged**. `BenchmarkResult.bundle.extra`,
schema JSON, and OmniPerf output include per-call mean, standard
deviation, maximum [ms], and call count under `physics_*` and
`render_*`. Disabled scopes add no keys, and distributed metadata is
preserved.
- Ordered raw samples remain in local `profile_timings.json`, outside
`output_paths`. The renderer sweep groups physics calls by rendered
frame and reports render, physics, and combined statistics without
scraping logs. Invalid profiling output errors propagate.

```bash
uv run python scripts/benchmarks/benchmark_renderer.py 'newton_*'
BENCHMARK_MODE=physics_render uv run python scripts/benchmarks/benchmark_renderer.py 'newton_*'
```

Scope timing synchronizes the device and changes execution overlap, so
profiled runs are diagnostics. API/OmniPerf summaries cover all captured
calls; the sweep additionally removes padding frames and reports
per-frame statistics.

Migration: collect scope timings through the runtime benchmark; normal
simulations no longer install render timers from the profiling flag.
Read scalar summaries from `bundle.extra` or raw `timings_ms` pairs from
the local profiling file. The old
`isaaclab.renderers.render_context.RENDER_PROFILE_SCOPE` import remains
available with a deprecation warning; use
`isaaclab.benchmark.stepping.RENDER_PROFILE_SCOPE`.

## Validation

- Benchmark, renderer orchestration, task configuration, sweep, and
runtime smoke tests: 398 passed, 1 skipped.
- Regression tests failed before the fixes and passed afterward for
profiling restoration, the deprecated scope import, and invalid
direct-pose rendering configurations.
- Real Newton GPU sweeps passed in both modes with 1 environment, 3
measured frames, and 64×64 resolution. Reported statistics were
independently checked against raw samples.
- Formatting and changelog checks passed against the current `develop`
base.
- Sphinx documentation built without warnings or errors using `uv run
--isolated --extra dev -- make -C docs current-docs` with
`SPHINXOPTS='-D viewcode_follow_imported_members=0'` to omit imported
source-code links.

## Type of change

- New feature
- Bug fix
- Breaking change: render profiling moved from normal simulation runs
into the runtime benchmark
- Documentation update

## Release backport

- [x] <!-- backport-active-release --> Backport this pull request to the
active release branch after it merges into `develop`

## Checklist

- [x] I have read and understood the contribution guidelines
- [x] I have run the pre-commit checks with `uv run isaaclab -f`
- [x] I have made corresponding changes to the documentation
- [x] My changes generate no new warnings
- [x] I have added tests that prove my fix is effective or that my
feature works
- [x] I have added a changelog fragment under
`source/<pkg>/changelog.d/` for every touched package
- [x] My name already exists in `CONTRIBUTORS.md`

(cherry picked from commit 3714907)
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.

4 participants