Adds friction force reporting to ContactSensor
Description
This PR extends the ContactSensor class to expose aggregated friction forces for each filtered body. It uses the same vectorized approach used for contact_points.
Concretely, this change introduces:
ContactSensorCfg.track_friction_forcestoggle to turn on friction trackingContactSensorData.friction_forces_wwhere the sum of friction forces for each filtered body are stored
Fixes https://github.com/isaac-sim/IsaacLab/issues/2074, #2064
Performance
Results of check_contact_sensor.py with track_friction_data = False:
avg dt real-time 0.017448579105403043
avg dt real-time 0.017589360827958443
avg dt real-time 0.016146250123070787
Results of check_contact_sensor.py with track_friction_data = True:
avg dt real-time 0.01818224351439858
avg dt real-time 0.017720674386015163
avg dt real-time 0.01777262271923246
Type of change
- New feature (non-breaking change which adds functionality)
Checklist
- [x] I have read and understood the contribution guidelines
- [x] I have run the
pre-commitchecks 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 updated the changelog and the corresponding version in the extension's
config/extension.tomlfile - [x] I have added my name to the
CONTRIBUTORS.mdor my name already exists there
I am curious how do you use the friction force for your learning setup, would love to learn how you guys are using it : ))
@greptileai some help ;)
@greptileai everything you said. Whatever it takes to improve the MR and make it less error-prone and feature complete :)
Responding to greptile's suggestions:
- Done
- Won't do. This was an intentional design choice as friction forces can be zero if not in contact, whereas contact points cannot
- Done
- Done
- Done
@gattra-rai could you take a look at the doc build issues? https://github.com/isaac-sim/IsaacLab/actions/runs/19120652606/job/54640238296?pr=3563. perhaps some of the suggestions from greptile might help