1
0
mirror of https://github.com/sjwhitworth/golearn.git synced 2025-04-25 13:48:49 +08:00
golearn/neural/neural.go
Richard Townsend ff52c013eb Update gonum to latest version
Should fix #200 and #205
2018-03-24 00:19:35 +00:00

20 lines
510 B
Go

//Package neural contains Neural Network functions.
package neural
import (
"gonum.org/v1/gonum/mat"
)
type ActivationFunction func(float64) float64
// First function is always the forward activation function
// Second function is always the backward activation function
type NeuralFunction struct {
Forward ActivationFunction
Backward ActivationFunction
}
// LayerFuncs are vectorised layer value transformation functions
// (e.g. sigmoid). They must operate in-place.
type LayerFunc func(*mat.Dense)