pub struct CmsaEsConfig {
pub pop_size: usize,
pub genome_dim: usize,
pub bounds: Bounds,
pub initial_sigma: f32,
pub mu: usize,
pub tau: f32,
pub tau_c: f32,
}Expand description
Static configuration for a CMSA-ES run.
Fields§
§pop_size: usizeOffspring population size λ.
genome_dim: usizeGenome dimensionality D.
bounds: BoundsSearch-space bounds; used only to sample the initial mean m⁰.
initial_sigma: f32Initial global step size σ̄.
mu: usizeNumber of selected parents μ = ⌊λ/2⌋.
tau: f32Log-normal σ-self-adaptation learning rate τ = 1/√(2D).
tau_c: f32Covariance time constant τ_c = 1 + D(D+1)/(2μ).
Implementations§
Source§impl CmsaEsConfig
impl CmsaEsConfig
Sourcepub fn default_for(genome_dim: usize) -> Self
pub fn default_for(genome_dim: usize) -> Self
Default configuration for dimensionality D, with the Hansen-style
population λ = 4 + ⌊3 ln D⌋ and μ = ⌊λ/2⌋.
Sets bounds = (-5.12, 5.12) and initial_sigma = 1.0.
Sourcepub fn with_pop_size(pop_size: usize, genome_dim: usize) -> Self
pub fn with_pop_size(pop_size: usize, genome_dim: usize) -> Self
Configuration with an explicit population size λ.
The pop_size ≥ 2 invariant is enforced by Validate::validate at the
harness chokepoint, not by this infallible producer.
Trait Implementations§
Source§impl Clone for CmsaEsConfig
impl Clone for CmsaEsConfig
Source§fn clone(&self) -> CmsaEsConfig
fn clone(&self) -> CmsaEsConfig
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for CmsaEsConfig
impl Debug for CmsaEsConfig
Source§impl Validate for CmsaEsConfig
impl Validate for CmsaEsConfig
Source§fn validate_all(&self) -> Result<(), Vec<ConfigError>>
fn validate_all(&self) -> Result<(), Vec<ConfigError>>
Returns every violated invariant rather than just the first. Read more
Auto Trait Implementations§
impl Freeze for CmsaEsConfig
impl RefUnwindSafe for CmsaEsConfig
impl Send for CmsaEsConfig
impl Sync for CmsaEsConfig
impl Unpin for CmsaEsConfig
impl UnsafeUnpin for CmsaEsConfig
impl UnwindSafe for CmsaEsConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<C> CloneExpand for Cwhere
C: Clone,
impl<C> CloneExpand for Cwhere
C: Clone,
fn __expand_clone_method(&self, _scope: &mut Scope) -> C
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more