class StochasticGradient

Trainer for GradientMachine.

Inheritance:


Public Methods

[more] StochasticGradient(GradientMachine* machine_, Criterion* criterion_)
Take the machine_ to train, the train data_, the criterion_ to use, and the optimizer_ to use


Inherited from Trainer:

Public Methods

ovirtual void train(DataSet* data_, MeasurerList* measurers)
ovirtual void test(MeasurerList* measurers)
ostatic Allocator* extractMeasurers(MeasurerList* measurers, DataSet* train, DataSet*** datas, Measurer**** meas, int** n_meas, int* n_datas)
ovirtual void loadXFile(XFile* file)
ovirtual void saveXFile(XFile* file)


Inherited from Object:

Public Fields

oAllocator* allocator

Public Methods

ovoid addOption(const char* name, int size, void* ptr, const char* help="")
ovoid addIOption(const char* name, int* ptr, int init_value, const char* help="")
ovoid addROption(const char* name, real* ptr, real init_value, const char* help="")
ovoid addBOption(const char* name, bool* ptr, bool init_value, const char* help="")
ovoid addOOption(const char* name, Object** ptr, Object* init_value, const char* help="")
ovoid setOption(const char* name, void* ptr)
ovoid setIOption(const char* name, int option)
ovoid setROption(const char* name, real option)
ovoid setBOption(const char* name, bool option)
ovoid setOOption(const char* name, Object* option)
ovoid load(const char* filename)
ovoid save(const char* filename)
ovoid* operator new(size_t size, Allocator* allocator_=NULL)
ovoid* operator new(size_t size, Allocator* allocator_, void* ptr_)
ovoid operator delete(void* ptr)


Documentation

Trainer for GradientMachine. Given a machine and a criterion, train the machine using a stochastic gradient descent.

Options:
"end accuracy" real end accuracy [0.0001]
"learning rate" real learning rate [0.01]
"learning rate decay" real learning rate decay [0]
"max iter" int maximum number of iterations [-1]
"shuffle" bool shuffle the dataset [true]

o StochasticGradient(GradientMachine* machine_, Criterion* criterion_)
Take the machine_ to train, the train data_, the criterion_ to use, and the optimizer_ to use


This class has no child classes.
Author:
Ronan Collobert (collober@idiap.ch)

Alphabetic index HTML hierarchy of classes or Java



This page was generated with the help of DOC++.