Versions in this module Expand all Collapse all v2 v2.8.7 Jul 26, 2021 v2.8.6 Jul 26, 2021 v2.8.5 Jul 23, 2021 v2.8.4 Jul 23, 2021 v2.8.3 Jul 23, 2021 Changes in this version + var NetErrDepthCalculationFailedLoopDetected = errors.New("depth can not be determined for network with loop") + var NetErrExceededMaxActivationAttempts = errors.New("maximal network activation attempts exceeded") + var NetErrUnsupportedSensorsArraySize = errors.New("the sensors array size is unsupported by network solver") + func ActivateModule(module *NNode, a *neatmath.NodeActivatorsFactory) error + func ActivateNode(node *NNode, a *neatmath.NodeActivatorsFactory) error + func NeuronTypeName(nlayer NodeNeuronType) string + func NodeTypeName(nType NodeType) string + type FastControlNode struct + ActivationType neatmath.NodeActivationType + InputIndexes []int + OutputIndexes []int + type FastModularNetworkSolver struct + Id int + Name string + func NewFastModularNetworkSolver(biasNeuronCount, inputNeuronCount, outputNeuronCount, totalNeuronCount int, ...) *FastModularNetworkSolver + func (s *FastModularNetworkSolver) Flush() (bool, error) + func (s *FastModularNetworkSolver) ForwardSteps(steps int) (res bool, err error) + func (s *FastModularNetworkSolver) LinkCount() int + func (s *FastModularNetworkSolver) LoadSensors(inputs []float64) error + func (s *FastModularNetworkSolver) NodeCount() int + func (s *FastModularNetworkSolver) ReadOutputs() []float64 + func (s *FastModularNetworkSolver) RecursiveSteps() (res bool, err error) + func (s *FastModularNetworkSolver) Relax(maxSteps int, maxAllowedSignalDelta float64) (relaxed bool, err error) + func (s *FastModularNetworkSolver) String() string + type FastNetworkLink struct + Signal float64 + SourceIndex int + TargetIndex int + Weight float64 + type Link struct + AddedWeight float64 + InNode *NNode + IsRecurrent bool + IsTimeDelayed bool + OutNode *NNode + Params []float64 + Trait *neat.Trait + Weight float64 + func NewLink(weight float64, inputNode, outNode *NNode, recurrent bool) *Link + func NewLinkCopy(l *Link, inputNode, outNode *NNode) *Link + func NewLinkWithTrait(trait *neat.Trait, weight float64, inputNode, outNode *NNode, recurrent bool) *Link + func (l *Link) IsEqualGenetically(ol *Link) bool + func (l *Link) String() string + type NNode struct + Activation float64 + ActivationSum float64 + ActivationType math.NodeActivationType + ActivationsCount int32 + Id int + Incoming []*Link + NeuronType NodeNeuronType + Outgoing []*Link + Params []float64 + PhenotypeAnalogue *NNode + Trait *neat.Trait + func NewNNode(nodeId int, neuronType NodeNeuronType) *NNode + func NewNNodeCopy(n *NNode, t *neat.Trait) *NNode + func NewNetworkNode() *NNode + func (n *NNode) Depth(d int) (int, error) + func (n *NNode) Flushback() + func (n *NNode) FlushbackCheck() error + func (n *NNode) GetActiveOut() float64 + func (n *NNode) GetActiveOutTd() float64 + func (n *NNode) IsNeuron() bool + func (n *NNode) IsSensor() bool + func (n *NNode) NodeType() NodeType + func (n *NNode) Print() string + func (n *NNode) SensorLoad(load float64) bool + func (n *NNode) String() string + type Network struct + Id int + Name string + Outputs []*NNode + func NewModularNetwork(in, out, all, control []*NNode, netId int) *Network + func NewNetwork(in, out, all []*NNode, netId int) *Network + func (n *Network) Activate() (bool, error) + func (n *Network) ActivateSteps(maxSteps int) (bool, error) + func (n *Network) AllNodes() []*NNode + func (n *Network) Complexity() int + func (n *Network) FastNetworkSolver() (Solver, error) + func (n *Network) Flush() (res bool, err error) + func (n *Network) ForwardSteps(steps int) (res bool, err error) + func (n *Network) IsRecurrent(inNode, outNode *NNode, count *int, thresh int) bool + func (n *Network) LinkCount() int + func (n *Network) LoadSensors(sensors []float64) error + func (n *Network) MaxDepth() (int, error) + func (n *Network) NodeCount() int + func (n *Network) OutputIsOff() bool + func (n *Network) PrintActivation() string + func (n *Network) PrintInput() string + func (n *Network) ReadOutputs() []float64 + func (n *Network) RecursiveSteps() (bool, error) + func (n *Network) Relax(_ int, _ float64) (bool, error) + type NodeIdGenerator interface + NextNodeId func() int + type NodeNeuronType byte + const BiasNeuron + const HiddenNeuron + const InputNeuron + const OutputNeuron + func NeuronTypeByName(name string) (NodeNeuronType, error) + type NodeType byte + const NeuronNode + const SensorNode + type Solver interface + Flush func() (bool, error) + ForwardSteps func(steps int) (bool, error) + LinkCount func() int + LoadSensors func(inputs []float64) error + NodeCount func() int + ReadOutputs func() []float64 + RecursiveSteps func() (bool, error) + Relax func(maxSteps int, maxAllowedSignalDelta float64) (bool, error)