Skip to content

CMOEA-MS configuration

Configure cmoeams through vamos.algorithms.CMOEAMSConfig. This page is the parameter reference, not a tutorial about the algorithm; see CMOEA-MS for the algorithm, its two stages, its variations and its budget rule.

New in VAMOS 1.2.0. The 1.0 compatibility baseline does not cover CMOEA-MS and CMOEAMSConfig yet.

from vamos.algorithms import CMOEAMSConfig

Configuration overview · Algorithm contracts · Optimization

CMOEAMSConfig dataclass

Bases: _SerializableConfig

Configuration of CMOEA-MS (Tian et al., 2022).

pop_size is the size of the population, at least 2. The crossover selects the variation: ("de", {"cr": ..., "f": ...}) the DE variation (real variables only), whose crossover is de_variant, "rand_1_bin" (binomial, PlatEMO's) or "rand_1_exp" (exponential); any crossover with two parents and two children the GA variation, which keeps both children. feasible_ratio_threshold is the paper's lambda: the fitness is that of stage B when the ratio of feasible solutions of the union of the population and the offspring is greater than it, and at least 10% of the evaluations have been done.

default(pop_size=None, n_var=None, encoding=None) classmethod

Create the default CMOEA-MS configuration: that of the paper, of PlatEMO's implementation and of jMetal's port.

pop_size=None means 100. Real variables use the GA variation with SBX (probability 1.0, distribution index 20) and polynomial mutation (probability 1/n, distribution index 20), and feasible_ratio_threshold (lambda) is 0.5. Discrete and mixed encoding values take their crossover and mutation from the shared encoding table.

Builder methods

Use CMOEAMSConfig.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, _RepairBuilder, _InitializerBuilder, _ConstraintModeBuilder, _ResultArchiveBuilder

Fluent builder for CMOEA-MS configs.

Examples: cfg = CMOEAMSConfig.default(n_var=10) cfg = CMOEAMSConfig.builder().pop_size(100).crossover("sbx", prob=1.0, eta=20.0).mutation("pm", prob="1/n", eta=20.0).build() cfg = CMOEAMSConfig.builder().pop_size(100).crossover("de", cr=1.0, f=0.5).de_variant("rand_1_exp").mutation("pm").build()

de_variant(value)

The crossover of the DE variation: "rand_1_bin" (binomial, the default) or "rand_1_exp" (exponential).

feasible_ratio_threshold(value)

The paper's lambda: stage B needs a ratio of feasible solutions greater than this value; 0.5 by default.