Package-level declarations
Properties
Link copied to clipboard
Name for EvolveScope.store to store target value on previous iteration for comparison
Link copied to clipboard
Name for EvolveScope.store to store steady iteration
Functions
Link copied to clipboard
Base evaluates function for Chromosome by fitnessFunction
Link copied to clipboard
inline suspend fun <V, F> EvolveScope<V, F>.evaluateAll(start: Int, end: Int, parallelismLimit: Int, crossinline fitnessFunction: (V) -> F)
Base evaluates function for all chromosomes in Population by fitnessFunction
Link copied to clipboard
inline fun <V, F, ES : EvolveScope<V, F>> ES.isSteadyGenerations(targetIterationCount: Int, storeNamePrevious: String = STEADY_GENERATIONS, storeNameIteration: String = STEADY_GENERATIONS_CURRENT_ITERATION): Boolean
Check for steady generation with Chromosome.fitness.
Link copied to clipboard
inline fun <V, F, ES : EvolveScope<V, F>> ES.onSteadyGenerations(targetIterationCount: Int, storeNamePrevious: String = STEADY_GENERATIONS, storeNameIteration: String = STEADY_GENERATIONS_CURRENT_ITERATION, onSteadyGenerations: ES.(target: F) -> Unit): Boolean
Check for steady generation with Chromosome.fitness.
inline fun <T : Comparable<T>, V, F, ES : EvolveScope<V, F>> ES.onSteadyGenerations(target: T, targetIterationCount: Int, storeNamePrevious: String = STEADY_GENERATIONS, storeNameIteration: String = STEADY_GENERATIONS_CURRENT_ITERATION, onSteadyGenerations: ES.(target: T) -> Unit): Boolean
inline fun <T, V, F, ES : EvolveScope<V, F>> ES.onSteadyGenerations(target: T, targetIterationCount: Int, storeNamePrevious: String = STEADY_GENERATIONS, storeNameIteration: String = STEADY_GENERATIONS_CURRENT_ITERATION, equalsPredicate: (current: T, previous: T) -> Boolean, onSteadyGenerations: ES.(target: T) -> Unit): Boolean
Check for steady generation with target.
Link copied to clipboard
inline suspend fun <V, F, ES : EvolveScope<V, F>> ES.shakeBy(percent: Double, evaluateNew: Boolean = true, parallelismLimit: Int = parallelismConfig.workersCount, noinline fitnessFunction: (V) -> F = this.fitnessFunction, predicate: ES.() -> Boolean)
Shake percent*100% population with Population.reset function if predicate is true.
inline suspend fun <V, F, ES : EvolveScope<V, F>> ES.shakeBy(from: Int, to: Int, evaluateNew: Boolean = true, parallelismLimit: Int = parallelismConfig.workersCount, noinline fitnessFunction: (V) -> F = this.fitnessFunction, predicate: ES.() -> Boolean)
Shake population with Population.reset function if predicate is true.
Link copied to clipboard
Stop and finish GA if stopCondition return true.
Stop and finish GA if iteration more or equal to maxIteration.
inline fun <V, F> EvolveScope<V, F>.stopBy(maxIteration: Int = Int.MAX_VALUE, stopCondition: EvolveScope<V, F>.() -> Boolean)
Stop and finish GA if: