23 #ifndef SRC_APPLICATION_GRIDWORLDDRLEXPERIENCEREPLAYPOMDP_HPP_
24 #define SRC_APPLICATION_GRIDWORLDDRLEXPERIENCEREPLAYPOMDP_HPP_
29 #include <opengl/application/OpenGLEpisodicApplication.hpp>
30 #include <opengl/visualization/WindowCollectorChart.hpp>
31 using namespace mic::opengl::visualization;
33 #include <mlnn/BackpropagationNeuralNetwork.hpp>
35 using namespace mic::mlnn;
36 using namespace mic::types;
42 namespace application {
70 virtual void initialize(
int argc,
char* argv[]);
75 virtual void initializePropertyDependentVariables();
80 virtual bool performSingleStep();
85 virtual void startNewEpisode();
90 virtual void finishCurrentEpisode();
154 float computeBestValueForGivenStateAndPredictions(mic::types::Position2D player_position_,
float* predictions_);
161 mic::types::MatrixXfPtr getPredictedRewardsForGivenState(mic::types::Position2D player_position_);
168 mic::types::NESWAction selectBestActionForGivenState(mic::types::Position2D player_position_);
174 std::string streamNetworkResponseTable();
mic::configuration::Property< std::string > statistics_filename
Property: name of the file to which the statistics will be exported.
long long number_of_successes
Class emulating the gridworld environment.
mic::configuration::Property< int > step_limit
mic::configuration::Property< std::string > mlnn_filename
Property: name of the file to which the neural network will be serialized (or deserialized from)...
mic::utils::DataCollectorPtr< std::string, float > collector_ptr
Data collector.
mic::configuration::Property< float > step_reward
Class responsible for solving the gridworld problem with Q-learning, neural network used for approxim...
mic::configuration::Property< float > learning_rate
long long sum_of_iterations
mic::configuration::Property< double > epsilon
mic::configuration::Property< bool > mlnn_save
Property: flad denoting thether the nn should be saved to a file (after every episode end)...
BackpropagationNeuralNetwork< float > neural_net
Multi-layer neural network used for approximation of the Qstate rewards.
mic::configuration::Property< float > discount_rate
WindowCollectorChart< float > * w_chart
Window for displaying statistics.
SpatialExperienceMemory experiences
mic::environments::Gridworld grid_env
The gridworld environment.
mic::configuration::Property< bool > mlnn_load
Property: flad denoting thether the nn should be loaded from a file (at the initialization of the tas...
size_t batch_size
Size of the batch in experience replay - set to the size of maze (width*height).
Class representing the spatial experience memory - used in memory replay. Derived from the Batch clas...