TorchActorCritic¶
-
class
maze.core.agent.torch_actor_critic.
TorchActorCritic
(policy: maze.core.agent.torch_policy.TorchPolicy, critic: Union[maze.core.agent.torch_state_critic.TorchStateCritic, maze.core.agent.torch_state_action_critic.TorchStateActionCritic], device: str)¶ Encapsulates a structured torch policy and critic for training actor-critic algorithms in structured environments.
- Parameters
policy – A structured torch policy for training in structured environments.
critic – A structured torch critic for training in structured environments.
device – Device the model (networks) should be located on (cpu or cuda)
-
property
device
¶ implementation of
TorchModel
-
eval
() → None¶ implementation of
TorchModel
-
load_state_dict
(state_dict: Dict) → None¶ implementation of
TorchModel
-
parameters
() → List[torch.Tensor]¶ implementation of
TorchModel
-
state_dict
() → Dict¶ implementation of
TorchModel
-
to
(device: str)¶ implementation of
TorchModel
-
train
() → None¶ implementation of
TorchModel