Skip to main content

CmaEsFitness

Trait CmaEsFitness 

Source
pub trait CmaEsFitness: Send + Sync {
    // Required method
    fn evaluate(&self, x: &RealVector) -> f64;
}
Expand description

Trait for fitness functions used with CMA-ES

CMA-ES is a minimization algorithm, so lower values are better.

Required Methods§

Source

fn evaluate(&self, x: &RealVector) -> f64

Evaluate the fitness of a solution (lower is better)

Implementors§

Source§

impl<F> CmaEsFitness for F
where F: Fn(&RealVector) -> f64 + Send + Sync,

Available on crate feature parallel only.

Implement CmaEsFitness for any Fn that matches the signature