|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.epochx.core.GPInitialisation<TYPE>
public class GPInitialisation<TYPE>
This class is responsible for controlling the initialisation operation. Note
that as with the other core classes, no actual (initialisation) operation is
performed by this class. Rather, it provides the infrastructure around the
operation, and calls the implementation of Initialiser which
will perform the actual operation.
Initialiser,
FullInitialiser,
RampedHalfAndHalfInitialiser| Constructor Summary | |
|---|---|
GPInitialisation(GPModel<TYPE> model)
Constructs an instance of GEInitialisation which will setup the initialisation operation. |
|
| Method Summary | |
|---|---|
int |
getReversions()
Number of times the initial population was rejected and regenerated. |
java.util.List<CandidateProgram<TYPE>> |
initialise()
Initialises a new population of CandidatePrograms by
calling getInitialPopulation() on the initialiser provided
by the model. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public GPInitialisation(GPModel<TYPE> model)
Initialiser returned
by the models getInitialiser() method.
model - the GPModel which defines the Initialiser operator and
life cycle listener.Initialiser| Method Detail |
|---|
public java.util.List<CandidateProgram<TYPE>> initialise()
CandidatePrograms by
calling getInitialPopulation() on the initialiser provided
by the model.
After an initial population is constructed, the model's life cycle
listener is given an opportunity to confirm or modify it before
proceeding. The listener's onInitialisation() method is
called, passing it the newly formed population. If this method returns
null then the initialisation operation will be repeated, otherwise the
population returned by the life cycle listener will be used as the
initial population. The number of times the initial population is
rejected and thus regenerated is available with a call to
getReversions().
public int getReversions()
After an initial population is constructed, the model's life cycle
listener is given an opportunity to confirm or modify it before
proceeding. The listener's onInitialisation() method is
called, passing it the newly formed population. If this method returns
null then the initialisation operation will be repeated, otherwise the
population returned by the life cycle listener will be used as the
initial population. The number of times the initial population is
rejected and thus regenerated is available with a call to this method.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||