Esempio n. 1
0
        private Matrix <double> GradientDescent(double outputCalculated, double error)
        {
            Matrix <double> outputCalculatedMatrix = Matrix <double> .Build.Dense(1, 1, outputCalculated);

            Matrix <double> der = ActivationFunctions.SigmoidDerived(outputCalculatedMatrix);

            return(error * der);
        }
Esempio n. 2
0
        private Matrix <double> GradientDescent(Matrix <double> outputCalculated, Matrix <double> error)
        {
            Matrix <double> der = ActivationFunctions.SigmoidDerived(outputCalculated);

            return(error.PointwiseMultiply(der));
        }