forward

package
v0.0.0-...-77f7900 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 19, 2018 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrNoSensors = errors.New("network requires at least 1 input neuron")
	ErrNoOutputs = errors.New("network requires at least 1 output neuron")
)

Known errors

Functions

This section is empty.

Types

type Layer

type Layer struct {
	Activations []evo.Activation // activation functions for neurons in this layer
	Biases      []float64        // bias values for this layer
	Sources     []int            // indexes of source layers
	Weights     []*mat.Dense     // weights to each source layer
}

Layer in the neural network

type Network

type Network struct {
	Layers []Layer
}

Network of layers

func (Network) Activate

func (net Network) Activate(inputs evo.Matrix) (outputs evo.Matrix, err error)

Activate activates the network using the incoming matrix of values

type Translator

type Translator struct {
	DisableSortCheck bool
}

Translator transforms substrates into networks

func (Translator) Translate

func (t Translator) Translate(sub evo.Substrate) (net evo.Network, err error)

Translate the substrate into a network

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL