NSGA-II configuration¶
Configure nsgaii through vamos.algorithms.NSGAIIConfig. This page is the parameter reference, not a tutorial about the algorithm.
Stable public API. The 1.x compatibility policy defines the supported surface; import from the public facade shown below.
from vamos.algorithms import NSGAIIConfig
NSGA-II guide and example · Configuration overview · Algorithm contracts · Optimization
NSGAIIConfig
dataclass
¶
Bases: _SerializableConfig
default(pop_size=100, n_var=None, encoding=None)
classmethod
¶
Create a default NSGA-II configuration with sensible defaults.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
pop_size
|
int
|
Population size. |
100
|
n_var
|
int | None
|
Number of variables used for the default mutation probability. |
None
|
encoding
|
str | None
|
Problem encoding. If omitted, defaults to |
None
|
Returns:
| Type | Description |
|---|---|
NSGAIIConfig
|
Frozen configuration ready to use. |
Builder methods¶
Use NSGAIIConfig.builder() to obtain the fluent builder; do not import the private builder class directly. The methods below are generated from that returned object, so their signatures are not maintained as a second manual parameter table.
Bases: _ConfigBuilderState, _PopSizeBuilder, _CrossoverBuilder, _MutationBuilder, _SelectionBuilder, _RepairBuilder, _InitializerBuilder, _MutationProbFactorBuilder, _ResultArchiveBuilder, _ConstraintModeBuilder, _TrackGenealogyBuilder
Fluent builder for NSGA-II configs.
steady_state(enabled=True)
¶
Enable classic one-offspring steady-state NSGA-II.
When enabled, the built configuration resolves offspring_size and
replacement_size to one. Explicit conflicting values fail fast.