Michele Milesi commited on
Commit
5d9a387
1 Parent(s): 3b39390
Files changed (2) hide show
  1. agent-dreamer_v3.py +1 -1
  2. agent-ppo.py +1 -1
agent-dreamer_v3.py CHANGED
@@ -79,7 +79,7 @@ def main(cfg_path: str, checkpoint_path: str, test=False):
79
 
80
  while True:
81
  # Convert numpy observations into torch observations and normalize image observations
82
- torch_obs = prepare_obs(fabric, o, cnn_keys)
83
 
84
  # Select actions, the agent returns a one-hot categorical or
85
  # more one-hot categorical distributions for muli-discrete actions space
 
79
 
80
  while True:
81
  # Convert numpy observations into torch observations and normalize image observations
82
+ torch_obs = prepare_obs(fabric, o, cnn_keys=cnn_keys)
83
 
84
  # Select actions, the agent returns a one-hot categorical or
85
  # more one-hot categorical distributions for muli-discrete actions space
agent-ppo.py CHANGED
@@ -69,7 +69,7 @@ def main(cfg_path: str, checkpoint_path: str, test=False):
69
 
70
  while True:
71
  # Convert numpy observations into torch observations and normalize image observations
72
- torch_obs = prepare_obs(fabric, o, cnn_keys)
73
 
74
  actions = agent.get_actions(torch_obs, greedy=True)
75
  actions = torch.cat([act.argmax(dim=-1) for act in actions], dim=-1)
 
69
 
70
  while True:
71
  # Convert numpy observations into torch observations and normalize image observations
72
+ torch_obs = prepare_obs(fabric, o, cnn_keys=cnn_keys)
73
 
74
  actions = agent.get_actions(torch_obs, greedy=True)
75
  actions = torch.cat([act.argmax(dim=-1) for act in actions], dim=-1)