QDpy
Loading...
Searching...
No Matches
qdpy.algorithms.boil.BOIL Class Reference

Alternate model building, focused illumination, and search for a chosen descriptor. More...

Inheritance diagram for qdpy.algorithms.boil.BOIL:
qdpy.algorithms.bayesian.BOPElites qdpy.algorithms.modern._FixedGeneration qdpy.algorithms.base.QDAlgorithm qdpy.algorithms.base.QDAlgorithmLike qdpy.base.Summarisable qdpy.base.Saveable qdpy.base.Copyable qdpy.base.CreatableFromConfig

Public Member Functions

 reinit (self)
 remaining_evaluations (self)
 focus (self, cells=None)
 Restrict the illumination phase to grid cells selected from the preview.
 set_target (self, descriptor, *, distance_weight=1.)
 Search for measured solutions with a chosen target descriptor.
 best_target (self)
 Find the strongest measured target utility, including measurements rejected by the grid.
 prediction_map (self, *, samples=512, min_probability=.5, seed=0)
 Build a model-only prediction map without spending evaluations or advancing the search.
 optimise (self, evaluate, budget=None, **kwargs)
 Spend a phase budget within the lifetime evaluation limit.
Public Member Functions inherited from qdpy.algorithms.bayesian.BOPElites
 n_observations (self)
 n_invalid_observations (self)
 tell (self, individual, fitness=None, features=None, scores=None, elapsed=None, verbose=False, tell_container=True)
Public Member Functions inherited from qdpy.algorithms.modern._FixedGeneration
 current_iter (self)
 ask (self)
 ask_batch (self, size=None)
 Issue one manual generation in proposal order.
 tell_batch (self, results)
 Apply results from the outstanding manual generation.
Public Member Functions inherited from qdpy.algorithms.base.QDAlgorithm
Union[str, Sequence[float]] optimisation_task (self)
None optimisation_task (self, Union[str, Sequence[float]] optimisation_task)
int nb_suggestions (self)
int nb_suggestions_in_iteration (self)
int nb_evaluations (self)
int nb_evaluations_in_iteration (self)
int nb_updated (self)
int nb_updated_in_iteration (self)
int batch_size (self)
Union[int, float] nb_max_iter (self)
None tell_container_entries (self, Optional[Container] cont=None)
IndividualLike best (self)
None add_callback (self, str event, Callable fn)
Public Member Functions inherited from qdpy.base.Summarisable
Mapping[str, Any] __get_summary_state__ (self)
str summary (self, Optional[int] max_depth=None, Optional[int] max_entry_length=250)
Public Member Functions inherited from qdpy.base.Saveable
Mapping[str, Any] __get_saved_state__ (self)
None save (self, str output_path, str output_type="pickle")
Public Member Functions inherited from qdpy.base.CreatableFromConfig
Any from_config (cls, Mapping[str, Any] config, **Any kwargs)

Protected Member Functions

 _start_fixed_batch (self, size)
Protected Member Functions inherited from qdpy.algorithms.bayesian.BOPElites
 _internal_ask (self, base_ind)
 _commit_generation (self, evaluated)
Protected Member Functions inherited from qdpy.algorithms.modern._FixedGeneration
 _offer_to_grid (self, individual, cell)
 _receive_fixed_batch (self, records, verbose, batch_start_time)
Protected Member Functions inherited from qdpy.algorithms.base.QDAlgorithm
 _check_archive_weights (self)
None _attach_evaluation (self, ind, fitness, features, scores, elapsed)
Tuple[MutableMapping[str, Any], bool] _tell_before_container_update (self, IndividualLike individual)
 Read pre-admission state for optimiser feedback.
None _tell_after_container_update (self, IndividualLike individual, bool added, Mapping[str, Any] xattr={})
 Account for a completed tell and send feedback.
None _internal_tell (self, IndividualLike individual, bool added_to_container, Mapping[str, Any] xattr={})
IndividualLike _internal_best (self)
bool _verify_if_finished_iteration (self, float batch_start_time)
None _transfer_suggestion (self, IndividualLike individual, IndividualLike evaluated)
 Transfer coordinator-side metadata when evaluation returns a new object.
 _fixed_batch_plan (self, size, evaluate, packed)

Detailed Description

Alternate model building, focused illumination, and search for a chosen descriptor.

Bayesian Optimization with Interactive Illumination (Kent and Branke, 2023).

Reuse the measured design and descriptor posteriors across all three
phases. Use a fixed one- or two-dimensional rectangular reporting grid.
Model building multiplies expected joint improvement by one plus the
normalized entropy of posterior region membership. Focused
illumination considers only selected cells. Target search uses common
Monte Carlo draws to estimate the expected improvement in target utility.

:param container: Best-only Grid with one objective and one or two descriptors.
:param budget: Total measurement attempts across repeated optimise calls and manual batches.
:param dimension: Length of a real-valued genome.
:param ind_domain: Common lower and upper decision bounds.
:param quality_floor: Empty-cell threshold in weighted fitness units.
:param entropy_weight: Nonnegative multiplier on normalized descriptor entropy.
:param target_samples: Power-of-two count of fixed, scrambled Sobol posterior draws.
:param kwargs: Native optimizer arguments and BOP-Elites initialization and search settings.

Definition at line 47 of file boil.py.

Member Function Documentation

◆ _start_fixed_batch()

qdpy.algorithms.boil.BOIL._start_fixed_batch ( self,
size )
protected
Prepare a generation for an optimiser that opts into batch feedback.

Reimplemented from qdpy.algorithms.modern._FixedGeneration.

Definition at line 200 of file boil.py.

◆ best_target()

qdpy.algorithms.boil.BOIL.best_target ( self)

Find the strongest measured target utility, including measurements rejected by the grid.

Return a BOILTargetResult for the active target, or None before any observations.

Definition at line 136 of file boil.py.

◆ focus()

qdpy.algorithms.boil.BOIL.focus ( self,
cells = None )

Restrict the illumination phase to grid cells selected from the preview.

Select a nonempty sequence of grid indices, or pass None to use the full map.

Definition at line 104 of file boil.py.

◆ optimise()

qdpy.algorithms.boil.BOIL.optimise ( self,
evaluate,
budget = None,
** kwargs )

Spend a phase budget within the lifetime evaluation limit.

Run an additional phase, using the remaining budget if none is given.

Reimplemented from qdpy.algorithms.modern._FixedGeneration.

Definition at line 206 of file boil.py.

◆ prediction_map()

qdpy.algorithms.boil.BOIL.prediction_map ( self,
* ,
samples = 512,
min_probability = .5,
seed = 0 )

Build a model-only prediction map without spending evaluations or advancing the search.

Return up to one provisional solution per cell, ranked by predicted weighted fitness.

Definition at line 177 of file boil.py.

◆ reinit()

qdpy.algorithms.boil.BOIL.reinit ( self)
Reset measurements, the phase, and the lifetime attempt count.

Reimplemented from qdpy.algorithms.bayesian.BOPElites.

Definition at line 84 of file boil.py.

◆ remaining_evaluations()

qdpy.algorithms.boil.BOIL.remaining_evaluations ( self)
Return the number of attempts still available, including future phases.

Definition at line 95 of file boil.py.

◆ set_target()

qdpy.algorithms.boil.BOIL.set_target ( self,
descriptor,
* ,
distance_weight = 1. )

Search for measured solutions with a chosen target descriptor.

Maximize weighted fitness minus distance_weight times Euclidean descriptor error.

Definition at line 116 of file boil.py.


The documentation for this class was generated from the following file: