saealib.SerialEvaluator#

class saealib.SerialEvaluator[ソース]#

ベースクラス: Evaluator

Default evaluator: evaluates each candidate sequentially.

Methods

__init__

acknowledge

Acknowledge one contiguous update sequence.

can_reattach

Return whether pending work can be restored after checkpoint load.

cancel

Cancel submitted work when the backend supports cancellation.

collect

Return unacknowledged updates for a handle.

contract

Return the evaluator family contract.

detach

Detach work whose result must no longer be delivered.

evaluate_batch

Evaluate a batch, using the problem's optional evaluation adapter.

evaluate_request

Evaluate a request while exposing its context to the adapter.

has_partial_lifecycle_override

Return whether lifecycle adapter methods are only partly overridden.

reattach

Restore a pending request or raise when unsupported.

submit

Submit a request through the synchronous adapter.

supports_batch_rollback

Return whether failed batch submission can be rolled back.

Method Details

SerialEvaluator.__init__()#
SerialEvaluator.acknowledge(handle, sequence)#

Acknowledge one contiguous update sequence.

パラメータ:
戻り値の型:

None

SerialEvaluator.can_reattach(pending)#

Return whether pending work can be restored after checkpoint load.

パラメータ:

pending (PendingEvaluation)

戻り値の型:

bool

SerialEvaluator.cancel(handle)#

Cancel submitted work when the backend supports cancellation.

パラメータ:

handle (EvaluationHandle)

戻り値の型:

bool

SerialEvaluator.collect(handle, *, wait=True)#

Return unacknowledged updates for a handle.

パラメータ:
戻り値の型:

list[EvaluationUpdate]

SerialEvaluator.contract()#

Return the evaluator family contract.

戻り値の型:

ComponentContract

SerialEvaluator.detach(handle)#

Detach work whose result must no longer be delivered.

パラメータ:

handle (EvaluationHandle)

戻り値の型:

bool

SerialEvaluator.evaluate_batch(x, problem)[ソース]#

Evaluate a batch, using the problem's optional evaluation adapter.

パラメータ:
  • x (GenomeBatch | np.ndarray)

  • problem (Problem)

戻り値の型:

EvaluationResult

SerialEvaluator.evaluate_request(request, problem)[ソース]#

Evaluate a request while exposing its context to the adapter.

パラメータ:
戻り値の型:

EvaluationResult

classmethod SerialEvaluator.has_partial_lifecycle_override()#

Return whether lifecycle adapter methods are only partly overridden.

戻り値の型:

bool

SerialEvaluator.reattach(pending, problem)#

Restore a pending request or raise when unsupported.

パラメータ:
戻り値の型:

EvaluationHandle

SerialEvaluator.submit(request, problem)#

Submit a request through the synchronous adapter.

パラメータ:
戻り値の型:

EvaluationHandle

SerialEvaluator.supports_batch_rollback()#

Return whether failed batch submission can be rolled back.

戻り値の型:

bool