bitrl & cuberl Documentation
Simulation engine for reinforcement learning agents
Loading...
Searching...
No Matches
cuberl::rl::policies::RandomTabularPolicy Class Reference

class RandomTabularPolicy More...

#include <random_tabular_policy.h>

Public Types

typedef uint_t output_type
 The type returned when calling this->operator()
 

Public Member Functions

 RandomTabularPolicy ()
 Constructor.
 
 RandomTabularPolicy (uint_t seed)
 Constructor Initialize with a seed.
 
template<typename MatType >
output_type operator() (const MatType &q_map, uint_t state_idx) const
 operator(). Given a
 
template<typename VecTp >
output_type operator() (const VecTp &vec) const
 operator(). Given a vector always returns the position of the maximum occuring element. If the given vector is empty returns CubeAIConsts::invalid_size_type
 
template<typename MatType >
output_type get_action (const MatType &q_map, uint_t state_idx)
 get_action. Given a
 
template<typename VecTp >
output_type get_action (const VecTp &q_map)
 get_action. Given a vector always returns the position of the maximum occuring element. If the given vector is empty returns CubeAIConsts::invalid_size_type
 
void on_episode (uint_t) noexcept
 any actions the policy should perform on the given episode index
 
void reset () noexcept
 Reset the policy.
 

Detailed Description

Member Typedef Documentation

◆ output_type

The type returned when calling this->operator()

Constructor & Destructor Documentation

◆ RandomTabularPolicy() [1/2]

cuberl::rl::policies::RandomTabularPolicy::RandomTabularPolicy ( )

Constructor.

◆ RandomTabularPolicy() [2/2]

cuberl::rl::policies::RandomTabularPolicy::RandomTabularPolicy ( uint_t  seed)
explicit

Constructor Initialize with a seed.

Member Function Documentation

◆ get_action() [1/2]

template<typename MatType >
output_type cuberl::rl::policies::RandomTabularPolicy::get_action ( const MatType &  q_map,
uint_t  state_idx 
)

get_action. Given a

◆ get_action() [2/2]

template<typename VecTp >
RandomTabularPolicy::output_type cuberl::rl::policies::RandomTabularPolicy::get_action ( const VecTp &  q_map)

get_action. Given a vector always returns the position of the maximum occuring element. If the given vector is empty returns CubeAIConsts::invalid_size_type

◆ on_episode()

void cuberl::rl::policies::RandomTabularPolicy::on_episode ( uint_t  )
inlinenoexcept

any actions the policy should perform on the given episode index

◆ operator()() [1/2]

template<typename MatType >
output_type cuberl::rl::policies::RandomTabularPolicy::operator() ( const MatType &  q_map,
uint_t  state_idx 
) const

operator(). Given a

◆ operator()() [2/2]

template<typename VecTp >
RandomTabularPolicy::output_type cuberl::rl::policies::RandomTabularPolicy::operator() ( const VecTp &  vec) const

operator(). Given a vector always returns the position of the maximum occuring element. If the given vector is empty returns CubeAIConsts::invalid_size_type

◆ reset()

void cuberl::rl::policies::RandomTabularPolicy::reset ( )
inlinenoexcept

Reset the policy.


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