Repository navigation
[RL] Normalize unbounded SB3 action spaces - #7910
Conversation
|
There was a problem hiding this comment.
Isaac Lab Review Bot
The PR consistently introduces environment-owned raw action bounds, composes manager-based term bounds into Gymnasium spaces, enforces declared bounds before term processing, and rejects unsupported unbounded continuous spaces in the SB3 wrapper. The proposed A1 finding is not supported because the supplied context does not establish that its normalized action domain is incorrect or identify a broken consumer.
- Design and architecture: The action manager is the coherent source of truth for manager-based action bounds, while direct environments derive enforcement from DirectRLEnvCfg.action_space. Bounds declared by a task are intentionally enforced at the environment layer and therefore apply independently of the RL wrapper; this is a documented breaking design choice rather than an evidenced defect in the A1 configuration.
- API: The new ActionTermCfg.raw_action_bounds and ActionManager.action_space APIs preserve unbounded behavior when bounds are omitted, validate malformed bound pairs, expose composed bounds through ManagerBasedRLEnv, and provide SB3 with an explicit finite-space requirement. Documentation and changelog fragments describe the new contract and migration requirement.
- Implementation: The changed producer and consumer paths are internally aligned: manager actions are moved to the expected device and dtype, clamped into the manager buffer before term slicing, direct-environment actions are clamped before preprocessing, and SB3 rejects fully or partially unbounded Box spaces instead of substituting artificial bounds. Tests cover composition, enforcement, invalid bounds, environment-space propagation, and SB3 rejection behavior.
No blocking issues. No inline issue met the actionable-evidence threshold; the assessment above records the review feedback.
Automated review; human maintainers own approval decisions.
…unds # Conflicts: # source/isaaclab_rl/test/test_sb3_wrapper.py
|
run-ci |
1 similar comment
|
run-ci |
|
Backported to |
# Description Fix Stable-Baselines3 off-policy training on Isaac Lab environments with unbounded continuous action spaces without changing the underlying environment semantics. - Replace the SB3 wrapper's artificial `[-100, 100]` fallback with normalized `[-1, 1]` bounds. - Keep manager-based and direct environments unbounded and leave their action processing unchanged. - Add `Sb3VecEnvWrapper.action_bounds` so policies using a different finite domain can override the fallback. - Preserve already-bounded environment action spaces unchanged. This gives SAC and TD3 a useful finite scaling domain while limiting the behavior change to the SB3 adapter. Fixes #5080 No new dependencies. ## Type of change - Bug fix - Breaking change - Documentation update ## Release backport - [x] <!-- backport-active-release --> Backport this pull request to the active release branch after it merges into `develop` ## Screenshots Not applicable. ## 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 documentation changes - [x] My changes generate no new warnings - [x] I have added regression tests - [x] I have added changelog fragments for every touched package - [x] My name already exists in `CONTRIBUTORS.md` ## Validation - `uv run --extra sb3 --extra test pytest -q source/isaaclab_rl/test/test_wrappers.py -k sb3` - `uv run python tools/changelog/cli.py check develop` - `uv run isaaclab -f` (cherry picked from commit e5a1779)
…7530, #7899) (#7926) ## Description Backports the two changes merged into `develop` since September 19 that are still missing from `release/3.0.0`: | Source PR | Change | Source commit | | --- | --- | --- | | #7530 | Validate camera outputs against renderer capabilities before simulator startup | `31d1c53510490c76841e9c35a329574b357d9900` | | #7899 | Share native resources by construction cfg and centralize ownership and teardown | `c90c3a1097a0a669a823b880b1c8d0654d7fd267` | Includes the original regression tests, API documentation, and changelog fragments. #7530 applied without changes. #7899 required two conflict resolutions to retain the release branch's OVRTX mapping API, documentation, and tests. Of its 62 files, 59 match the merged source exactly; the other three retain those existing release additions. Release versions, lockfile entries, compiled changelogs, and documentation routing are preserved. ## Audit Checked all **33 PRs** merged from September 19, 2026 00:00 America/Los_Angeles through `develop` commit `c90c3a1097` (September 20, 21:29 Pacific), against release base `75e9c8ce12`. **31 are already backported; the remaining two are included here.** Git first-parent history and GitHub's merged PR list agree. Automatic changelog/version compilation remains branch-specific. <details> <summary>31 PRs already recorded in release</summary> | Source PRs | Existing release commit | | --- | --- | | #7777, #7608, #7895, #7872, #7831, #7834, #7838, #7840, #7903, #7674 | [`ff22c52891`](ff22c52) | | #7886 | [`41bfaee5f0`](41bfaee) | | #7042 | [`970d21ef48`](970d21e) | | #7905 | [`f0563d1f9e`](f0563d1) | | #7604 | [`dca7cfe984`](dca7cfe) | | #7610, #7603 | [`5dd2220243`](5dd2220) | | #7839 | [`b8b93bb96e`](b8b93bb) | | #6851 | [`baa025ad90`](baa025a) | | #7250 | [`f86b33e6b1`](f86b33e) | | #7910 | [`24f7b4842b`](24f7b48) | | #7810 | [`9738e096c8`](9738e09) | | #7832 | [`be270ed88b`](be270ed) | | #4679 | [`80157aa22d`](80157aa) | | #7914 | [`01b59b5a22`](01b59b5) | | #7502 | [`db7db61f60`](db7db61) | | #7918 | [`bca9dba8bb`](bca9dba) | | #7919 | [`ef1514c97c`](ef1514c) | | #7922 | [`7d6979a19e`](7d6979a) | | #7923 | [`a1dd560b98`](a1dd560) | | #7924 | [`892e51dc1d`](892e51d) | | #7925 | [`75e9c8ce12`](75e9c8c) | </details> ## Validation **745 tests passed** on the combined backport: - Core registry, configclass, replication, camera contracts, and task presets: 158 passed. - Newton manager/model/reset and coupling suites: 299 passed. - OVPhysX/OVRTX lifecycle, scene data, bindings, and material contracts: 141 passed on CPU. - Clone-plan algebra: 83 passed. - All 8 OV CUDA cases skipped in the CPU run: 8 passed on GPU. - OVPhysX ray-caster regression: 1 passed. - Kit simulation-context and PhysX scene-data tests: 54 passed. - Newton solver reset integration: 1 passed. The registry-identity and borrowed-config-field regressions both fail with the pre-backport implementations and pass with this change. Backport file-scope validation, source-file comparison, `git diff --check`, and `uv run isaaclab -f` passed. Local validation used PyTorch 2.12.0/CUDA 13.0, Isaac Sim 6.0.1.0, Newton 1.6.0rc1, and an RTX 5090. Existing deprecation/runtime warnings occurred. Full Docker CI is requested separately against the pinned environment; local checks do not claim a startup or runtime speedup. ## Checklist - [x] Read the contribution guidelines and ran formatting/changelog checks. - [x] Included source tests, documentation, and changelog fragments. - [x] Verified regression behavior and preserved release-specific changes. - [x] Recorded source commit hashes and audited the requested merge window. --------- Co-authored-by: Antoine RICHARD <[email protected]> Co-authored-by: ooctipus <[email protected]>
|
@ooctipus @StafaH @AntoineRichard also, |
Description
Fix Stable-Baselines3 off-policy training on Isaac Lab environments with unbounded continuous action spaces without changing the underlying environment semantics.
[-100, 100]fallback with normalized[-1, 1]bounds.Sb3VecEnvWrapper.action_boundsso policies using a different finite domain can override the fallback.This gives SAC and TD3 a useful finite scaling domain while limiting the behavior change to the SB3 adapter.
Fixes #5080
No new dependencies.
Type of change
Release backport
developScreenshots
Not applicable.
Checklist
uv run isaaclab -fCONTRIBUTORS.mdValidation
uv run --extra sb3 --extra test pytest -q source/isaaclab_rl/test/test_wrappers.py -k sb3uv run python tools/changelog/cli.py check developuv run isaaclab -f