9#ifndef ADAPTIVEMOMENTESTIMATION_H
10#define ADAPTIVEMOMENTESTIMATION_H
32#include "loss_index.h"
33#include "optimization_algorithm.h"
39struct AdaptiveMomentEstimationData;
87 Index get_batch_samples_number()
const;
171 #include "../../opennn-cuda/opennn-cuda/adaptive_moment_estimation_cuda.h"
193 Index learning_rate_iteration = 0;
195 Tensor<type, 1> gradient_exponential_decay;
196 Tensor<type, 1> square_gradient_exponential_decay;
TrainingResults perform_training()
const type & get_epsilon() const
Returns epsilon.
void set_loss_index_pointer(LossIndex *)
const type & get_maximum_time() const
Returns the maximum training time.
const type & get_beta_2() const
Returns beta 2.
const type & get_loss_goal() const
void from_XML(const tinyxml2::XMLDocument &)
void set_default()
Sets the members of the optimization algorithm object to their default values.
AdaptiveMomentEstimation()
type initial_learning_rate
Initial learning rate.
const type & get_beta_1() const
Returns beta 1.
void set_epsilon(const type &)
Tensor< string, 2 > to_string_matrix() const
Writes as matrix of strings the most representative atributes.
type beta_1
Exponential decay over gradient estimates.
string write_optimization_algorithm_type() const
Return the algorithm optimum for your model.
void set_initial_learning_rate(const type &)
void set_maximum_time(const type &)
void set_loss_goal(const type &)
type epsilon
Small number to prevent any division by zero.
void set_beta_2(const type &)
void set_batch_samples_number(const Index &new_batch_samples_number)
Set number of samples in each batch. Default 1000.
type maximum_time
Maximum training time. It is used as a stopping criterion.
void set_maximum_epochs_number(const Index &)
void update_parameters(LossIndexBackPropagation &, AdaptiveMomentEstimationData &)
Update iteration parameters.
type initial_decay
Learning rate decay over each update.
type training_loss_goal
Goal value for the loss. It is used as a stopping criterion.
virtual ~AdaptiveMomentEstimation()
Destructor.
Index maximum_epochs_number
Maximum epochs number.
void write_XML(tinyxml2::XMLPrinter &) const
Index batch_samples_number
Training and selection batch size.
Index maximum_selection_failures
Maximum number of times when selection error increases.
void set_beta_1(const type &)
const type & get_initial_learning_rate() const
Returns the initial learning rate.
type beta_2
Exponential decay over square gradient estimates.
This abstract class represents the concept of loss index composed of an error term and a regularizati...
AdaptiveMomentEstimationData()
Default constructor.
This structure contains the optimization algorithm results.