org.encog.neural.neat.training.opp
public class NEATCrossover extends Object implements EvolutionaryOperator
Constructor and Description |
---|
NEATCrossover() |
Modifier and Type | Method and Description |
---|---|
void |
addNeuronID(long nodeID,
List<NEATNeuronGene> vec,
NEATGenome best,
NEATGenome notBest)
Add a neuron.
|
void |
init(EvolutionaryAlgorithm theOwner)
Init this operator.
|
int |
offspringProduced() |
int |
parentsNeeded() |
void |
performOperation(Random rnd,
Genome[] parents,
int parentIndex,
Genome[] offspring,
int offspringIndex)
Perform the evolutionary operation.
|
public void addNeuronID(long nodeID, List<NEATNeuronGene> vec, NEATGenome best, NEATGenome notBest)
nodeID
- The neuron id.vec
- THe list of id's used.public void init(EvolutionaryAlgorithm theOwner)
init
in interface EvolutionaryOperator
theOwner
- The evolutionary algorithm used with this operator.public int offspringProduced()
offspringProduced
in interface EvolutionaryOperator
public int parentsNeeded()
parentsNeeded
in interface EvolutionaryOperator
public void performOperation(Random rnd, Genome[] parents, int parentIndex, Genome[] offspring, int offspringIndex)
performOperation
in interface EvolutionaryOperator
rnd
- A random number generator.parents
- The parents.parentIndex
- The index into the parents array.offspring
- The offspring.offspringIndex
- An index into the offspring array.Copyright © 2014. All Rights Reserved.