![]() |
aGrUM
0.20.3
a C++ library for (probabilistic) graphical models
|
<agrum/FMDP/simulation/fmdpSimulator.h> More...
#include <fmdpSimulator.h>
Public Attributes | |
Instantiation | currentState_ |
Tha state in which the system currently is. More... | |
Instantiation | endState_ |
Public Member Functions | |
Constructors, Destructors. | |
FMDPSimulator (const FMDP< double > *fmdp) | |
Default constructor. More... | |
FMDPSimulator (const std::string &resource) | |
Default constructor. More... | |
~FMDPSimulator () | |
Default destructor. More... | |
double | reward () |
Sets the intial statefrom which we begun the simulation. More... | |
void | perform (Idx) |
Sets the intial statefrom which we begun the simulation. More... | |
const DiscreteVariable * | primeVar (const DiscreteVariable *mainVar) |
Iteration over the variables of the simulated probleme. More... | |
SequenceIteratorSafe< const DiscreteVariable *> | beginVariables () |
Iteration over the variables of the simulated probleme. More... | |
SequenceIteratorSafe< const DiscreteVariable *> | endVariables () |
Iteration over the variables of the simulated probleme. More... | |
virtual const std::string & | actionName (Idx actionId) |
Iteration over the variables of the simulated probleme. More... | |
SequenceIteratorSafe< Idx > | beginActions () |
Iteration over the variables of the simulated probleme. More... | |
SequenceIteratorSafe< Idx > | endActions () |
Iteration over the variables of the simulated probleme. More... | |
Protected Member Functions | |
virtual double | transitionProbability_ (const DiscreteVariable *var, const Instantiation &transit, Idx actionId) |
INLINE void | setInitialState (const Instantiation &initialState) |
Sets the intial statefrom which we begun the simulation. More... | |
void | setInitialStateRandomly () |
Sets the intial statefrom which we begun the simulation. More... | |
INLINE void | setEndState (const Instantiation &endState) |
Sets the final states upon which a run is over. More... | |
virtual bool | hasReachEnd () |
Tests if end state has been reached. More... | |
INLINE const Instantiation & | currentState () |
Sets the intial statefrom which we begun the simulation. More... | |
virtual Instantiation | randomState_ () |
Choses a random state as the first test for a run. More... | |
<agrum/FMDP/simulation/fmdpSimulator.h>
A class to simulate a Factored Markov Decision Process.
Definition at line 48 of file fmdpSimulator.h.
Default constructor.
Definition at line 47 of file fmdpSimulator.cpp.
References gum::Set< Key, Alloc >::emplace().
gum::FMDPSimulator::FMDPSimulator | ( | const std::string & | resource | ) |
Default constructor.
Definition at line 52 of file fmdpSimulator.cpp.
References gum::Set< Key, Alloc >::emplace().
gum::FMDPSimulator::~FMDPSimulator | ( | ) |
Default destructor.
Definition at line 64 of file fmdpSimulator.cpp.
References gum::Set< Key, Alloc >::emplace().
|
inlinevirtual |
Iteration over the variables of the simulated probleme.
Implements gum::AbstractSimulator.
Definition at line 104 of file fmdpSimulator.h.
|
inlinevirtual |
Iteration over the variables of the simulated probleme.
Implements gum::AbstractSimulator.
Definition at line 107 of file fmdpSimulator.h.
|
inlinevirtual |
Iteration over the variables of the simulated probleme.
Implements gum::AbstractSimulator.
Definition at line 90 of file fmdpSimulator.h.
|
inlineinherited |
Sets the intial statefrom which we begun the simulation.
Definition at line 87 of file abstractSimulator.h.
References gum::AbstractSimulator::reward().
|
inlinevirtual |
Iteration over the variables of the simulated probleme.
Implements gum::AbstractSimulator.
Definition at line 108 of file fmdpSimulator.h.
|
inlinevirtual |
Iteration over the variables of the simulated probleme.
Implements gum::AbstractSimulator.
Definition at line 93 of file fmdpSimulator.h.
|
virtualinherited |
Tests if end state has been reached.
Reimplemented in gum::FactorySimulator, and gum::TaxiSimulator.
Definition at line 84 of file abstractSimulator.cpp.
References gum::Set< Key, Alloc >::emplace().
|
virtual |
Sets the intial statefrom which we begun the simulation.
Implements gum::AbstractSimulator.
Definition at line 74 of file fmdpSimulator.cpp.
References gum::Set< Key, Alloc >::emplace().
|
inlinevirtual |
Iteration over the variables of the simulated probleme.
Implements gum::AbstractSimulator.
Definition at line 85 of file fmdpSimulator.h.
|
protectedvirtualinherited |
Choses a random state as the first test for a run.
Reimplemented in gum::FactorySimulator, and gum::TaxiSimulator.
Definition at line 72 of file abstractSimulator.cpp.
References gum::Set< Key, Alloc >::emplace().
|
inlinevirtual |
Sets the intial statefrom which we begun the simulation.
Implements gum::AbstractSimulator.
Definition at line 74 of file fmdpSimulator.h.
|
inlineinherited |
Sets the final states upon which a run is over.
Definition at line 81 of file abstractSimulator.h.
References gum::AbstractSimulator::reward().
|
inlineinherited |
Sets the intial statefrom which we begun the simulation.
Definition at line 72 of file abstractSimulator.h.
References gum::AbstractSimulator::reward().
|
inherited |
Sets the intial statefrom which we begun the simulation.
Definition at line 64 of file abstractSimulator.cpp.
References gum::Set< Key, Alloc >::emplace().
|
inlineprotectedvirtual |
Definition at line 112 of file fmdpSimulator.h.
The Factored Markov Decision Process that describes how the system evolves.
Definition at line 123 of file fmdpSimulator.h.
|
private |
Just to know if it should be deleted in the end.
Definition at line 126 of file fmdpSimulator.h.
|
inherited |
Tha state in which the system currently is.
Definition at line 125 of file abstractSimulator.h.
|
inherited |
Definition at line 125 of file abstractSimulator.h.