Exemplo n.º 1
0
 def calc_pdparam(self, x, evaluate=True):
     '''
     Calculate pdparams for multi-action by chunking the network logits output
     '''
     x = torch.cat(torch.split(x, self.state_dims, dim=1)).unsqueeze_(dim=1)
     pdparam = SARSA.calc_pdparam(self, x, evaluate=evaluate)
     return pdparam
Exemplo n.º 2
0
 def calc_pdparam(self, x, evaluate=True):
     '''
     Calculate pdparams for multi-action by chunking the network logits output
     '''
     x = torch.cat(torch.split(x, self.state_dims, dim=1)).unsqueeze_(dim=1)
     pdparam = SARSA.calc_pdparam(self, x, evaluate=evaluate)
     return pdparam
Exemplo n.º 3
0
 def calc_pdparam(self, xs, evaluate=True, net=None):
     '''
     Calculate pdparams for multi-action by chunking the network logits output
     '''
     pdparam = SARSA.calc_pdparam(self, xs, evaluate=evaluate, net=net)
     return pdparam