Fido
 All Classes Namespaces Files Functions Variables Typedefs Macros Pages
Public Member Functions | Public Attributes | Protected Member Functions | Protected Attributes | List of all members
net::Adadelta Class Reference

An adaptive learning rate Trainer (Zeiler). More...

#include <Adadelta.h>

Inherits net::SGDTrainer.

Public Member Functions

 Adadelta (double rho_, double targetErrorLevel_, int maximumEpochs_)
 Initialize an Adadelta object with necessary constants. More...
 
void store (std::ofstream *output)
 Stores an Adadelta object using specified ofstream. More...
 
bool initFromStream (std::ifstream *in)
 
- Public Member Functions inherited from net::SGDTrainer
 SGDTrainer ()
 Initialize empty Backpropagation object. More...
 
 SGDTrainer (double targetErrorLevel_, int maximumEpochs_)
 Initialize the object with necessary constants. More...
 
double train (net::NeuralNet *network, const std::vector< std::vector< double > > &input, const std::vector< std::vector< double > > &correctOutput)
 Trains a neural network on a training set until the target error level is reached. More...
 
double trainEpocs (double numberOfEpochs, net::NeuralNet *network, const std::vector< std::vector< double > > &input, const std::vector< std::vector< double > > &correctOutput)
 Trains a neural network on a training set for a specified number of epochs. More...
 
void store (std::ofstream *out)
 Stores a Trainer object using specified stream. More...
 
bool initFromStream (std::ifstream *in)
 
- Public Member Functions inherited from net::Trainer
std::vector< std::vector
< std::vector< std::vector
< double > > > > 
getGradients ()
 
std::vector< std::vector
< std::vector< std::vector
< double > > > > 
getWeightChanges ()
 
std::vector< std::vector
< std::vector< double > > > 
getInitialWeights ()
 
std::vector< std::vector
< std::vector< double > > > 
getFinalWeights ()
 

Public Attributes

double rho
 the decay rate of the system, set by constructor More...
 
double epsilon
 a very small number used for root mean square calculations More...
 
- Public Attributes inherited from net::SGDTrainer
double targetErrorLevel
 The target error level, set by constructor. More...
 
int maximumEpochs
 The maximum number of iterations, set by constructor. More...
 

Protected Member Functions

void resetNetworkVectors (net::NeuralNet *network)
 Resets the Adadelta object's accumulation vectors. More...
 
double getChangeInWeight (double weight, int layerIndex, int neuronIndex, int weightIndex)
 
- Protected Member Functions inherited from net::SGDTrainer
double trainOnDataPoint (net::NeuralNet *network, const std::vector< double > &input, const std::vector< double > &correctOutput)
 Gets the output of the neural network, calculates the error of each neuron, and edits the weights of the neurons to reduce error. More...
 

Protected Attributes

std::vector< std::vector
< std::vector< double > > > 
accumulatedGradients
 
std::vector< std::vector
< std::vector< double > > > 
accumulatedUpdates
 
- Protected Attributes inherited from net::Trainer
std::vector< std::vector
< std::vector< std::vector
< double > > > > 
gradients
 
std::vector< std::vector
< std::vector< std::vector
< double > > > > 
weightChanges
 
std::vector< std::vector
< std::vector< double > > > 
initialWeights
 
std::vector< std::vector
< std::vector< double > > > 
finalWeights
 

Detailed Description

An adaptive learning rate Trainer (Zeiler).

Constructor & Destructor Documentation

Adadelta::Adadelta ( double  rho_,
double  targetErrorLevel_,
int  maximumEpochs_ 
)

Initialize an Adadelta object with necessary constants.

Parameters
rho_decay level of the trainer. Between 0 and 1.
targetErrorLevel_at this error level, a net will be considered trained
maximumEpochs_after this number of training iterations (one pass through all of the data points), a net will stop being trained no matter what

Member Function Documentation

double Adadelta::getChangeInWeight ( double  weight,
int  layerIndex,
int  neuronIndex,
int  weightIndex 
)
protectedvirtual

Implements net::SGDTrainer.

bool Adadelta::initFromStream ( std::ifstream *  in)
void Adadelta::resetNetworkVectors ( net::NeuralNet network)
protectedvirtual

Resets the Adadelta object's accumulation vectors.

Reimplemented from net::SGDTrainer.

void Adadelta::store ( std::ofstream *  output)
virtual

Stores an Adadelta object using specified ofstream.

Parameters
outputpointer to the output stream which the neural network will be written to

Implements net::Trainer.

Member Data Documentation

std::vector< std::vector< std::vector<double> > > net::Adadelta::accumulatedGradients
protected
std::vector< std::vector< std::vector<double> > > net::Adadelta::accumulatedUpdates
protected
double net::Adadelta::epsilon

a very small number used for root mean square calculations

double net::Adadelta::rho

the decay rate of the system, set by constructor


The documentation for this class was generated from the following files: