A generic stochastic search template for algorithms that need a distribution parameter. More...
#include <edoAlgoAdaptive.h>
Public Types | |
typedef D::EOType | EOType |
Alias for the type EOT. | |
typedef EOType::AtomType | AtomType |
Alias for the atom type. | |
typedef EOType::Fitness | Fitness |
Alias for the fitness. | |
Public Member Functions | |
edoAlgoAdaptive (D &distrib, eoPopEvalFunc< EOType > &evaluator, eoSelect< EOType > &selector, edoEstimator< D > &estimator, edoSampler< D > &sampler, eoReplacement< EOType > &replacor, eoContinue< EOType > &pop_continuator, edoContinue< D > &distribution_continuator) | |
edoAlgoAdaptive (D &distrib, eoPopEvalFunc< EOType > &evaluator, eoSelect< EOType > &selector, edoEstimator< D > &estimator, edoSampler< D > &sampler, eoReplacement< EOType > &replacor, eoContinue< EOType > &pop_continuator) | |
constructor without an edoContinue | |
void | operator() (eoPop< EOType > &pop) |
Call the algorithm. | |
Protected Attributes | |
D & | _distrib |
The distribution that you want to update. | |
eoPopEvalFunc< EOType > & | _evaluator |
A full evaluation function. | |
eoSelect< EOType > & | _selector |
A EOType selector. | |
edoEstimator< D > & | _estimator |
A EOType estimator. It is going to estimate distribution parameters. | |
edoSampler< D > & | _sampler |
A D sampler. | |
eoReplacement< EOType > & | _replacor |
A EOType replacor. | |
eoContinue< EOType > & | _pop_continuator |
A EOType population continuator. | |
edoDummyContinue< D > | _dummy_continue |
A D continuator that always return true. | |
edoContinue< D > & | _distribution_continuator |
A D continuator. |
A generic stochastic search template for algorithms that need a distribution parameter.
An adaptive algorithm will directly updates a distribution, it must thus be instanciated with an edoDistrib at hand. Thus, this distribution object should be instanciated appart. The reference to this distribution is generally also needed by at least one of the algorithm's operator, generally for algorithms that shares the same algorithms across operators and/or iterations.
If you no operator needs to update the distribution, then it is simpler to use an edoAlgoStateless .
Definition at line 55 of file edoAlgoAdaptive.h.
edoAlgoAdaptive< D >::edoAlgoAdaptive | ( | D & | distrib, |
eoPopEvalFunc< EOType > & | evaluator, | ||
eoSelect< EOType > & | selector, | ||
edoEstimator< D > & | estimator, | ||
edoSampler< D > & | sampler, | ||
eoReplacement< EOType > & | replacor, | ||
eoContinue< EOType > & | pop_continuator, | ||
edoContinue< D > & | distribution_continuator | ||
) | [inline] |
Takes algo operators, all are mandatory
distrib | A distribution to use, if you want to update this parameter (e.gMA-ES) instead of replacing it (e.g. an EDA) |
evaluator | Evaluate a population |
selector | Selection of the best candidate solutions in the population |
estimator | Estimation of the distribution parameters |
sampler | Generate feasible solutions using the distribution |
replacor | Replace old solutions by new ones |
pop_continuator | Stopping criterion based on the population features |
distribution_continuator | Stopping criterion based on the distribution features |
Definition at line 81 of file edoAlgoAdaptive.h.
edoAlgoAdaptive< D >::edoAlgoAdaptive | ( | D & | distrib, |
eoPopEvalFunc< EOType > & | evaluator, | ||
eoSelect< EOType > & | selector, | ||
edoEstimator< D > & | estimator, | ||
edoSampler< D > & | sampler, | ||
eoReplacement< EOType > & | replacor, | ||
eoContinue< EOType > & | pop_continuator | ||
) | [inline] |
constructor without an edoContinue
Takes algo operators, all are mandatory
distrib | A distribution to use, if you want to update this parameter (e.gMA-ES) instead of replacing it (e.g. an EDA) |
evaluator | Evaluate a population |
selector | Selection of the best candidate solutions in the population |
estimator | Estimation of the distribution parameters |
sampler | Generate feasible solutions using the distribution |
replacor | Replace old solutions by new ones |
pop_continuator | Stopping criterion based on the population features |
Definition at line 115 of file edoAlgoAdaptive.h.
void edoAlgoAdaptive< D >::operator() | ( | eoPop< EOType > & | pop | ) | [inline] |
Call the algorithm.
pop | the population of candidate solutions |
Definition at line 140 of file edoAlgoAdaptive.h.
References edoAlgoAdaptive< D >::_distrib, edoAlgoAdaptive< D >::_distribution_continuator, edoAlgoAdaptive< D >::_estimator, edoAlgoAdaptive< D >::_evaluator, edoAlgoAdaptive< D >::_pop_continuator, edoAlgoAdaptive< D >::_replacor, edoAlgoAdaptive< D >::_sampler, and edoAlgoAdaptive< D >::_selector.