Skip to content

Commit

Permalink
-fix loading learned strategies
Browse files Browse the repository at this point in the history
  • Loading branch information
nick-harder committed Oct 3, 2023
1 parent b1ae73e commit b29975a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion assume/strategies/learning_strategies.py
Original file line number Diff line number Diff line change
Expand Up @@ -424,7 +424,7 @@ def load_actor_params(self, load_path):
"""
directory = f"{load_path}/actors/actor_{self.unit_id}.pt"

params = th.load(directory)
params = th.load(directory, map_location=self.device)

self.actor = Actor(self.obs_dim, self.act_dim, self.float_type)
self.actor.load_state_dict(params["actor"])
Expand Down

0 comments on commit b29975a

Please sign in to comment.