GaSelectRandomBest
selection is randomly selects number of chromosomes and then it cuts off chromosomes with worst fitness values to fit in selection size. This selection use GaSelectRandomBestParams class for parameters.
More...
#include <D:/Temp/vs/gal/source/SelectionOperations.h>
Inherits Population::SelectionOperations::GaSelectRandom.
Public Member Functions | |
virtual GAL_API void GACALL | operator() (const GaPopulation &population, const GaSelectionParams ¶meters, GaSelectionResultSet &result) const |
More details are given in specification of GaSelectionOperation::operator () method. | |
virtual GaParameters *GACALL | MakeParameters () const |
More details are given in specification of GaOperation::MakeParameters method. | |
virtual bool GACALL | CheckParameters (const GaParameters ¶meters) const |
Valid parameters must have selection size grater then 0 and group size greater then or equal to selection size. |
GaSelectRandomBest
selection is randomly selects number of chromosomes and then it cuts off chromosomes with worst fitness values to fit in selection size. This selection use GaSelectRandomBestParams class for parameters.
This class has no built-in synchronizator, so LOCK_OBJECT
and LOCK_THIS_OBJECT
macros cannot be used with instances of this class. Because this genetic operation is stateless all public method are thread-safe.
void Population::SelectionOperations::GaSelectRandomBest::operator() | ( | const GaPopulation & | population, | |
const GaSelectionParams & | parameters, | |||
GaSelectionResultSet & | result | |||
) | const [virtual] |
More details are given in specification of GaSelectionOperation::operator () method.
This method is thread-safe.
Reimplemented from Population::SelectionOperations::GaSelectRandom.
virtual GaParameters* GACALL Population::SelectionOperations::GaSelectRandomBest::MakeParameters | ( | ) | const [inline, virtual] |
More details are given in specification of GaOperation::MakeParameters method.
This method is thread-safe.
Reimplemented from Population::SelectionOperations::GaSelectRandom.
virtual bool GACALL Population::SelectionOperations::GaSelectRandomBest::CheckParameters | ( | const GaParameters & | parameters | ) | const [inline, virtual] |
Valid parameters must have selection size grater then 0 and group size greater then or equal to selection size.
More details are given in specification of GaOperation::CheckParameters method.
This method is thread-safe.
Reimplemented from Population::SelectionOperations::GaSelectRandom.