|
LBANN
0.103.0
LivermoreBigArtificialNeuralNetworkToolkit
|
#include <adagrad.hpp>
Public Types | |
Public Types | |
| using | AbsDistMatrixType = El::AbstractDistMatrix< TensorDataType > |
| The tensor type expected in this object. More... | |
| using | OptimizerType = data_type_optimizer< TensorDataType > |
| The optimizer base type of this object. More... | |
| using | WeightsType = data_type_weights< TensorDataType > |
| The concrete weights type used by this object. More... | |
Public Member Functions | |
| adagrad (TensorDataType learning_rate, TensorDataType eps=1e-8) | |
| adagrad (const adagrad &other) | |
| adagrad & | operator= (const adagrad &other) |
| ~adagrad () override=default | |
| template<class Archive > | |
| void | serialize (Archive &ar) |
| std::string | get_type () const override |
| description | get_description () const override |
| void | setup (WeightsType *w=nullptr) override |
| void | write_proto (lbann_data::Optimizer &opt) const final |
Public Member Functions inherited from lbann::Cloneable< adagrad< TensorDataType >, data_type_optimizer< TensorDataType > > | |
| std::unique_ptr< adagrad< TensorDataType > > | clone () const |
| Return an exception-safe, memory-safe copy of this object. More... | |
Protected Member Functions | |
| adagrad () | |
| Default constructor. More... | |
| void | step_compute (AbsDistMatrixType &values, const AbsDistMatrixType &gradient) override |
Private Types | |
| using | BaseType = Cloneable< adagrad< TensorDataType >, data_type_optimizer< TensorDataType > > |
Private Member Functions | |
| void | step_compute_cpu (AbsDistMatrixType &values, const AbsDistMatrixType &gradient) |
Private Attributes | |
| TensorDataType | m_eps |
| std::unique_ptr< AbsDistMatrixType > | m_cache |
AdaGrad optimizer.
Reference:
John Duchi, Elad Hazan, and Yoram Singer. "Adaptive subgradient methods for online learning and stochastic optimization." Journal of Machine Learning Research 12, no. Jul (2011): 2121-2159.
Definition at line 45 of file adagrad.hpp.
| using lbann::adagrad< TensorDataType >::AbsDistMatrixType = El::AbstractDistMatrix<TensorDataType> |
The tensor type expected in this object.
Definition at line 56 of file adagrad.hpp.
|
private |
Definition at line 49 of file adagrad.hpp.
| using lbann::adagrad< TensorDataType >::OptimizerType = data_type_optimizer<TensorDataType> |
The optimizer base type of this object.
Definition at line 59 of file adagrad.hpp.
| using lbann::adagrad< TensorDataType >::WeightsType = data_type_weights<TensorDataType> |
The concrete weights type used by this object.
Definition at line 62 of file adagrad.hpp.
| lbann::adagrad< TensorDataType >::adagrad | ( | TensorDataType | learning_rate, |
| TensorDataType | eps = 1e-8 |
||
| ) |
| lbann::adagrad< TensorDataType >::adagrad | ( | const adagrad< TensorDataType > & | other | ) |
|
overridedefault |
|
inlineprotected |
Default constructor.
This constructor exists as an implementation detail of the serialization code. It is not for general use.
Definition at line 94 of file adagrad.hpp.
|
override |
Human-readable description.
|
inlineoverride |
Human-readable type name.
Definition at line 77 of file adagrad.hpp.
| adagrad& lbann::adagrad< TensorDataType >::operator= | ( | const adagrad< TensorDataType > & | other | ) |
| void lbann::adagrad< TensorDataType >::serialize | ( | Archive & | ar | ) |
Archive for checkpoint and restart
Definition at line 37 of file adagrad_impl.hpp.
|
override |
|
overrideprotected |
Computation for an optimization step.
|
private |
CPU implementation of optimization step.
|
final |
Add optimizer data to prototext
|
private |
AdaGrad cache.
Definition at line 105 of file adagrad.hpp.
|
private |
Small factor to avoid division by zero.
Definition at line 103 of file adagrad.hpp.