module documentation

Fitness surrogate model classes and handler for incremental evaluations.

Class LQModel Up to a full quadratic model using the pseudo inverse to compute the model coefficients.
Class LQModelSettings Undocumented
Class ModelInjectionCallback inject model.xopt and decrease sigma if mean is close to model.xopt.
Class ModelInjectionCallbackSettings Undocumented
Class SurrogatePopulation surrogate f-values for a population.
Class SurrogatePopulationSettings Undocumented
Class Tau placeholder to store Kendall tau related things
Function kendall_tau return rank correlation coefficient between data x and y
Variable ___author__ Undocumented
Variable __license__ Undocumented
Function _kendall_tau return Kendall tau rank correlation coefficient.
Function _n_for_model_building_default truncate worst solutions for model building
Function _sorted_index_default Undocumented
def kendall_tau(x, y):

return rank correlation coefficient between data x and y

___author__: str =

Undocumented

__license__: str =

Undocumented

def _kendall_tau(x, y):

return Kendall tau rank correlation coefficient.

Implemented only to potentially remove dependency on scipy.stats.

This

>>> import numpy as np
>>> from cma.fitness_models import _kendall_tau
>>> kendalltau = lambda x, y: (_kendall_tau(x, y), 0)
>>> # from scipy.stats import kendalltau  # incomment if not available
>>> for dim in np.random.randint(3, 22, 5):
...     x, y = np.random.randn(dim), np.random.randn(dim)
...     t1, t2 = _kendall_tau(x, y), kendalltau(x, y)[0]
...     # print(t1, t2)
...     assert np.isclose(t1, t2)
def _n_for_model_building_default(m):

truncate worst solutions for model building

def _sorted_index_default(m):

Undocumented