Maximum Acyclic Subgraph - Multiple Sequence Alignment
MaximumAcyclicSubgraph
Public Member Functions | Public Attributes | List of all members
Agent Class Reference

This Agent class selects edges according to a policy. More...

#include <Agent.h>

Collaboration diagram for Agent:
Collaboration graph
[legend]

Public Member Functions

 Agent ()
 Default constructor.
 
 Agent (Graph &g)
 Default destructor. More...
 
Episode getEpisode ()
 
std::pair< state *, unsigned int > executePolicy (state *s, Policy &p)
 

Public Attributes

state s0
 The initial state where every episode starts.
 
Policy lpolicy
 Pointer to the Policy that Agent currently uses.
 

Detailed Description

This Agent class selects edges according to a policy.

Constructor & Destructor Documentation

Agent::Agent ( Graph g)
inline

Default destructor.

Constructor with Graph and policy being set.

Parameters
gGraph being used to create state
polType of Policy, either Random or Learned

Member Function Documentation

std::pair< state *, unsigned int > Agent::executePolicy ( state s,
Policy &  p 
)

The member executePolicy selects an edge in state s according to Policy p.

Parameters
sExpects a state s as input parameter.
pExpects a policy p as input parameter.
Returns
Returns a state action pair
Episode Agent::getEpisode ( )

This function runs an episode. It relies on s and policy to calculate state-action pairs as well as score.

Returns
This function returns an episode

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