diff --git a/torchrl/envs/libs/dm_control.py b/torchrl/envs/libs/dm_control.py index 96d392a76c2..3e1aac917e0 100644 --- a/torchrl/envs/libs/dm_control.py +++ b/torchrl/envs/libs/dm_control.py @@ -80,8 +80,8 @@ def _dmcontrol_to_torchrl_spec_transform( shape = torch.Size([1]) return BoundedTensorSpec( shape=shape, - low=spec.low, - high=spec.high, + low=spec.minimum, + high=spec.maximum, dtype=dtype, device=device, ) diff --git a/torchrl/modules/tensordict_module/actors.py b/torchrl/modules/tensordict_module/actors.py index 870f68b7bf3..8561b026f3c 100644 --- a/torchrl/modules/tensordict_module/actors.py +++ b/torchrl/modules/tensordict_module/actors.py @@ -443,7 +443,7 @@ class QValueModule(TensorDictModuleBase): def __init__( self, - action_space: Optional[str], + action_space: Optional[str] = None, action_value_key: Optional[NestedKey] = None, action_mask_key: Optional[NestedKey] = None, out_keys: Optional[Sequence[NestedKey]] = None,