MCPcopy Create free account
hub / github.com/andrinr/evo / EvolutionEngine

Class EvolutionEngine

src/simulation/evolution.rs:17–28  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

15/// Manages the graveyard and organism spawning/evolution.
16#[derive(Debug, Clone)]
17pub struct EvolutionEngine {
18 /// Graveyard of deceased organisms for breeding selection.
19 /// Maintained sorted by fitness (highest first).
20 graveyard: Vec<Organism>,
21 /// Maximum size of the graveyard.
22 max_graveyard_size: usize,
23 /// Elite pool - top scoring organisms preserved across all time.
24 /// These are the best organisms ever seen and are kept for breeding.
25 elite_pool: Vec<Organism>,
26 /// Maximum size of the elite pool.
27 max_elite_pool_size: usize,
28}
29
30/// Source of organisms for breeding.
31#[derive(Debug, Clone, Copy)]

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected