Documentation of 'org.neuroph.core.learning.SupervisedLearning' Java class
SupervisedLearning
org.neuroph.core.learning

Class SupervisedLearning

  • All Implemented Interfaces:
    java.io.Serializable
    Direct Known Subclasses:
    LMS, SimulatedAnnealingLearning


    public abstract class SupervisedLearning
    extends IterativeLearning
    implements java.io.Serializable
    Base class for all supervised learning algorithms. It extends IterativeLearning, and provides general supervised learning principles. Based on Template Method Pattern with abstract method calculateWeightChanges TODO: random pattern order
    See Also:
    Serialized Form
    • Constructor Detail

      • SupervisedLearning

        public SupervisedLearning()
        Creates new supervised learning rule
    • Method Detail

      • learn

        public final void learn(DataSet trainingSet,
                                double maxError)
        Trains network for the specified training set and maxError
        Parameters:
        trainingSet - training set to learn
        maxError - learning stop condition. If maxError is reached learning stops
      • learn

        public final void learn(DataSet trainingSet,
                                double maxError,
                                int maxIterations)
        Trains network for the specified training set, maxError and number of iterations
        Parameters:
        trainingSet - training set to learn
        maxError - learning stop condition. if maxError is reached learning stops
        maxIterations - maximum number of learning iterations
      • doLearningEpoch

        public void doLearningEpoch(DataSet trainingSet)
        This method implements basic logic for one learning epoch for the supervised learning algorithms. Epoch is the one pass through the training set. This method iterates through the training set and trains network for each element. It also sets flag if conditions to stop learning has been reached: network error below some allowed value, or maximum iteration count
        Specified by:
        doLearningEpoch in class IterativeLearning
        Parameters:
        trainingSet - training set for training network
      • isBatchMode

        public boolean isBatchMode()
        Returns true if learning is performed in batch mode, false otherwise
        Returns:
        true if learning is performed in batch mode, false otherwise
      • setBatchMode

        public void setBatchMode(boolean batchMode)
        Sets batch mode on/off (true/false)
        Parameters:
        batchMode - batch mode setting
      • setMaxError

        public void setMaxError(double maxError)
        Sets allowed network error, which indicates when to stopLearning training
        Parameters:
        maxError - network error
      • getMaxError

        public double getMaxError()
        Returns learning error tolerance - the value of total network error to stop learning.
        Returns:
        learning error tolerance
      • getPreviousEpochError

        public double getPreviousEpochError()
        Returns total network error in previous learning epoch
        Returns:
        total network error in previous learning epoch
      • getMinErrorChange

        public double getMinErrorChange()
        Returns min error change stopping criteria
        Returns:
        min error change stopping criteria
      • setMinErrorChange

        public void setMinErrorChange(double minErrorChange)
        Sets min error change stopping criteria
        Parameters:
        minErrorChange - value for min error change stopping criteria
      • getMinErrorChangeIterationsLimit

        public int getMinErrorChangeIterationsLimit()
        Returns number of iterations for min error change stopping criteria
        Returns:
        number of iterations for min error change stopping criteria
      • setMinErrorChangeIterationsLimit

        public void setMinErrorChangeIterationsLimit(int minErrorChangeIterationsLimit)
        Sets number of iterations for min error change stopping criteria
        Parameters:
        minErrorChangeIterationsLimit - number of iterations for min error change stopping criteria
      • getMinErrorChangeIterationsCount

        public int getMinErrorChangeIterationsCount()
        Returns number of iterations count for for min error change stopping criteria
        Returns:
        number of iterations count for for min error change stopping criteria
      • setErrorFunction

        public void setErrorFunction(ErrorFunction errorFunction)
      • getTotalNetworkError

        public double getTotalNetworkError()

DMelt 3.0 © DataMelt by jWork.ORG

You see the box below because you did not login.