Skip to content

[RL] Fix training continuation and task configuration overrides - #8465

Merged
StafaH merged 3 commits into
isaac-sim:developfrom
StafaH:fix/split-8379-training
Oct 12, 2026
Merged

StafaH merged 3 commits into
isaac-sim:developfrom
StafaH:fix/split-8379-training

Conversation

@StafaH

@StafaH StafaH commented Oct 12, 2026 •

Copy link
Copy Markdown
Collaborator

Continuing RSL-RL training restored the checkpoint's optimizer settings even when a new learning rate was configured. Add the training-only --no-resume_optimizer_state option to restore models and iteration while retaining a fresh policy optimizer, with documented PPO/distillation and RND behavior.

Also fix two training-configuration paths: expose isaaclab.cli.load_external_tasks() and discover installed downstream tasks before distributed workers select a backend, and apply non-string literal overrides after preset resolution, including a literal following a named selection on the same path. These changes keep task selection and continuation settings consistent at training startup.

Split from #8379. This PR targets develop independently and includes the training documentation and existing-test extensions.

Validation

  • uv run --no-sync python -m pytest source/isaaclab_rl/test/test_entrypoints.py -k "checkpoint_preserves or task_registered_default_backend or rsl_training_registers": 6 passed. The existing checkpoint test now uses real runners and saved checkpoints; it checks model/iteration restoration, policy optimizer selection, and RND model/optimizer restoration. Disabling iteration or RND loading makes it fail.
  • uv run --no-sync python -m pytest source/isaaclab_tasks/test/core/test_hydra.py: 67 passed. The extended mixed-override regression fails without the fix.
  • uv run --no-sync python -m pytest source/isaaclab/test/cli/test_installed_workflow_entrypoints.py: 34 passed.
  • uv run --isolated --extra dev -- make -C docs current-docs: passed with warnings treated as errors.
  • uv run --no-sync isaaclab -f: passed, including changelog checks.

Type of change

  • Bug fix and new CLI option

Release backport

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

Checklist

  • Read the contribution guidelines.
  • Ran formatting and lint checks.
  • Kept regression tests with the corresponding fixes.
  • Included package changelog fragments.
  • Author already appears in CONTRIBUTORS.md.

Optimizer state resumes by default (--resume_optimizer_state); --no-resume_optimizer_state retains a fresh policy optimizer and its configured learning rate. Existing runner/dispatch/parser and lazy-import tests: 15 passed; default, enabled, and disabled CLI forms also checked.

Ordinary imports are at module scope; inline imports are retained where required by optional dependencies or deferred runtime loading.

@StafaH
StafaH requested a review from a team October 12, 2026 01:56
@github-actions github-actions Bot added bug Something isn't working documentation Improvements or additions to documentation isaac-lab Related to Isaac Lab team labels Oct 12, 2026
@greptile-apps

greptile-apps Bot commented Oct 12, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerConfidence Score: 4/5

[Medium impact] Adds checkpoint loading options and fixes task configuration overrides.

Fix the silently ignored literal override before merging.

Findings

  1. P1 Literal overrides are silently ignored ▶
  2. P2 Resume guarantees lack tests ▶

Summary

This PR adds --reset_optimizer for RSL-RL checkpoints, discovers downstream tasks before backend selection, and applies non-string overrides after preset resolution.

  • RSL-RL can restore a checkpoint with a fresh policy optimizer.
  • RL commands discover installed tasks before choosing a backend.
  • Literal task overrides now replace values after presets resolve.

Diagram

%%{init: {'theme': 'neutral'}}%%
flowchart TD
  A[Discover installed tasks] --> B[Select training backend]
  B --> C[Resolve presets]
  C --> D[Apply literal overrides]
  D --> E[Build runner with new settings]
  E --> F{Reset optimizer?}
  F -->|Yes| G[Load models and iteration; keep fresh policy optimizer]
  F -->|No| H[Load checkpoint normally]
  G --> I[Continue training]
  H --> I
Loading

Reviews (1) · Last reviewed commit: "Fix training continuation and task confi..." · Reviewed by 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

Needs attention: Design and architecture (1), Scope and over-engineering (1). Other reviewed categories look good.

  • PR description: The body matches the current diff, but after removing playback wiring it must describe --reset_optimizer as training-only; validation scopes and pass counts align with the changed tests.
  • Design and architecture: RL dispatch imports private isaaclab.cli task discovery, making it vulnerable to internal refactors; expose and use a public discovery function.
  • Scope and over-engineering: Minimal implementation: extend hydra.register_task, public isaaclab.cli task discovery, and cli_args_rsl_rl/train_rsl_rl; delete playback reset wiring and claims; keep focused tests; no source modules were added. Suggested PR breakdown: 1) Hydra override precedence; 2) public task discovery plus dispatch; 3) training-only optimizer reset, documentation, changelog, and checkpoint validation.
  • API: API changes look good.
  • Compatibility and deprecation: No breaking changes identified.
  • Implementation: Implementation looks good.
  • Style consistency: Style consistency looks good.
  • Test quality: Test quality looks good.

