14#ifndef MLPACK_METHODS_RL_ASYNC_LEARNING_HPP
15#define MLPACK_METHODS_RL_ASYNC_LEARNING_HPP
52 typename EnvironmentType,
72 UpdaterType updater = UpdaterType(),
73 EnvironmentType environment = EnvironmentType());
88 template <
typename Measure>
97 NetworkType&
Network() {
return learningNetwork; }
99 const NetworkType&
Network()
const {
return learningNetwork; }
104 const PolicyType&
Policy()
const {
return policy; }
109 const UpdaterType&
Updater()
const {
return updater; }
114 const EnvironmentType&
Environment()
const {
return environment; }
121 NetworkType learningNetwork;
130 EnvironmentType environment;
142 typename EnvironmentType,
143 typename NetworkType,
144 typename UpdaterType,
147class OneStepQLearningWorker;
158 typename EnvironmentType,
159 typename NetworkType,
160 typename UpdaterType,
163class OneStepSarsaWorker;
174 typename EnvironmentType,
175 typename NetworkType,
176 typename UpdaterType,
179class NStepQLearningWorker;
190 typename EnvironmentType,
191 typename NetworkType,
192 typename UpdaterType,
196 NetworkType, UpdaterType, PolicyType>, EnvironmentType, NetworkType,
197 UpdaterType, PolicyType>;
208 typename EnvironmentType,
209 typename NetworkType,
210 typename UpdaterType,
214 NetworkType, UpdaterType, PolicyType>, EnvironmentType, NetworkType,
215 UpdaterType, PolicyType>;
226 typename EnvironmentType,
227 typename NetworkType,
228 typename UpdaterType,
232 NetworkType, UpdaterType, PolicyType>, EnvironmentType, NetworkType,
233 UpdaterType, PolicyType>;
239#include "async_learning_impl.hpp"
Wrapper of various asynchronous learning algorithms, e.g.
const TrainingConfig & Config() const
Modify training config.
AsyncLearning(TrainingConfig config, NetworkType network, PolicyType policy, UpdaterType updater=UpdaterType(), EnvironmentType environment=EnvironmentType())
Construct an instance of the given async learning algorithm.
NetworkType & Network()
Get learning network.
TrainingConfig & Config()
Get training config.
const PolicyType & Policy() const
Modify behavior policy.
PolicyType & Policy()
Get behavior policy.
const UpdaterType & Updater() const
Modify optimizer.
void Train(Measure &measure)
Starting async training.
UpdaterType & Updater()
Get optimizer.
EnvironmentType & Environment()
Get the environment.
const EnvironmentType & Environment() const
Modify the environment.
const NetworkType & Network() const
Modify learning network.
Forward declaration of NStepQLearningWorker.
Forward declaration of OneStepQLearningWorker.
Forward declaration of OneStepSarsaWorker.
Linear algebra utility functions, generally performed on matrices or vectors.
The core includes that mlpack expects; standard C++ includes and Armadillo.