-
Notifications
You must be signed in to change notification settings - Fork 418
Open
Labels
bugSomething isn't workingSomething isn't working
Description
Describe the bug
The VecNorm transform produces a bug when calling the to_observation_norm method with multiple keys
To Reproduce
gym_env = GymEnv("MountainCarContinuous-v0", device='cpu')
transformed_env = TransformedEnv(gym_env, VecNorm(in_keys=["observation", "reward"]))
transformed_env.rollout(100)
transformed_env.transform[0].to_observation_norm()
Expected behavior
Should return ObservationNorm but gives following error:
...
out += ObservationNorm
TypeError: 'type' object is not iterable
Reason and Possible fixes
Using the VecNorm transform with only one key works - so to do it for multiple keys one can just use it repeatedly with single keys.
Checklist
- I have checked that there is no similar issue in the repo (required)
- I have read the documentation (required)
- I have provided a minimal working example to reproduce the bug (required)
vmoens
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working