Agent
- class agent.supervised_agent.SupervisedAgent(agent_id='Default Agent', log_path='./Brains', **kwargs)[source]
A class representing a supervised agent.
- agent_id
The ID of the agent.
- Type:
str
- log_path
The path to save the agent’s logs.
- Type:
str
- callback
The callback for saving the best model.
- hparamcallback
The callback for saving hyperparameters.
- Type:
- checkpoint_callback
The callback for saving checkpoints.
- Type:
CheckpointCallback
- callback_list
The list of callbacks.
- Type:
CallbackList
- create_model(policy_model, envs, policy_kwargs)[source]
Creates a PPO model for the supervised agent.
- Parameters:
policy_model (object) – The policy model to be used.
envs (object) – The environment to interact with.
policy_kwargs (dict) – Additional keyword arguments for the policy.
- Returns:
The recurrent model for the supervised agent.
- Return type:
object
- create_recurrent_model(policy_model, envs, policy_kwargs)[source]
Creates a recurrent PPO model for the supervised agent.
- Parameters:
policy_model (object) – The policy model to be used.
envs (object) – The environment to interact with.
policy_kwargs (dict) – Additional keyword arguments for the policy.
- Returns:
The recurrent model for the supervised agent.
- Return type:
object