func (shc *StochasticHillClimber) resetParametersToRandom(cortex *ng.Cortex) {

	neurons := cortex.Neurons
	for _, neuronNode := range neurons {
		for _, cxn := range neuronNode.Inbound {
			cxn.Weights = ng.RandomWeights(len(cxn.Weights))
		}
		neuronNode.Bias = ng.RandomBias()
	}

}
Example #2
0
func RandomBias() float64 {
	return ng.RandomBias()
}