Skip to content

Commit c8f77a7

Browse files
authored
Adds missing typehint in reward function (#1303)
# Description Adds missing typehint in reward function ## Type of change - Bug fix (non-breaking change which fixes an issue) ## 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
1 parent 002fec4 commit c8f77a7

File tree

1 file changed

+1
-1
lines changed
  • source/extensions/omni.isaac.lab/omni/isaac/lab/envs/mdp

1 file changed

+1
-1
lines changed

source/extensions/omni.isaac.lab/omni/isaac/lab/envs/mdp/rewards.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -159,7 +159,7 @@ def joint_acc_l2(env: ManagerBasedRLEnv, asset_cfg: SceneEntityCfg = SceneEntity
159159
return torch.sum(torch.square(asset.data.joint_acc[:, asset_cfg.joint_ids]), dim=1)
160160

161161

162-
def joint_deviation_l1(env, asset_cfg: SceneEntityCfg = SceneEntityCfg("robot")) -> torch.Tensor:
162+
def joint_deviation_l1(env: ManagerBasedRLEnv, asset_cfg: SceneEntityCfg = SceneEntityCfg("robot")) -> torch.Tensor:
163163
"""Penalize joint positions that deviate from the default one."""
164164
# extract the used quantities (to enable type-hinting)
165165
asset: Articulation = env.scene[asset_cfg.name]

0 commit comments

Comments
 (0)