Question
When running the default examples for locomotion, like RoughEnvCfg for Digit, there is a reward defined as undesired_contacts.
Let's imagine we set this reward to penalize anything that's not the feet for getting in contact with the floor. One could do something like this (for G1):
undesired_contacts = RewTerm(
func=mdp.undesired_contacts,
weight=-1.0,
params={"sensor_cfg": SceneEntityCfg("contact_forces", body_names=[r"^(?!left_ankle_roll_link)(?!right_ankle_roll_link).+$"]), "threshold": 1.0},
)
However, this penalty does not differentiate the feet contacting the floor (desired) or the other foot (undesired). Is there a way to, for instance, to penalize only self-collision? Can we filter out the contact_forces with the floor?
Question
When running the default examples for locomotion, like RoughEnvCfg for Digit, there is a reward defined as undesired_contacts.
Let's imagine we set this reward to penalize anything that's not the feet for getting in contact with the floor. One could do something like this (for G1):
However, this penalty does not differentiate the feet contacting the floor (desired) or the other foot (undesired). Is there a way to, for instance, to penalize only self-collision? Can we filter out the contact_forces with the floor?