21 std::vector<uint> bestGenerations_;
22 SelBestOpP selectBest_;
27 bool operate(
const std::vector<IndividualP>&);
40typedef boost::shared_ptr<HallOfFame> HallOfFameP;
Records a set of best-so-far individuals.
std::vector< IndividualP > getBest()
Get HoF contents (vector of best-so-far individuals)
uint hofSize_
no. of individuals in HoF
void read(XMLNode &)
Read operator state from XMLNode or the Registry. Called after Operator::initialize.
void write(XMLNode &)
Write operator state to XMLNode or the Registry. Called after Operator::initialize.
uint getLastChange()
Return generation of last update (of newest individual in HoF)
std::vector< IndividualP > bestIndividuals_
vector of individuals in HoF
uint lastChangeGen_
generation of last update
bool initialize(StateP)
Perform initialization. Called before Operator::operate. By default, if the return value is false,...
bool operate(StateP)
Collect best individuals of the whole Population.