SStopping criterion monitoring the quotient of generalization loss and training progress. More...
#include <shark/Algorithms/StoppingCriteria/GeneralizationQuotient.h>
Public Types | |
typedef ValidatedSingleObjectiveResultSet< PointType > | ResultSet |
Public Types inherited from shark::AbstractStoppingCriterion< ValidatedSingleObjectiveResultSet< PointType > > | |
typedef ValidatedSingleObjectiveResultSet< PointType > | ResultSet |
Public Member Functions | |
GeneralizationQuotient (std::size_t intervalSize, double maxLoss) | |
bool | stop (ResultSet const &set) |
returns true if training should stop More... | |
void | reset () |
resets the internal state. call before a new trial More... | |
Protected Attributes | |
double | m_minTraining |
double | m_maxLoss |
double | m_meanPerformance |
std::queue< double > | m_interval |
std::size_t | m_intervalSize |
SStopping criterion monitoring the quotient of generalization loss and training progress.
The GeneralizationQuotient is, as the name suggests, a quotient of two other stopping criteria, namely the generalization loss and theThis stopping criterion is based on the empirical fact that the generalization error does not have a smooth surface. It is normal that during periods of fast learning the generalization loss might increase first and than decrease again. This class calculates the quotient of training progress and generalization loss. It stops if it is bigger than maxloss > 0. Terminology for this and other stopping criteria is taken from (and also see):
Lutz Prechelt. Early Stopping - but when? In Genevieve B. Orr and Klaus-Robert Müller: Neural Networks: Tricks of the Trade, volume 1524 of LNCS, Springer, 1997.
Definition at line 69 of file GeneralizationQuotient.h.
typedef ValidatedSingleObjectiveResultSet<PointType> shark::GeneralizationQuotient< PointType >::ResultSet |
Definition at line 73 of file GeneralizationQuotient.h.
|
inline |
Definition at line 75 of file GeneralizationQuotient.h.
References shark::GeneralizationQuotient< PointType >::m_intervalSize, shark::GeneralizationQuotient< PointType >::m_maxLoss, shark::GeneralizationQuotient< PointType >::reset(), and SHARK_ASSERT.
|
inlinevirtual |
resets the internal state. call before a new trial
Implements shark::AbstractStoppingCriterion< ValidatedSingleObjectiveResultSet< PointType > >.
Definition at line 99 of file GeneralizationQuotient.h.
References shark::GeneralizationQuotient< PointType >::m_interval, and shark::GeneralizationQuotient< PointType >::m_minTraining.
Referenced by shark::GeneralizationQuotient< PointType >::GeneralizationQuotient().
|
inlinevirtual |
returns true if training should stop
Implements shark::AbstractStoppingCriterion< ValidatedSingleObjectiveResultSet< PointType > >.
Definition at line 82 of file GeneralizationQuotient.h.
References shark::GeneralizationQuotient< PointType >::m_minTraining.
|
protected |
Definition at line 109 of file GeneralizationQuotient.h.
Referenced by shark::GeneralizationQuotient< PointType >::reset().
|
protected |
Definition at line 110 of file GeneralizationQuotient.h.
Referenced by shark::GeneralizationQuotient< PointType >::GeneralizationQuotient().
|
protected |
Definition at line 106 of file GeneralizationQuotient.h.
Referenced by shark::GeneralizationQuotient< PointType >::GeneralizationQuotient().
|
protected |
Definition at line 107 of file GeneralizationQuotient.h.
|
protected |
Definition at line 105 of file GeneralizationQuotient.h.
Referenced by shark::GeneralizationQuotient< PointType >::reset(), and shark::GeneralizationQuotient< PointType >::stop().