Minor fixes needed. Posted 2 inline findings.

Automated review; human maintainers own approval decisions.

@ooctipus

Copy link
Copy Markdown
Collaborator

maybe call it resume_optimizer_state?

I got confused to reset_library

@StafaH
StafaH force-pushed the fix/split-8379-training branch from 92c684f to 8a37278 Compare October 12, 2026 18:31
@StafaH

StafaH commented Oct 12, 2026

Copy link
Copy Markdown
Collaborator Author

Renamed in 8a37278 to --resume_optimizer_state (enabled by default), with --no-resume_optimizer_state to retain a fresh policy optimizer and configured learning rate. Updated the existing parser/runner tests, docs, and changelog. All 15 focused runner, dispatch, parser, and lazy-import cases pass; also checked the default, explicit-enable, and explicit-disable CLI forms.

@StafaH

StafaH commented Oct 12, 2026

Copy link
Copy Markdown
Collaborator Author

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 Oct 12, 2026
@StafaH

StafaH commented Oct 12, 2026

Copy link
Copy Markdown
Collaborator Author

Please backport this PR to the active release branch after it merges into develop.

@StafaH
StafaH merged commit 4310098 into isaac-sim:develop Oct 12, 2026
59 checks passed
StafaH added a commit that referenced this pull request Oct 12, 2026
#8495)

## Description

Backport the remaining simulation and training fixes from #8464 and
#8465 to `release/3.0.0`, completing the release coverage for the three
PRs split from #8379. This replaces the conflict-resolution drafts #8490
and #8491.

#8463 is already present in the release branch as
`78a297879f7a1edbfd32959ea4fcab8e967c8152`; replaying its merged commit
is empty. Its Newton HDR background and lens-distortion changes are
inherited from the base and are not duplicated here.

- Preserve compliant-contact stiffness during PhysX/OVPhysX material
randomization and use full-stage USD import for positive-stiffness
acceleration-spring materials, with a warning about the startup cost.
- Add training-only `--resume_optimizer_state` /
`--no-resume_optimizer_state`, preserving checkpoint models, iteration,
and RND state while allowing a fresh policy optimizer.
- Expose task discovery for direct workers and preserve literal
overrides following named preset selections.

## Conflict resolution

Kept the release branch's logging and test organization. Adapted
compliant-contact coverage into its existing
`test_heterogeneous_clone_contacts` and retained its scene helper and
ordinary settling duration. Used the source PR's focused CPU/GPU
scenario selection. Did not import the unrelated develop-only
indexed-state test consolidation or logging changes.

Source commits: `171b0ebe03b728997a09c016b37eb49ab074e81a` (#8464) and
`43100989af845462ac7036a256c01bcc8b84fe4a` (#8465). Release base:
`6ea915c13`.

## Validation

- Existing RSL-RL runner, dispatch, parser, and import checks: 14
passed.
- Hydra suite: 67 passed.
- Installed CLI workflow suite: 34 passed.
- OVPhysX material randomization: CPU and GPU passed in separate
processes (2 cases).
- Heterogeneous clone contacts: CPU and GPU passed in separate processes
(6 cases). Removing the cloning fallback makes the compliant GPU case
fail its clone-height comparison; the backport passes.
- Formatting/lint and changelog checks passed against the release base.
The release checker requires an `origin/` ref, so validation used a
temporary base alias that was removed afterward.
- Camera-output contract suite (including the existing #8463 backport):
18 passed.
- `uv run --isolated --extra dev -- make -C docs current-docs`: passed
with warnings treated as errors.
- Native PhysX integration tests will be covered by requested CI; they
were not run locally for this backport.

## Checklist

- [x] Followed contribution guidelines and kept existing tests with
their fixes.
- [x] Included the original package changelog fragments.
- [x] Preserved ordinary imports at module scope and justified
optional/runtime imports.
- [x] Author already appears in `CONTRIBUTORS.md`.
@StafaH
StafaH deleted the fix/split-8379-training branch October 26, 2026 16:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working documentation Improvements or additions to documentation isaac-lab Related to Isaac Lab team

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants