AsyncLearning< WorkerType, EnvironmentType, NetworkType, UpdaterType, PolicyType > Class Template Reference

Wrapper of various asynchronous learning algorithms, e.g. More...

Public Member Functions

 AsyncLearning (TrainingConfig config, NetworkType network, PolicyType policy, UpdaterType updater=UpdaterType(), EnvironmentType environment=EnvironmentType())
 Construct an instance of the given async learning algorithm. More...

 
TrainingConfigConfig ()
 Get training config. More...

 
const TrainingConfigConfig () const
 Modify training config. More...

 
EnvironmentType & Environment ()
 Get the environment. More...

 
const EnvironmentType & Environment () const
 Modify the environment. More...

 
NetworkType & Network ()
 Get learning network. More...

 
const NetworkType & Network () const
 Modify learning network. More...

 
PolicyType & Policy ()
 Get behavior policy. More...

 
const PolicyType & Policy () const
 Modify behavior policy. More...

 
template
<
typename
Measure
>
void Train (Measure &measure)
 Starting async training. More...

 
UpdaterType & Updater ()
 Get optimizer. More...

 
const UpdaterType & Updater () const
 Modify optimizer. More...

 

Detailed Description


template
<
typename
WorkerType
,
typename
EnvironmentType
,
typename
NetworkType
,
typename
UpdaterType
,
typename
PolicyType
>

class mlpack::rl::AsyncLearning< WorkerType, EnvironmentType, NetworkType, UpdaterType, PolicyType >

Wrapper of various asynchronous learning algorithms, e.g.

async one-step Q-learning, async one-step Sarsa, async n-step Q-learning and async advantage actor-critic.

For more details, see the following:

@inproceedings{mnih2016asynchronous,
title = {Asynchronous methods for deep reinforcement learning},
author = {Mnih, Volodymyr and Badia, Adria Puigdomenech and Mirza,
Mehdi and Graves, Alex and Lillicrap, Timothy and Harley,
Tim and Silver, David and Kavukcuoglu, Koray},
booktitle = {International Conference on Machine Learning},
pages = {1928--1937},
year = {2016}
}
Template Parameters
WorkerTypeThe type of the worker.
EnvironmentTypeThe type of reinforcement learning task.
NetworkTypeThe type of the network model.
UpdaterTypeThe type of the optimizer.
PolicyTypeThe type of the behavior policy.

Definition at line 57 of file async_learning.hpp.

Constructor & Destructor Documentation

◆ AsyncLearning()

AsyncLearning ( TrainingConfig  config,
NetworkType  network,
PolicyType  policy,
UpdaterType  updater = UpdaterType(),
EnvironmentType  environment = EnvironmentType() 
)

Construct an instance of the given async learning algorithm.

Parameters
configHyper-parameters for training.
networkThe network model.
policyThe behavior policy.
updaterThe optimizer.
environmentThe reinforcement learning task.

Member Function Documentation

◆ Config() [1/2]

TrainingConfig& Config ( )
inline

Get training config.

Definition at line 92 of file async_learning.hpp.

◆ Config() [2/2]

const TrainingConfig& Config ( ) const
inline

Modify training config.

Definition at line 94 of file async_learning.hpp.

◆ Environment() [1/2]

EnvironmentType& Environment ( )
inline

Get the environment.

Definition at line 112 of file async_learning.hpp.

◆ Environment() [2/2]

const EnvironmentType& Environment ( ) const
inline

Modify the environment.

Definition at line 114 of file async_learning.hpp.

◆ Network() [1/2]

NetworkType& Network ( )
inline

Get learning network.

Definition at line 97 of file async_learning.hpp.

◆ Network() [2/2]

const NetworkType& Network ( ) const
inline

Modify learning network.

Definition at line 99 of file async_learning.hpp.

◆ Policy() [1/2]

PolicyType& Policy ( )
inline

Get behavior policy.

Definition at line 102 of file async_learning.hpp.

◆ Policy() [2/2]

const PolicyType& Policy ( ) const
inline

Modify behavior policy.

Definition at line 104 of file async_learning.hpp.

◆ Train()

void Train ( Measure &  measure)

Starting async training.

Template Parameters
MeasureThe type of the measurement. It should be a callable object like
bool foo(double reward);
where reward is the total reward of a deterministic test episode, and the return value should indicate whether the training process is completed.
Parameters
measureThe measurement instance.

◆ Updater() [1/2]

UpdaterType& Updater ( )
inline

Get optimizer.

Definition at line 107 of file async_learning.hpp.

◆ Updater() [2/2]

const UpdaterType& Updater ( ) const
inline

Modify optimizer.

Definition at line 109 of file async_learning.hpp.


The documentation for this class was generated from the following file:
  • /home/jenkins-mlpack/mlpack.org/_src/mlpack-3.2.1/src/mlpack/methods/reinforcement_learning/async_learning.hpp