Unit tests for newton warp, refactor camera replicator functionality to rtx_renderer#4898
Unit tests for newton warp, refactor camera replicator functionality to rtx_renderer#4898bareya wants to merge 10 commits intoisaac-sim:developfrom
Conversation
Greptile SummaryThis PR extracts duplicated camera-renderer logic from
Issues already raised in prior review threads (not repeated here):
New concern found in this review:
Confidence Score: 3/5
Important Files Changed
Sequence DiagramsequenceDiagram
participant C as Camera / TiledCamera
participant IR as _initialize_replicator
participant IU as isaac_rtx_renderer_utils
participant Rep as omni.replicator.core
participant UB as _update_buffers_impl
Note over C: Camera._initialize_impl()
C->>IR: _initialize_replicator()
IR->>IU: configure_isaac_rtx_settings(data_types)
IU-->>IR: RTX settings applied (fast-path / warnings)
IR->>IU: resolve_simple_shading_mode(data_types)
IU-->>IR: mode int or None
IR->>Rep: create.render_product(cam_path, resolution)
Rep-->>IR: render_prod_path
IR->>Rep: AnnotatorRegistry.get_annotator(name)
Rep-->>IR: rep_annotator
IR->>Rep: rep_annotator.attach(render_prod_path)
IR-->>C: _rep_registry + _render_product_paths populated
C->>C: _create_buffers()
C->>C: _update_intrinsic_matrices()
Note over C: Per-step update
C->>UB: _update_buffers_impl(env_mask)
UB->>IU: ensure_isaac_rtx_render_update()
IU-->>UB: RTX renderer pumped (once per step)
UB->>Rep: annotator.get_data() per env_id
Rep-->>UB: raw output
UB->>C: _process_annotator_output(name, output)
Note over C: slice_output_channels / colorize / depth reshape
UB->>IU: apply_depth_clipping(output, name, range, behavior)
IU-->>UB: tensor clipped in-place
|
| from isaaclab_physx.renderers.isaac_rtx_renderer_utils import ( | ||
| configure_isaac_rtx_settings, | ||
| resolve_simple_shading_mode, | ||
| ) |
There was a problem hiding this comment.
Unguarded import of optional isaaclab_physx in core Camera class
The import at lines 417–420 is executed unconditionally every time _initialize_impl() is called, with no try/except or conditional guard. Since isaaclab is the base package and isaaclab_physx is a separate optional extension, any deployment installing isaaclab without isaaclab_physx will now get an ImportError when initializing a Camera, whereas previously the code path worked fine (the internal has_kit() guard made it a graceful no-op).
This is a breaking change for installations without isaaclab_physx. Consider either:
- Guarding the import with
try/except ImportError - Keeping the RTX-settings logic inlined (behind the existing
has_kit()guard) so the base package has no new cross-package dependency
| if isaac_sim_version.major >= 6: | ||
| needs_color_render = "rgb" in data_types or "rgba" in data_types | ||
| if not needs_color_render: | ||
| settings.set_bool("/rtx/sdg/force/disableColorRender", True) | ||
| if settings.get("/isaaclab/has_gui"): | ||
| settings.set_bool("/rtx/sdg/force/disableColorRender", False) |
There was a problem hiding this comment.
Unconditional GUI override setting even when the fast-path flag was never written
When needs_color_render is True (rgb/rgba requested), the first branch is skipped, so /rtx/sdg/force/disableColorRender is never set to True. However, the GUI override at lines 108–109 runs unconditionally and calls settings.set_bool("/rtx/sdg/force/disableColorRender", False) anyway. While harmless (setting a flag to False that was never set True), this is an unnecessary settings mutation that could surprise future maintainers.
The GUI override only needs to apply when the fast-path was attempted, so it should be nested:
if not needs_color_render:
settings.set_bool("/rtx/sdg/force/disableColorRender", True)
if settings.get("/isaaclab/has_gui"):
settings.set_bool("/rtx/sdg/force/disableColorRender", False)The existing test test_gui_overrides_fast_path already captures the original intent and can be updated accordingly.
There was a problem hiding this comment.
or even better, figure out the boolean value first and then make the set_bool() call just once.
…ading-refactor-and-test
43fa438 to
9b5af55
Compare
| @@ -4,6 +4,27 @@ Changelog | |||
| 4.5.13 (2026-03-10) | |||
There was a problem hiding this comment.
Why don't you bump the version?
| @@ -4,6 +4,20 @@ Changelog | |||
| 0.5.8 (2026-03-10) | |||
There was a problem hiding this comment.
Same. Why not bump the version?
|
If you like you can merge my wip branch - https://github.com/huidongc/IsaacLab/tree/dev/rendering-correctness-validation and double confirm no regression due to the refactoring: |
Description
Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context.
List any dependencies that are required for this change.
Fixes # (issue)
Type of change
Screenshots
Please attach before and after screenshots of the change if applicable.
Checklist
pre-commitchecks with./isaaclab.sh --formatconfig/extension.tomlfileCONTRIBUTORS.mdor my name already exists there