12 #ifndef MLPACK_METHODS_RL_ENVIRONMENT_ENV_TYPE_HPP 13 #define MLPACK_METHODS_RL_ENVIRONMENT_ENV_TYPE_HPP 52 State(
const arma::colvec& data) : data(data)
56 arma::colvec&
Data() {
return data; }
59 const arma::colvec&
Encode()
const {
return data; }
141 State(
const arma::colvec& data) : data(data)
145 arma::colvec&
Data() {
return data; }
148 const arma::colvec&
Encode()
const {
return data; }
Implementation of continuous action.
Implementation of state of the dummy environment.
To use the dummy environment, one may start by specifying the state and action dimensions.
double Sample(const State &, const Action &, State &)
Dummy function to mimic sampling in an environment.
Linear algebra utility functions, generally performed on matrices or vectors.
double Sample(const State &, const Action &, State &)
Dummy function to mimic sampling in an environment.
State()
Construct a state instance.
State(const arma::colvec &data)
Construct a state instance from given data.
Implementation of state of the dummy environment.
The core includes that mlpack expects; standard C++ includes and Armadillo.
State(const arma::colvec &data)
Construct a state instance from given data.
arma::colvec & Data()
Modify the internal representation of the state.
static size_t dimension
Dimension of the encoded state.
State InitialSample()
Dummy function to mimic initial sampling in an environment.
Action()
Construct an action instance.
To use the dummy environment, one may start by specifying the state and action dimensions.
bool IsTerminal(const State &) const
Dummy function to find terminal state.
const arma::colvec & Encode() const
Encode the state to a column vector.
Implementation of discrete action.
bool IsTerminal(const State &) const
Dummy function to find terminal state.
arma::colvec & Data()
Modify the internal representation of the state.
const arma::colvec & Encode() const
Encode the state to a column vector.
State InitialSample()
Dummy function to mimic initial sampling in an environment.
State()
Construct a state instance.
std::vector< double > action
static size_t dimension
Dimension of the encoded state.