Public Member Functions
Agent Class Reference

#include <core.hh>

List of all members.

Public Member Functions

virtual int first_action (const std::vector< float > &s)=0
virtual void last_action (float r)=0
virtual int next_action (float r, const std::vector< float > &s)=0
virtual void savePolicy (const char *filename)
virtual void seedExp (std::vector< experience > seeds)
virtual void setDebug (bool d)=0
virtual ~Agent ()

Detailed Description

Interface for an agent. Implementations of the Agent interface determine the choice of actions given previous sensations and rewards.

Definition at line 241 of file core.hh.


Constructor & Destructor Documentation

virtual Agent::~Agent ( ) [inline, virtual]

Definition at line 276 of file core.hh.


Member Function Documentation

virtual int Agent::first_action ( const std::vector< float > &  s) [pure virtual]

Determines the first action that an agent takes in an environment. This method implies that the environment is currently in an initial state.

Parameters:
sThe initial sensation from the environment.
Returns:
The action the agent wishes to take first.
virtual void Agent::last_action ( float  r) [pure virtual]

Gives feedback for the last action taken. This method may only be called if the last method called was first_action or next_action. It implies that the task is episodic and has just terminated. Note that terminal sensations (states) are not represented.

Parameters:
rThe one-step reward resulting from the previous action.
virtual int Agent::next_action ( float  r,
const std::vector< float > &  s 
) [pure virtual]

Determines the next action that an agent takes in an environment and gives feedback for the previous action. This method may only be called if the last method called was first_action or next_action.

Parameters:
rThe one-step reward resulting from the previous action.
sThe current sensation from the environment.
Returns:
The action the agent wishes to take next.
virtual void Agent::savePolicy ( const char *  filename) [inline, virtual]

Save the current policy to a file

Definition at line 274 of file core.hh.

virtual void Agent::seedExp ( std::vector< experience seeds) [inline, virtual]

Use the model seeds from the environment to initialize the agent or its model

Definition at line 271 of file core.hh.

virtual void Agent::setDebug ( bool  d) [pure virtual]

Set some debug flags on/off


The documentation for this class was generated from the following file:


rl_common
Author(s):
autogenerated on Thu Jun 6 2019 22:00:08