- added the #define for eo_verbose (true) and eo_no_verbose (false)
- added the eoNormMutation, simple normal mutation for simple real variables Modified Files: src/eo src/es/eoRealOp.h tutorial/Lesson2/FirstRealEA.cpp tutorial/Lesson3/SecondBitEA.cpp
This commit is contained in:
parent
0e62de2d14
commit
4944881d7c
4 changed files with 57 additions and 6 deletions
|
|
@ -235,7 +235,7 @@ void main_function(int argc, char **argv)
|
|||
// Combine them with relative rates
|
||||
eoPropCombinedQuadOp<Indi> xover(xover1, onePointRate);
|
||||
xover.add(xoverU, URate);
|
||||
xover.add(xover2, twoPointsRate, true);
|
||||
xover.add(xover2, twoPointsRate, eo_verbose);
|
||||
|
||||
// MUTATION
|
||||
// standard bit-flip mutation for bitstring
|
||||
|
|
@ -244,7 +244,7 @@ void main_function(int argc, char **argv)
|
|||
eoDetBitFlip<Indi> mutationOneBit;
|
||||
// Combine them with relative rates
|
||||
eoPropCombinedMonOp<Indi> mutation(mutationBitFlip, bitFlipRate);
|
||||
mutation.add(mutationOneBit, oneBitRate, true);
|
||||
mutation.add(mutationOneBit, oneBitRate, eo_verbose);
|
||||
|
||||
// The operators are encapsulated into an eoTRansform object
|
||||
eoSGATransform<Indi> transform(xover, pCross, mutation, pMut);
|
||||
|
|
@ -294,7 +294,7 @@ void main_function(int argc, char **argv)
|
|||
checkpoint.add(SecondStat);
|
||||
|
||||
// The Stdout monitor will print parameters to the screen ...
|
||||
eoStdoutMonitor monitor(false);
|
||||
eoStdoutMonitor monitor(eo_no_verbose);
|
||||
|
||||
// when called by the checkpoint (i.e. at every generation)
|
||||
checkpoint.add(monitor);
|
||||
|
|
|
|||
Reference in a new issue