OpenANN  1.1.0
An open source library for artificial neural networks.
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
List of all members | Public Member Functions
NeuroEvolutionAgent Class Reference

#include <NeuroEvolutionAgent.h>

+ Inheritance diagram for NeuroEvolutionAgent:

Public Member Functions

 NeuroEvolutionAgent (int h, bool b, const std::string &a, bool compress=false, int m=0, bool fullyObservable=true, bool alphaBetaFilter=false, bool doubleExponentialSmoothing=false)
 
 ~NeuroEvolutionAgent ()
 
virtual void abandoneIn (Environment &environment)
 Abandon an agent in an environment. More...
 
virtual void chooseAction ()
 Choose an action and execute it in the environment. More...
 
virtual void chooseOptimalAction ()
 Choose an action and execute it in the environment. More...
 
virtual const Eigen::VectorXd & currentParameters ()
 Request the current parameters. More...
 
virtual unsigned int dimension ()
 Request the number of optimizable parameters. More...
 
virtual double error ()
 Compute error on training set. More...
 
virtual Eigen::VectorXd gradient ()
 Compute gradient of the error function with respect to the parameters. More...
 
virtual void initialize ()
 Initialize the optimizable parameters. More...
 
virtual bool providesGradient ()
 Check if the object provides a gradient of the error function with respect to its parameters. More...
 
virtual bool providesInitialization ()
 Check if the object knows how to initialize its parameters. More...
 
virtual void setParameters (const Eigen::VectorXd &parameters)
 Set new parameters. More...
 
void setSigma0 (double sigma0)
 
- Public Member Functions inherited from OpenANN::Agent
virtual ~Agent ()
 
- Public Member Functions inherited from OpenANN::Optimizable
virtual ~Optimizable ()
 
virtual void finishedIteration ()
 This callback is called after each optimization algorithm iteration. More...
 
virtual unsigned examples ()
 Request number of training examples. More...
 
virtual double error (unsigned n)
 Compute error of a given training example. More...
 
virtual Eigen::VectorXd gradient (unsigned n)
 Compute gradient of a given training example. More...
 
virtual void errorGradient (int n, double &value, Eigen::VectorXd &grad)
 Calculates the function value and gradient of a training example. More...
 
virtual void errorGradient (double &value, Eigen::VectorXd &grad)
 Calculates the function value and gradient of all training examples. More...
 
virtual Eigen::VectorXd error (std::vector< int >::const_iterator startN, std::vector< int >::const_iterator endN)
 Calculates the errors of given training examples. More...
 
virtual Eigen::VectorXd gradient (std::vector< int >::const_iterator startN, std::vector< int >::const_iterator endN)
 Calculates the accumulated gradient of given training examples. More...
 
virtual void errorGradient (std::vector< int >::const_iterator startN, std::vector< int >::const_iterator endN, double &value, Eigen::VectorXd &grad)
 Calculates the accumulated gradient and error of given training examples. More...
 

Constructor & Destructor Documentation

NeuroEvolutionAgent::NeuroEvolutionAgent ( int  h,
bool  b,
const std::string &  a,
bool  compress = false,
int  m = 0,
bool  fullyObservable = true,
bool  alphaBetaFilter = false,
bool  doubleExponentialSmoothing = false 
)
NeuroEvolutionAgent::~NeuroEvolutionAgent ( )

Member Function Documentation

void NeuroEvolutionAgent::abandoneIn ( Environment environment)
virtual

Abandon an agent in an environment.

Parameters
environmentreinforcement learning environment

Implements OpenANN::Agent.

void NeuroEvolutionAgent::chooseAction ( )
virtual

Choose an action and execute it in the environment.

This action might not be optimal, i.e. the agent is allowed to explore.

Implements OpenANN::Agent.

void NeuroEvolutionAgent::chooseOptimalAction ( )
virtual

Choose an action and execute it in the environment.

The action must be optimal, i.e. the agent must exploit the learned policy.

Implements OpenANN::Agent.

const Eigen::VectorXd & NeuroEvolutionAgent::currentParameters ( )
virtual

Request the current parameters.

Returns
current parameters

Implements OpenANN::Optimizable.

unsigned int NeuroEvolutionAgent::dimension ( )
virtual

Request the number of optimizable parameters.

Returns
number of optimizable parameters

Implements OpenANN::Optimizable.

double NeuroEvolutionAgent::error ( )
virtual

Compute error on training set.

Returns
current error on training set or objective function value

Implements OpenANN::Optimizable.

Eigen::VectorXd NeuroEvolutionAgent::gradient ( )
virtual

Compute gradient of the error function with respect to the parameters.

Returns
gradient

Implements OpenANN::Optimizable.

void NeuroEvolutionAgent::initialize ( )
virtual

Initialize the optimizable parameters.

Implements OpenANN::Optimizable.

bool NeuroEvolutionAgent::providesGradient ( )
virtual

Check if the object provides a gradient of the error function with respect to its parameters.

Returns
does the optimizable provide a gradient?

Implements OpenANN::Optimizable.

bool NeuroEvolutionAgent::providesInitialization ( )
virtual

Check if the object knows how to initialize its parameters.

Returns
does the optimizable object provide a parameter initialization?

Implements OpenANN::Optimizable.

void NeuroEvolutionAgent::setParameters ( const Eigen::VectorXd &  parameters)
virtual

Set new parameters.

Parameters
parametersnew parameters

Implements OpenANN::Optimizable.

void NeuroEvolutionAgent::setSigma0 ( double  sigma0)

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