-
Notifications
You must be signed in to change notification settings - Fork 368
Adds gradient cap for teacher student distillation #91
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks a lot for the MR!
Hm not sure why there are formatting issues on the runner file. Could we undo those please?
Also is there a value of max grad norm that works decently? Might make sense to keep them as default.
Yeah I was wondering the same. |
You are right. Making the default 0.2 might or might not work for all usecases. It's alright to keep it None. Yes, we need to modify IsaacLab configure to support this parameter as well. Merging this MR then. Not sure why the formatting happened differently but CI didn't complain so it might be just pre-commit version differences. |
@ClemensSchwarke after merging #84, #85, #87 -- might make sense to do a patch release of rsl-rl as well. |
This PR adds a gradient cap to the teacher-student distillation setup. The goal is to prevent excessively large gradients from destabilizing training. 📌 Changes Introduced a clipping mechanism to cap the gradients during backpropagation in the distillation process. Helps improve training stability, especially in early iterations. --------- Co-authored-by: alessandro.assirelli <[email protected]>
# Description Added `max_grad_norm` field to `RslRlDistillationAlgorithmCfg` in order to be compatible with leggedrobotics/rsl_rl#91 ## Type of change - New feature (non-breaking change which adds functionality) ## Checklist - [x] I have run the [`pre-commit` checks](https://pre-commit.com/) with `./isaaclab.sh --format` - [ ] I have made corresponding changes to the documentation - [x] My changes generate no new warnings - [ ] I have added tests that prove my fix is effective or that my feature works - [ ] I have updated the changelog and the corresponding version in the extension's `config/extension.toml` file - [x] I have added my name to the `CONTRIBUTORS.md` or my name already exists there --------- Signed-off-by: Mayank Mittal <[email protected]> Co-authored-by: alessandro.assirelli <[email protected]> Co-authored-by: Mayank Mittal <[email protected]>
…-sim#2454) # Description Added `max_grad_norm` field to `RslRlDistillationAlgorithmCfg` in order to be compatible with leggedrobotics/rsl_rl#91 ## Type of change - New feature (non-breaking change which adds functionality) ## Checklist - [x] I have run the [`pre-commit` checks](https://pre-commit.com/) with `./isaaclab.sh --format` - [ ] I have made corresponding changes to the documentation - [x] My changes generate no new warnings - [ ] I have added tests that prove my fix is effective or that my feature works - [ ] I have updated the changelog and the corresponding version in the extension's `config/extension.toml` file - [x] I have added my name to the `CONTRIBUTORS.md` or my name already exists there --------- Signed-off-by: Mayank Mittal <[email protected]> Co-authored-by: alessandro.assirelli <[email protected]> Co-authored-by: Mayank Mittal <[email protected]>
…-sim#2454) # Description Added `max_grad_norm` field to `RslRlDistillationAlgorithmCfg` in order to be compatible with leggedrobotics/rsl_rl#91 ## Type of change - New feature (non-breaking change which adds functionality) ## Checklist - [x] I have run the [`pre-commit` checks](https://pre-commit.com/) with `./isaaclab.sh --format` - [ ] I have made corresponding changes to the documentation - [x] My changes generate no new warnings - [ ] I have added tests that prove my fix is effective or that my feature works - [ ] I have updated the changelog and the corresponding version in the extension's `config/extension.toml` file - [x] I have added my name to the `CONTRIBUTORS.md` or my name already exists there --------- Signed-off-by: Mayank Mittal <[email protected]> Co-authored-by: alessandro.assirelli <[email protected]> Co-authored-by: Mayank Mittal <[email protected]>
# Description Added `max_grad_norm` field to `RslRlDistillationAlgorithmCfg` in order to be compatible with leggedrobotics/rsl_rl#91 ## Type of change - New feature (non-breaking change which adds functionality) ## Checklist - [x] I have run the [`pre-commit` checks](https://pre-commit.com/) with `./isaaclab.sh --format` - [ ] I have made corresponding changes to the documentation - [x] My changes generate no new warnings - [ ] I have added tests that prove my fix is effective or that my feature works - [ ] I have updated the changelog and the corresponding version in the extension's `config/extension.toml` file - [x] I have added my name to the `CONTRIBUTORS.md` or my name already exists there --------- Signed-off-by: Mayank Mittal <[email protected]> Co-authored-by: alessandro.assirelli <[email protected]> Co-authored-by: Mayank Mittal <[email protected]>
This PR adds a gradient cap to the teacher-student distillation setup.
The goal is to prevent excessively large gradients from destabilizing training.
📌 Changes
Introduced a clipping mechanism to cap the gradients during backpropagation in the distillation process.
Helps improve training stability, especially in early iterations.