pantheonrl.common.agents.StaticPolicyAgent

class StaticPolicyAgent(policy)[source]

Bases: Agent

Agent representing a static (not learning) policy.

Parameters:

policy (ActorCriticPolicy) – Policy representing the agent’s responses to observations

Methods

get_action

Return an action given an observation.

update

Update does nothing since the agent does not learn.

get_action(obs)[source]

Return an action given an observation.

Parameters:

obs (Observation) – The observation to use

Returns:

The action to take

Return type:

ndarray

update(reward, done)[source]

Update does nothing since the agent does not learn.

Parameters:
  • reward (float) – The reward receieved from the previous action step

  • done (bool) – Whether the game is done

Return type:

None