Esempio n. 1
0
 def __init__(self, env):
     super(ActorCriticNet, self).__init__()
     self.affine = nn.Linear(env.state_size, 128)
     self.action_head = nn.Linear(128, env.action_size)
     self.value_head = nn.Linear(128, 1)
     self.distribution = distributions.ActionDistribution(env,
                                                          use_probs=True)
Esempio n. 2
0
 def __init__(self, env, hidden_size=512):
     super(NatureCNN, self).__init__()
     self.input_size = 4
     self.features = atari.NatureFeatures(self.input_size, hidden_size)
     self.critic = atari.NatureCritic(hidden_size)
     self.actor = atari.NatureActor(hidden_size, env.action_size)
     self.action_dist = distributions.ActionDistribution(env, use_probs=False)
Esempio n. 3
0
    def __init__(self, env):
        super(ActorCriticNet, self).__init__()
        self.actor = models.robotics.RoboticsActor(env.state_size,
                                                   env.action_size,
                                                   layer_sizes=[64, 64])
        self.critic = models.robotics.RoboticsMLP(env.state_size, 1)

        self.action_dist = dist.ActionDistribution(env,
                                                   use_probs=False,
                                                   reparam=False)
 def __init__(self, env):
     super(ActorCriticNet, self).__init__()
     self.affine1 = nn.Linear(env.state_size['image'], 128)
     self.action_head = nn.Linear(128, env.action_size)
     self.value_head = nn.Linear(128, 1)
     self.distribution = distributions.ActionDistribution(env)