コード例 #1
0
 def __init__(self,
              observation_space,
              net,
              rnn=False,
              data_parallel=False,
              parallel_dim=0):
     super().__init__(observation_space, net, rnn, data_parallel,
                      parallel_dim)
     self.pd = DeterministicPd()
     self.to(get_device())
コード例 #2
0
 def __init__(self,
              observation_space,
              action_space,
              net,
              noise=None,
              rnn=False,
              normalize_ac=True):
     if rnn:
         raise ValueError(
             'rnn with DeterministicActionNoisePol is not supported now')
     BasePol.__init__(self,
                      observation_space,
                      action_space,
                      net,
                      rnn=rnn,
                      normalize_ac=normalize_ac)
     self.noise = noise
     self.pd = DeterministicPd()
     self.to(get_device())
コード例 #3
0
 def __init__(self,
              ob_space,
              ac_space,
              net,
              noise=None,
              rnn=False,
              normalize_ac=True,
              data_parallel=False,
              parallel_dim=0):
     if rnn:
         raise ValueError(
             'rnn with DeterministicActionNoisePol is not supported now')
     BasePol.__init__(self,
                      ob_space,
                      ac_space,
                      net,
                      rnn=rnn,
                      normalize_ac=normalize_ac,
                      data_parallel=data_parallel,
                      parallel_dim=parallel_dim)
     self.noise = noise
     self.pd = DeterministicPd()
     self.to(get_device())
コード例 #4
0
 def __init__(self, observation_space, action_space, net, rnn=False):
     super().__init__(observation_space, action_space, net, rnn)
     self.pd = DeterministicPd()
     self.to(get_device())