Skip to content

Commit

Permalink
amend
Browse files Browse the repository at this point in the history
  • Loading branch information
vmoens committed Apr 8, 2024
1 parent 331faf4 commit 97b69d1
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion sota-implementations/dreamer/dreamer_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -84,11 +84,13 @@ def _make_env(cfg, device):
env = env.append_transform(
TensorDictPrimer(random=False, default_value=0, **default_dict)
)
assert env is not None
return env


def transform_env(cfg, env):
env = TransformedEnv(env)
if not isinstance(env, TransformedEnv):
env = TransformedEnv(env)
if cfg.env.from_pixels:
# transforms pixel from 0-255 to 0-1 (uint8 to float32)
env.append_transform(
Expand Down

0 comments on commit 97b69d1

Please sign in to comment.