|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
GPNodeSelector is a Prototype which describes algorithms which select random nodes out of trees, typically marking them for mutation, crossover, or whatnot. GPNodeSelectors can cache information about a tree, as they may receive the pickNode(...) method more than once on a tree. But this should really only be done if it can be done relatively efficiently; it's not all that common. A GPNodeSelector will be called reset() just before it is pressed into service in selecting nodes from a new tree, which gives it the chance to reset caches, etc.
Method Summary | |
GPNode |
pickNode(EvolutionState s,
int subpopulation,
int thread,
GPIndividual ind,
GPTree tree)
Picks a node at random from tree and returns it. |
void |
reset()
Resets the Node Selector before a new series of pickNode() if need be. |
Methods inherited from interface ec.Prototype |
clone, defaultBase, setup |
Method Detail |
public GPNode pickNode(EvolutionState s, int subpopulation, int thread, GPIndividual ind, GPTree tree)
public void reset()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |