Class AbstractActivationFunction

    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      de.jungblut.math.DoubleMatrix apply​(de.jungblut.math.DoubleMatrix matrix)
      Applies the gradient of the activation function on each element in the given matrix.
      de.jungblut.math.DoubleVector apply​(de.jungblut.math.DoubleVector vector)
      Applies the activation function on each element in the given vector.
      de.jungblut.math.DoubleMatrix gradient​(de.jungblut.math.DoubleMatrix matrix)
      Applies the gradient of the activation function on each element in the given matrix.
      de.jungblut.math.DoubleVector gradient​(de.jungblut.math.DoubleVector vector)
      Applies the gradient of the activation function on each element in the given vector.
      protected de.jungblut.math.DoubleMatrix newInstance​(de.jungblut.math.DoubleMatrix mat)  
      protected de.jungblut.math.DoubleVector newInstance​(de.jungblut.math.DoubleVector v)  
      java.lang.String toString()  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • AbstractActivationFunction

        public AbstractActivationFunction()
    • Method Detail

      • apply

        public de.jungblut.math.DoubleVector apply​(de.jungblut.math.DoubleVector vector)
        Description copied from interface: ActivationFunction
        Applies the activation function on each element in the given vector.
        Specified by:
        apply in interface ActivationFunction
        Parameters:
        vector - the vector to apply this function on.
        Returns:
        a new vector that contains the activated elements.
      • apply

        public de.jungblut.math.DoubleMatrix apply​(de.jungblut.math.DoubleMatrix matrix)
        Description copied from interface: ActivationFunction
        Applies the gradient of the activation function on each element in the given matrix.
        Specified by:
        apply in interface ActivationFunction
        Parameters:
        matrix - the matrix to apply this function on.
        Returns:
        a new matrix that contains the gradient of the elements.
      • gradient

        public de.jungblut.math.DoubleVector gradient​(de.jungblut.math.DoubleVector vector)
        Description copied from interface: ActivationFunction
        Applies the gradient of the activation function on each element in the given vector.
        Specified by:
        gradient in interface ActivationFunction
        Parameters:
        vector - the vector to apply this function on.
        Returns:
        a new vector that contains the gradient of the elements.
      • gradient

        public de.jungblut.math.DoubleMatrix gradient​(de.jungblut.math.DoubleMatrix matrix)
        Description copied from interface: ActivationFunction
        Applies the gradient of the activation function on each element in the given matrix.
        Specified by:
        gradient in interface ActivationFunction
        Parameters:
        matrix - the matrix to apply this function on.
        Returns:
        a new matrix that contains the gradient of the elements.
      • newInstance

        protected de.jungblut.math.DoubleMatrix newInstance​(de.jungblut.math.DoubleMatrix mat)
      • newInstance

        protected de.jungblut.math.DoubleVector newInstance​(de.jungblut.math.DoubleVector v)
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object