Class BestScoreEpochTerminationCondition
- java.lang.Object
-
- org.deeplearning4j.earlystopping.termination.BestScoreEpochTerminationCondition
-
- All Implemented Interfaces:
Serializable,EpochTerminationCondition
public class BestScoreEpochTerminationCondition extends Object implements EpochTerminationCondition
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description BestScoreEpochTerminationCondition(double bestExpectedScore)BestScoreEpochTerminationCondition(double bestExpectedScore, boolean lesserBetter)Deprecated."lessBetter" argument no longer used
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidinitialize()Initialize the epoch termination condition (often a no-op)booleanterminate(int epochNum, double score, boolean minimize)Should the early stopping training terminate at this epoch, based on the calculated score and the epoch number? Returns true if training should terminated, or false otherwiseStringtoString()
-
-
-
Constructor Detail
-
BestScoreEpochTerminationCondition
public BestScoreEpochTerminationCondition(double bestExpectedScore)
-
BestScoreEpochTerminationCondition
@Deprecated public BestScoreEpochTerminationCondition(double bestExpectedScore, boolean lesserBetter)
Deprecated."lessBetter" argument no longer used
-
-
Method Detail
-
initialize
public void initialize()
Description copied from interface:EpochTerminationConditionInitialize the epoch termination condition (often a no-op)- Specified by:
initializein interfaceEpochTerminationCondition
-
terminate
public boolean terminate(int epochNum, double score, boolean minimize)Description copied from interface:EpochTerminationConditionShould the early stopping training terminate at this epoch, based on the calculated score and the epoch number? Returns true if training should terminated, or false otherwise- Specified by:
terminatein interfaceEpochTerminationCondition- Parameters:
epochNum- Number of the last completed epoch (starting at 0)score- Score calculate for this epoch- Returns:
- Whether training should be terminated at this epoch
-
-