|
| | CMAParameters (const int &dim, const double *x0, const double &sigma, const int &lambda=-1, const uint64_t &seed=0, const TGenoPheno &gp=TGenoPheno()) |
| | Constructor. More...
|
| |
| | CMAParameters (const std::vector< double > &x0, const double &sigma, const int &lambda=-1, const uint64_t &seed=0, const TGenoPheno &gp=TGenoPheno()) |
| | Constructor. More...
|
| |
| | CMAParameters (const std::vector< double > &x0, const std::vector< double > &sigma, const int &lambda=-1, const std::vector< double > &lbounds=std::vector< double >(), const std::vector< double > &ubounds=std::vector< double >(), const uint64_t &seed=0) |
| | Constructor. More...
|
| |
|
void | initialize_parameters () |
| | initialize required parameters based on dim, lambda, x0 and sigma.
|
| |
|
void | reset_as_fixed (const int &k) |
| |
|
void | set_noisy () |
| | adapt parameters for noisy objective function.
|
| |
| void | set_algo (const int &algo) |
| | sets the optimization algorithm. Note: overrides Parameters::set_algo More...
|
| |
| void | set_str_algo (const std::string &algo) |
| | sets the optimization algorithm. More...
|
| |
| double | get_sigma_init () const |
| | returns initial sigma value More...
|
| |
| void | set_gradient (const bool &gradient) |
| | activates the gradient injection scheme. If no gradient function is defined, injects a numerical gradient solution instead Note: overrides Parameters::set_gradient More...
|
| |
|
void | set_sep () |
| | fix parameters for sep-CMA-ES, using only the diagonal of covariance matrix.
|
| |
| bool | is_sep () const |
| | whether algorithm leverages separability. More...
|
| |
|
void | set_vd () |
| | activates VD decomposition.
|
| |
| bool | is_vd () const |
| | whether algorithm uses vd update. More...
|
| |
| void | set_fixed_p (const int &index, const double &value) |
| | freezes a parameter to a given value in genotype during optimization. Adapts some generic parameters as well. More...
|
| |
| void | unset_fixed_p (const int &index) |
| | unfreezes a parameter. More...
|
| |
| void | set_restarts (const int &nrestarts) |
| | sets the maximum number of restarts (applies to IPOP and BIPOP). More...
|
| |
| int | get_restarts () const |
| | get the number of restarts (applies to IPOP and BIPOP). More...
|
| |
| void | set_lazy_update (const bool &lz) |
| | sets the lazy update (i.e. updates the eigenvalues every few steps). More...
|
| |
| bool | get_lazy_update () |
| | get lazy update status. More...
|
| |
|
void | set_elitism (const int &e) |
| | sets elitism: 0 -> no elitism 1 -> elitism: reinjects the best-ever seen solution 2 -> initial elitism: reinject x0 as long as it is not improved upon 3 -> initial elitism on restart: restart if best encountered solution is not the the final solution and reinjects the best solution until the population has better fitness, in its majority
|
| |
| void | set_stopping_criteria (const int &criteria, const bool &active) |
| | all stopping criteria are active by default, this allows to control them More...
|
| |
| void | set_tpa (const int &b) |
| | activates / deactivates two-point adaptation step-size mechanism. Overrides parameters::set_tpa by automatically setting dsigma value. More...
|
| |
| void | set_tpa_dsigma (const double &d) |
| | sets dsigma value, use with care. More...
|
| |
|
| Parameters () |
| | empty constructor.
|
| |
| | Parameters (const int &dim, const double *x0, const int &lambda=-1, const uint64_t &seed=0, const TGenoPheno &gp=GenoPheno< NoBoundStrategy >()) |
| | constructor More...
|
| |
| void | set_x0 (const double &x0) |
| | sets initial objective function parameter values to x0 across all dimensions More...
|
| |
| void | set_x0 (const double *x0) |
| | sets initial objective function parameter values to array x0 More...
|
| |
| void | set_x0 (const dVec &x0) |
| | sets initial objective function parameter values from Eigen vector More...
|
| |
| void | set_x0 (const double &x0min, const double &x0max) |
| | sets bounds on initial objective function parameter values. Bounds are the same across all dimensions, and initial value is sampled uniformly within these bounds. More...
|
| |
| void | set_x0 (const double *x0min, const double *x0max) |
| | sets bounds on initial objective function parameter values. Initial value is sampled uniformly within these bounds. More...
|
| |
| void | set_x0 (const std::vector< double > &x0min, const std::vector< double > &x0max) |
| | sets bounds on initial objective function parameter values. Initial value is sampled uniformly within these bounds. More...
|
| |
| void | set_x0 (const dVec &x0min, const dVec &x0max) |
| | sets bounds on initial objective function parameter values. Initial value is sampled uniformly within these bounds. More...
|
| |
| dVec | get_x0min () const |
| | returns lower bound on x0 vector More...
|
| |
| dVec | get_x0max () const |
| | returns upper bound on x0 vector More...
|
| |
| void | set_fixed_p (const int &index, const double &value) |
| | freezes a parameter to a given value during optimization. More...
|
| |
| void | unset_fixed_p (const int &index) |
| | unfreezes a parameter. More...
|
| |
| void | set_max_iter (const int &maxiter) |
| | sets the maximum number of iterations allowed for the optimization. More...
|
| |
| int | get_max_iter () const |
| | returns maximum number of iterations More...
|
| |
| void | set_max_fevals (const int &fevals) |
| | sets the maximum budget of objective function calls allowed for the optimization. More...
|
| |
| int | get_max_fevals () const |
| | returns maximum budget of objective function calls More...
|
| |
| void | set_ftarget (const double &val) |
| | sets the objective function target value when known. More...
|
| |
|
void | reset_ftarget () |
| | resets the objective function target value to its inactive state.
|
| |
| double | get_ftarget () const |
| | returns objective function target value. More...
|
| |
| void | set_seed (const int &seed) |
| | sets random generator's seed, 0 is special value to generate random seed. More...
|
| |
| int | get_seed () const |
| | returns random generator's seed. More...
|
| |
| void | set_ftolerance (const double &v) |
| | sets function tolerance as stopping criteria for TolHistFun: monitors the difference in function value over iterations and stops optimization when below tolerance. More...
|
| |
| double | get_ftolerance () const |
| | returns function tolerance More...
|
| |
| void | set_xtolerance (const double &v) |
| | sets parameter tolerance as stopping criteria for TolX. More...
|
| |
| double | get_xtolerance () const |
| | returns parameter tolerance More...
|
| |
| int | lambda () const |
| | returns lambda, number of offsprings per generation More...
|
| |
| int | dim () const |
| | returns the problem's dimension More...
|
| |
| void | set_quiet (const bool &quiet) |
| | sets the quiet mode (no output from the library) for the optimization at hand More...
|
| |
| bool | quiet () const |
| | returns whether the quiet mode is on. More...
|
| |
| void | set_algo (const int &algo) |
| | sets the optimization algorithm. More...
|
| |
| int | get_algo () const |
| | returns which algorithm is set for the optimization at hand. More...
|
| |
| void | set_gp (const TGenoPheno &gp) |
| | sets the genotype/phenotype transform object. More...
|
| |
| TGenoPheno | get_gp () const |
| | returns the current genotype/phenotype transform object. More...
|
| |
| void | set_fplot (const std::string &fplot) |
| | sets the output filename (activates the output to file). More...
|
| |
| void | set_full_fplot (const bool &b) |
| | activates / deactivates the full output (for legacy plotting). More...
|
| |
| std::string | get_fplot () const |
| | returns the current output filename. More...
|
| |
| void | set_gradient (const bool &gradient) |
| | activates the gradient injection scheme. If no gradient function is defined, injects a numerical gradient solution instead More...
|
| |
| bool | get_gradient () const |
| | returns whether the gradient injection scheme is activated. More...
|
| |
| void | set_edm (const bool &edm) |
| | activates computation of expected distance to minimum when optimization has completed More...
|
| |
| bool | get_edm () const |
| | returns whether edm is activated. More...
|
| |
| void | set_mt_feval (const bool &mt) |
| | activate / deactivate the parallel evaluation of objective function More...
|
| |
| bool | get_mt_feval () const |
| | returns whether the parallel evaluation of objective function is activated More...
|
| |
| void | set_max_hist (const int &m) |
| | sets maximum history size, allows to keep memory requirements fixed. More...
|
| |
| void | set_maximize (const bool &maximize) |
| | active internal maximization scheme (simply returns -f instead of f) More...
|
| |
| bool | get_maximize () const |
| | returns whether the maximization mode is enabled More...
|
| |
| void | set_initial_fvalue (const bool &b) |
| | whether to compute initial objective function value (i.e. at x0) More...
|
| |
| void | set_uh (const bool &b) |
| | activates / deactivates uncertainty handling scheme. More...
|
| |
| bool | get_uh () const |
| | get uncertainty handling status. More...
|
| |
| void | set_tpa (const int &b) |
| | activates / deactivates two-point adaptation step-size mechanism More...
|
| |
| int | get_tpa () const |
| | get two-point adapation step-size mechanism status. More...
|
| |
template<class TGenoPheno = GenoPheno<NoBoundStrategy>>
class libcmaes::CMAParameters< TGenoPheno >
Parameters for various flavors of the CMA-ES algorithm.