SHOGUN  4.1.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
List of all members | Public Member Functions | Protected Attributes
DescendCorrection Class Referenceabstract

Detailed Description

This is a base class for descend based correction method.

The interfact will be used in DescendUpdaterWithCorrection::update_variable() An example of descend based correction is NesterovMomentumCorrection

Definition at line 57 of file DescendCorrection.h.

Inheritance diagram for DescendCorrection:
Inheritance graph
[legend]

Public Member Functions

 DescendCorrection ()
 
virtual ~DescendCorrection ()
 
virtual void set_correction_weight (float64_t weight)
 
virtual DescendPair get_corrected_descend_direction (float64_t negative_descend_direction, index_t idx)=0
 
virtual void update_context (CMinimizerContext *context)=0
 
virtual void load_from_context (CMinimizerContext *context)=0
 

Protected Attributes

float64_t m_weight
 

Constructor & Destructor Documentation

Definition at line 62 of file DescendCorrection.h.

virtual ~DescendCorrection ( )
virtual

Definition at line 68 of file DescendCorrection.h.

Member Function Documentation

virtual DescendPair get_corrected_descend_direction ( float64_t  negative_descend_direction,
index_t  idx 
)
pure virtual

Get corrected descend direction

Parameters
negative_descend_directionthe negative descend direction
idxthe index of the direction
Returns
DescendPair (corrected descend direction and the change to correct descend direction)

Implemented in AdaptMomentumCorrection, NesterovMomentumCorrection, MomentumCorrection, and StandardMomentumCorrection.

virtual void load_from_context ( CMinimizerContext context)
pure virtual

Load the given context object to restore mutable variables

This method will be called by DescendUpdaterWithCorrection::load_from_context(CMinimizerContext* context)

Parameters
contexta context object

Implemented in AdaptMomentumCorrection, and MomentumCorrection.

virtual void set_correction_weight ( float64_t  weight)
virtual

Set the weight used in descend correction

param weight the weight

Reimplemented in AdaptMomentumCorrection.

Definition at line 74 of file DescendCorrection.h.

virtual void update_context ( CMinimizerContext context)
pure virtual

Update a context object to store mutable variables used in descend update

This method will be called by DescendUpdaterWithCorrection::update_context()

Parameters
contexta context object

Implemented in AdaptMomentumCorrection, and MomentumCorrection.

Member Data Documentation

float64_t m_weight
protected

weight of correction

Definition at line 110 of file DescendCorrection.h.


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

SHOGUN Machine Learning Toolbox - Documentation