Versions in this module Expand all Collapse all v1 v1.6.1 Aug 14, 2026 v1.6.0 Aug 1, 2026 Changes in this version + const EluActivation + const ModeMultiClass + const ModeMultiLabel + const ModeRegression + const ReLUActivation + const SigmoidActivation + const TanhActivation + func ApplyDropoutMask(a *mat.Dense, mask []bool, p float64) + func BinaryCrossEntropy(y_hat, y *mat.Dense, parameters map[string]*mat.Dense, lambd float64) float64 + func CrossEntropy(y_hat, y *mat.Dense, parameters map[string]*mat.Dense, lambd float64) float64 + func DropoutMask(a *mat.Dense, p float64) []bool + func Elu(a *mat.Dense) *mat.Dense + func EluDerivative(a *mat.Dense) *mat.Dense + func Linear(a *mat.Dense) *mat.Dense + func MeanSquaredError(yHat, y *mat.Dense, parameters map[string]*mat.Dense, lambd float64) float64 + func ReLU(a *mat.Dense) *mat.Dense + func ReLUDerivative(a *mat.Dense) *mat.Dense + func Sigmoid(a *mat.Dense) *mat.Dense + func SigmoidDerivative(a *mat.Dense) *mat.Dense + func SigmoidScalar(x float64) float64 + func Softmax(a *mat.Dense) *mat.Dense + func Tanh(a *mat.Dense) *mat.Dense + func TanhDerivative(a *mat.Dense) *mat.Dense + type Activation struct + Derivative ActivationFunction + Function ActivationFunction + Name ActivationType + func NewActivation(actType ActivationType) Activation + type ActivationFunction func(*mat.Dense) *mat.Dense + type ActivationType string + type Dense struct + Activation Activation + Dropout float64 + Iter float64 + L2Regularization float64 + Optimizer Optimizer + OutputActivation OutputActivation + Parameters map[string]*mat.Dense + func NewDense(config DenseConfig) *Dense + func (dn *Dense) BackwardPropagation(Z, A map[string]*mat.Dense, D map[string][]bool, y *mat.Dense) (*mat.Dense, map[string]*mat.Dense, map[string]*mat.Dense) + func (dn *Dense) ForwardPropagation(x *mat.Dense, training bool) (*mat.Dense, map[string]*mat.Dense, map[string]*mat.Dense, map[string][]bool) + func (dn *Dense) MarshalParameters() ([]byte, error) + func (dn *Dense) TrainableParameters(dW, db map[string]*mat.Dense) []*Parameter + func (dn *Dense) UnmarshalParameters(data []byte) error + func (dn *Dense) UpdateParameters(dW, db map[string]*mat.Dense, learningRate float64) + type DenseConfig struct + Activation Activation + NNStructure []int + Optimizer OptimizerType + OutputActivation OutputActivation + type LossFunction func(*mat.Dense, *mat.Dense, map[string]*mat.Dense, float64) float64 + type Mode struct + LossFunction LossFunction + OutputActivation OutputActivation + func NewMode(mode ModeType) Mode + type ModeType string + type Optimizer interface + MarshalState func() ([]byte, error) + Name func() OptimizerType + Step func(parameters []*Parameter, learningRate, t float64) + UnmarshalState func([]byte) error + func NewOptimizer(optType OptimizerType) Optimizer + type OptimizerType string + const AdamOptimizer + const GradientDescentOptimizer + type OutputActivation struct + Function OutputActivationFunction + Mode ModeType + type OutputActivationFunction func(*mat.Dense) *mat.Dense + type Parameter struct + Gradient *mat.Dense + Update func(*mat.Dense) + Value *mat.Dense