go-neural icon indicating copy to clipboard operation
go-neural copied to clipboard

learn.Evaluation() Least Squares Method

Open danhardman opened this issue 8 years ago • 0 comments

I was just checking out the least squares algorithm in the learn.Evaluation() method and I can't find the maths to back up the algorithm used. Would you be able to point me in the right direction?

Why isn't the Means Square Error being used here? Example:

func Evaluation(n *neural.Network, in, ideal []float64) float64 {
    out := n.Calculate(in)

    var e float64
    for i, _ := range out {
        e += math.Pow(out[i]-ideal[i], 2)
    }

    return e / float64(len(out))
}

danhardman avatar Mar 11 '16 14:03 danhardman