Skip to content

Refresh RTX sensors after visualizer resets - #9086

Open
AntoineRichard wants to merge 1 commit into
isaac-sim:mainfrom
AntoineRichard:codex/ui-reset-rtx-rerenders
Open

AntoineRichard wants to merge 1 commit into
isaac-sim:mainfrom
AntoineRichard:codex/ui-reset-rtx-rerenders

Conversation

@AntoineRichard

Copy link
Copy Markdown
Collaborator

Description

A reset requested from the visualizer can return an observation with camera data from before the reset. Automatic resets run the configured RTX rerenders, but environments reset by the visualizer miss that refresh.

Apply the same RTX rerender conditions after resetting the remaining environments in DirectRLEnv and ManagerBasedRLEnv. In manager-based environments, refresh the camera before the post-reset recorder hook as well as before the returned observation. The two reset phases still process disjoint environment IDs when a visualizer request coincides with automatic resets.

Split from #8868.

Validation

  • One CPU regression case per environment implementation combines an automatic reset with a visualizer reset. Both cases reproduce stale camera data on the base branch and pass with the fix.
  • All 10 focused environment unit tests passed.
  • Repository formatting, lint, and changelog checks passed.
  • The unit tests exercise rerender ordering with a simulated camera buffer. RTX hardware validation is pending.

Type of change

  • Bug fix (non-breaking change which fixes an issue)

Checklist

  • I have read and understood the contribution guidelines
  • I have run the pre-commit checks with uv run isaaclab --format
  • I have validated the changed behavior with focused coverage and applied the test-audit criteria
  • I have added a changelog fragment
  • My name already exists in CONTRIBUTORS.md

@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 (3). Other reviewed categories look good.

  • PR description: The title and body match the four-file reset-refresh scope, reported CPU validation, and pending RTX validation; no measurable performance claim requires additional evidence.
  • 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 new test and local callbacks omit annotations required by the typing guidance; annotate known inputs and returns.
  • Test quality: Test quality looks good.

Minor fixes needed. Posted 3 inline findings.

Automated review; human maintainers own approval decisions.

if len(manual_reset_ids) > 0:
index_fill_(self.reset_terminated, manual_reset_ids, True)
self._reset_idx(manual_reset_ids)
if (

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 adjacent rerender guard formatting

Both new guards split an expression that fits on one line beside the identical automatic-reset guard. Keep each guard on one line so the reset conditions remain directly comparable.

torch.testing.assert_close(env._compute_observations()["policy"], policy)


@pytest.mark.parametrize("env_type", [DirectRLEnv, ManagerBasedRLEnv])

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 — Describe the expanded test scope

This row adds manager-based coverage to a module described as testing direct environments. Broaden the module docstring to describe both implementations.


@pytest.mark.parametrize("env_type", [DirectRLEnv, ManagerBasedRLEnv])
@pytest.mark.kitless
def test_ui_resets_rerender_before_observations_and_recording(env_type):

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 — Annotate the new test functions

The new test and its local callbacks omit parameter and return annotations required by the typing guidance. Annotate their known inputs and add return annotations.

@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 (2). Other reviewed categories look good.

  • PR description: The title and body match the four-file reset fix, explain recorder ordering, and distinguish reported CPU validation from pending RTX hardware validation; no measurable performance claim requires benchmarking.
  • 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 new test and callbacks lack signature annotations required by contribution guidance and demonstrated by the adjacent test; annotate their parameters and returns.
  • Test quality: Test quality looks good.

Minor fixes needed. Posted 2 inline findings.

Automated review; human maintainers own approval decisions.

torch.testing.assert_close(env._compute_observations()["policy"], policy)


@pytest.mark.parametrize("env_type", [DirectRLEnv, ManagerBasedRLEnv])

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 — Update the module description

Adding a manager-based case makes the module docstring’s direct-only description inaccurate. Describe both environment implementations.


@pytest.mark.parametrize("env_type", [DirectRLEnv, ManagerBasedRLEnv])
@pytest.mark.kitless
def test_ui_resets_rerender_before_observations_and_recording(env_type):

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 — Annotate the new test callables

The test and its local callbacks omit parameter and return annotations, unlike the adjacent test and the type-hinting guidance. Annotate their signatures.

@greptile-apps

greptile-apps Bot commented Nov 18, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerView in GreptileConfidence Score: 5/5

[Medium impact] The PR appears safe to merge; RTX hardware validation is still pending.

Summary

Refreshes RTX sensor data after visualizer-requested resets in direct and manager-based RL environments.

  • Visualizer resets now refresh RTX cameras before observations.

No actionable issues found. RTX hardware validation remains pending, as noted in the PR.

Reviews (1) · Last reviewed commit: "Refresh RTX sensors after visualizer res..." · Reviewed by Greptile

This branch has not been deployed

No deployments
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.

1 participant