saealib.TellStage#
- class saealib.TellStage(algorithm, *, channel='true')[source]#
Bases:
StageUpdate the population via the algorithm’s tell() method.
Reads
state.offspring(the full candidate population, including both surrogate-scored and true-evaluated individuals, as the algorithm expects) and callsalgorithm.tell().- Parameters:
algorithm (Algorithm) – The evolutionary algorithm that updates the population.
channel (FeedbackChannel)
Methods
Initialize base Stage attributes. |
|
Return this stage's structural and direct state-access contract. |
|
Execute this stage and return the updated state. |
|
Expand into per-step lines via |
|
Render this stage as a plain-text algorithmic line. |
Method Details
- TellStage.__init__(algorithm, *, channel='true')[source]#
Initialize base Stage attributes.
- Parameters:
name (str, optional) – Override the class-level
name.label (str, optional) – Override the class-level
label.notation (str, optional) – Override the class-level
notation.algorithm (Algorithm | Proposer | FeedbackConsumer)
channel (FeedbackChannel)
- Return type:
None
- TellStage.contract()[source]#
Return this stage’s structural and direct state-access contract.
- Return type:
- TellStage.execute(state)[source]#
Execute this stage and return the updated state.
- Parameters:
state (OptimizationState) – Current optimization state.
- Returns:
Updated state.
- Return type:
OptimizationState
- TellStage.to_pseudocode(*, expand=False, indent=0)[source]#
Expand into per-step lines via
Algorithm.tell_notation.- Parameters:
expand (bool)
indent (int)
- Return type:
str
- TellStage.to_text(*, expand=False, indent=0)#
Render this stage as a plain-text algorithmic line.
- Parameters:
expand (bool)
indent (int)
- Return type:
str