Commit 2be9cd06 authored by Siddhartha Laghuvarapu's avatar Siddhartha Laghuvarapu
Browse files

Include policy id in compute actions

parent 746f16f0
...@@ -13,13 +13,12 @@ class NeuralBaselineAgent(NeuralMMOAgent): ...@@ -13,13 +13,12 @@ class NeuralBaselineAgent(NeuralMMOAgent):
def register_reset(self, observations): def register_reset(self, observations):
obs = {0:observations} obs = {0:observations}
actions,self.state,_ = self.trainer.compute_actions(obs) actions,self.state,_ = self.trainer.compute_actions(obs,state={},policy_id='policy_0')
# action = self.get_action(observations) # action = self.get_action(observations)
return actions[0] return actions[0]
def compute_action(self, observations, info=None): def compute_action(self, observations, info=None):
obs = {0:observations} obs = {0:observations}
actions,self.state,_ = self.trainer.compute_actions(obs) actions,self.state,_ = self.trainer.compute_actions(obs,state={},policy_id='policy_0')
# action = self.get_action(observations) # action = self.get_action(observations)
return actions[0] return actions[0]
\ No newline at end of file
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment