Improves recorder performance and add additional recording capability#3302
Improves recorder performance and add additional recording capability#3302kellyguo11 merged 18 commits intoisaac-sim:mainfrom
Conversation
| self.scene.write_data_to_sim() | ||
| # simulate | ||
| self.sim.step(render=False) | ||
| self.recorder_manager.record_pre_physics_step() |
There was a problem hiding this comment.
Isn't this happening now after the physics step?
There was a problem hiding this comment.
The recording right now records the states after a physics step. Here, it's adding functionality to record the states prior to every physics step in the decimation loop which provides more fine grain recording.
There was a problem hiding this comment.
The motivation here is that full determinism during replay is not possible when running parallel envs as the physX buffers cannot be flushed on every IsaacLab reset. This can cause significant divergence when replaying data collected with parallel envs by just using env.step as it has to run through the entire action space which may contain controllers that are sensitive to this nondeterminism. Recording at the decimation level every sim dt can help alleviate this by giving users the option of more fine grained control.
There was a problem hiding this comment.
Note that recording pre physics steps is fully optional and will not enabled by our existing default recorder workflows to limit dataset size. Users can take advantage of it via their own recorder terms if needed (like how Lightwheel is currently doing).
There was a problem hiding this comment.
but should this be called record_post_physics_step() or record_post_physics_decimated_step because it is after ?
There was a problem hiding this comment.
Sorry I misunderstood Mayank's original comment. Yes I agree the naming here is confusing. I have updated to be called "record_post_physics_decimation_step."
Signed-off-by: Kelly Guo <kellyg@nvidia.com>
Signed-off-by: Kelly Guo <kellyg@nvidia.com>
…isaac-sim#3302) # Description <!-- Thank you for your interest in sending a pull request. Please make sure to check the contribution guidelines. Link: https://isaac-sim.github.io/IsaacLab/main/source/refs/contributing.html --> This PR adds fixes from LightWheel Labs and additional functionality to the IsaacLab recorder. Fixes # (issue) - Fixes performance issue when recording long episode data by replacing the use of torch.cat at every timestep with list append. - Fixes configclass validation when key is not a string Adds Functionality - Adds optional episode meta data to HDF5 recorder - Adds option to record data pre-physics step - Adds joint target data to episode data. Joint target data can be optionally recorded by users and replayed to bypass action term controllers and improve replay determinism. ## Type of change <!-- As you go through the list, delete the ones that are not applicable. --> - Bug fix (non-breaking change which fixes an issue) - New feature (non-breaking change which adds functionality) ## Screenshots Please attach before and after screenshots of the change if applicable. <!-- Example: | Before | After | | ------ | ----- | | _gif/png before_ | _gif/png after_ | To upload images to a PR -- simply drag and drop an image while in edit mode and it should upload the image directly. You can then paste that source into the above before/after sections. --> ## 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 - [x] 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 <!-- As you go through the checklist above, you can mark something as done by putting an x character in it For example, - [x] I have done this task - [ ] I have not done this task --> --------- Signed-off-by: Kelly Guo <kellyg@nvidia.com> Co-authored-by: Kelly Guo <kellyg@nvidia.com>
Description
This PR adds fixes from LightWheel Labs and additional functionality to the IsaacLab recorder.
Fixes # (issue)
Adds Functionality
Type of change
Screenshots
Please attach before and after screenshots of the change if applicable.
Checklist
pre-commitchecks with./isaaclab.sh --formatconfig/extension.tomlfileCONTRIBUTORS.mdor my name already exists there