Label RSL-RL play videos with checkpoint stems - #7392
Conversation
Greptile SummaryThe PR labels RSL-RL play video filenames with the stem of the checkpoint used for playback.
Confidence Score: 5/5The PR appears safe to merge with no actionable correctness or security issues identified. The resolved checkpoint path is propagated only through the RSL-RL play flow, exact numeric checkpoint stems are appended without affecting training or custom checkpoint names, and the changed behavior is covered by focused tests. Important Files Changed
Reviews (1): Last reviewed commit: "Label RSL-RL play videos with checkpoint..." | Re-trigger Greptile |
There was a problem hiding this comment.
Isaac Lab Review Bot
Adds checkpoint-specific labels to RSL-RL play video filename prefixes, but the duplicate-label check can incorrectly suppress labels for checkpoints whose numeric IDs overlap with an existing prefix.
- Design and architecture: The optional keyword-only checkpoint path keeps existing training and non-RSL-RL callers unchanged while routing both default and preconfigured play recorders through the same labeling path.
- API: The new
checkpoint_pathparameter is keyword-only and defaults toNone, preserving compatibility for existing callers. The RSL-RL play entrypoint supplies the resolved checkpoint path explicitly. - Implementation: Matching is correctly limited to
model_<digits>.pt, but_checkpoint_video_prefix()uses substring containment. For example,model_120is considered present inclip_model_1200, leaving a video labeled with the wrong checkpoint. Duplicate suppression should compare a complete suffix token, such as equality with the label orendswith(f"_{label}").
Minor fixes needed. Posted 1 actionable finding inline.
Automated review; human maintainers own approval decisions.
384061a to
2f89c67
Compare
AntoineRichard
left a comment
There was a problem hiding this comment.
Thanks for the PR @diegoferigo-rai! The feature is nice, makes sense to me. Could you cut down the tests to the bare minimum, we're trying to get our CI under control and each added test is wasting compute!
There was a problem hiding this comment.
Could we cut down on the tests?
|
Could you target develop? We'll backport them to release |
|
Done. I consolidated the checkpoint-labeling tests into a single parametrized test plus the train-video case, cutting the added tests from six functions to two. Coverage is unchanged: default and existing-prefix labeling, the overlapping-id regression, and the non-model and non-numeric negatives. Consolidated in f70e29f. Also retargeted to develop, thanks! |
Previously, RSL-RL play videos used the same generic filename prefix for every checkpoint. Playing multiple numeric model checkpoints in one run directory could produce indistinguishable clips and collide with existing recordings. Thread the resolved checkpoint path into play video setup and append its numeric model stem to the recorder prefix. Training videos and checkpoints without numeric stems keep the existing prefix.
Reduce CI cost per review feedback by merging the checkpoint-labeling tests into one parametrized case. Coverage is preserved: default and existing-prefix labeling, the overlapping-id regression, and the non-model and non-numeric negatives.
291b4de to
f70e29f
Compare
|
@kellyguo11 @ClemensSchwarke could I get a review? |
|
@diegoferigo-rai pre-commits failed, can you take a look? |
The parametrized play-video test signature exceeded the 120-column limit. Let ruff format wrap the parameters so the ruff and ruff-format pre-commit hooks pass.
|
Fixed in 73dc184. The play-video test signature was one column over the 120 limit, so |
kellyguo11
left a comment
There was a problem hiding this comment.
@matthewtrepte for viz
|
run-ci |
|
Backported to |
# Description When playing an RSL-RL checkpoint with video recording, the clip filenames do not say which checkpoint produced them, so videos from different checkpoints in the same run directory are indistinguishable. This appends the checkpoint stem to the play video filename prefix. The label is only applied to real RSL-RL checkpoints, matched as `model_<N>.pt`, so custom or pretrained checkpoint names that merely contain a digit are not mislabeled. ## Type of change - Bug fix (non-breaking change which fixes an issue) ## 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 `./isaaclab.sh --format` - [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] I have added my name to the `CONTRIBUTORS.md` or my name already exists there (cherry picked from commit 8fbdc38)
Description
When playing an RSL-RL checkpoint with video recording, the clip filenames do not say which checkpoint produced them, so videos from different checkpoints in the same run directory are indistinguishable. This appends the checkpoint stem to the play video filename prefix. The label is only applied to real RSL-RL checkpoints, matched as
model_<N>.pt, so custom or pretrained checkpoint names that merely contain a digit are not mislabeled.Type of change
Release backport
developChecklist
pre-commitchecks with./isaaclab.sh --formatsource/<pkg>/changelog.d/for every touched packageCONTRIBUTORS.mdor my name already exists there