Documentation of 'org.joone.engine.ExtendableLearner' Java class
ExtendableLearner
org.joone.engine

Class ExtendableLearner

  • All Implemented Interfaces:
    java.io.Serializable, Learner
    Direct Known Subclasses:
    BasicLearner, BatchLearner, RpropLearner


    public class ExtendableLearner
    extends AbstractLearner
    Learners that extend this class are forced to implement certain functions, a so-called skeleton. The good thing is, because learners extend this class certain plug-ins can be added. For example, plug ins that change the objective function, or the delta-update rule. Still learners that do not fit into this skeleton have to opportunity to implement Learner directly (or extend AbstractLearner), but it won't be able to use the extra plug-ins (unless it is build in the learner by the programmer itself). Basically, this class is the BasicLearner, but by adding extenders it can provide totally different learning algoriths.
    See Also:
    Serialized Form
    • Constructor Detail

      • ExtendableLearner

        public ExtendableLearner()
        Creates a new instance of ExtendableLearner
    • Method Detail

      • requestBiasUpdate

        public final void requestBiasUpdate(double[] currentGradientOuts)
        Description copied from interface: Learner
        Override this method to implement what should be done to LearnableLayers
      • requestWeightUpdate

        public final void requestWeightUpdate(double[] currentPattern,
                                              double[] currentInps)
        Description copied from interface: Learner
        Override this method to implement what should be done to LearnableSynapses
      • getDefaultDelta

        public double getDefaultDelta(double[] currentGradientOuts,
                                      int j)
        Gets the default (normal calculation of) delta.
        Parameters:
        currentGradientOuts - the back propagated gradients.
        j - the index of the bias.
      • getDefaultDelta

        public double getDefaultDelta(double[] currentInps,
                                      int j,
                                      double[] currentPattern,
                                      int k)
        Gets the default (normal calculation of) delta.
        Parameters:
        currentInps - the forwarded input.
        j - the input index of the weight.
        currentPattern - the back propagated gradients.
        k - the output index of the weight.
      • getGradientBias

        public double getGradientBias(double[] currentGradientOuts,
                                      int j)
        Gets the gradient for biases.
        Parameters:
        currentGradientOuts - the back protected gradients.
        j - the index of the bias.
        Returns:
        the gradient for bias b_i.
      • getDefaultGradientBias

        public double getDefaultGradientBias(double[] currentGradientOuts,
                                             int j)
        Gets the default (normal calculation of the) gradient for biases.
        Parameters:
        currentGradientOuts - the back protected gradients.
        j - the index of the bias.
        Returns:
        the gradient for bias b_i.
      • getGradientWeight

        public double getGradientWeight(double[] currentInps,
                                        int j,
                                        double[] currentPattern,
                                        int k)
        Gets the gradient for weights.
        Parameters:
        aCurrentInps - the forwarded input.
        j - the input index of the weight.
        currentPattern - the back propagated gradients.
        k - the output index of the weight.
        Returns:
        the gradient for the weight w_j_k
      • getDefaultGradientWeight

        public double getDefaultGradientWeight(double[] currentInps,
                                               int j,
                                               double[] currentPattern,
                                               int k)
        Gets the default (normal calculation of the) gradient for weights.
        Parameters:
        aCurrentInps - the forwarded input.
        j - the input index of the weight.
        currentPattern - the back propagated gradients.
        k - the output index of the weight.
        Returns:
        the gradient for the weight w_j_k
      • addDeltaRuleExtender

        public void addDeltaRuleExtender(DeltaRuleExtender aDeltaRuleExtender)
        Adds a delta extender.
        Parameters:
        aDeltaRuleExtender - the delta rule extender to add.
      • addGradientExtender

        public void addGradientExtender(GradientExtender aGradientExtender)
        Adds a gradient extender.
        Parameters:
        aGradientExtender - the gradient extender to add.
      • setUpdateWeightExtender

        public void setUpdateWeightExtender(UpdateWeightExtender anUpdateWeightExtender)
        Sets an update weight extender.
        Parameters:
        anUpdateWeightExtender - the update weight extender to set.
      • getUpdateWeightExtender

        public UpdateWeightExtender getUpdateWeightExtender()
        Gets the update weight extender.
        Returns:
        the update weight extender.

DataMelt 3.0 © DataMelt by jWork.ORG

You see the box below because you did not login.