QDpy
Loading...
Searching...
No Matches
qdpy.algorithms.vq_elites.VQElites Class Reference

Learn archive niches using a vector-quantized autoencoder. More...

Public Member Functions

 stats (self)
 codebook (self)
 observe (self, genome, fitness, observation)
 Offer a previously measured candidate and trigger a refit when due.
 run (self, evaluate, budget)
 Collect additional real measurements using bounded Iso+LineDD variation.

Detailed Description

Learn archive niches using a vector-quantized autoencoder.

Store one measured elite per learned code.

The encoder maps raw observations to bounded latents. Each latent
selects its nearest learnable code. Periodic updates train from a
bounded observation depot, then re-encode already measured elites.
At the first refit the depot supplies initial codebook clusters
and archive seeds. Colliding elites compete using their stored
fitnesses, so remaps never call the expensive evaluator.

:param dimension: Length of a numeric decision vector.
:param observation_size: Number of numeric values in each raw observation.
:param cells: Number of learned archive codes.
:param latent_size: Width of the latent space.
:param hidden_size: Hidden width of the encoder and decoder.
:param ind_domain: Shared finite genome bounds.
:param fitness_domain: Closed interval of raw objective values.
:param fitness_weight: Finite nonzero signed objective weight.
:param training_period: Measurements between codebook updates.
:param training_capacity: Most recent measurements retained for training.
:param epochs: Optimizer passes per refit.
:param batch_size: Optimizer minibatch width.
:param learning_rate: Positive Adam learning rate.
:param commitment: Nonnegative encoder commitment weight.
:param iso_sigma: Independent Gaussian mutation scale.
:param line_sigma: Shared Iso+LineDD direction scale.
:param seed: Private random seed for trajectories, codebook and optimization.
:param device: Torch CPU or CUDA device.

Definition at line 37 of file vq_elites.py.

Member Function Documentation

◆ codebook()

qdpy.algorithms.vq_elites.VQElites.codebook ( self)
Return a detached copy of the current latent centroids.

Definition at line 128 of file vq_elites.py.

◆ observe()

qdpy.algorithms.vq_elites.VQElites.observe ( self,
genome,
fitness,
observation )

Offer a previously measured candidate and trigger a refit when due.

Accept a scalar objective and a finite observation with observation_size values.

Definition at line 208 of file vq_elites.py.

◆ run()

qdpy.algorithms.vq_elites.VQElites.run ( self,
evaluate,
budget )

Collect additional real measurements using bounded Iso+LineDD variation.

Call evaluate(genome) for a pair (scalar fitness, raw observation).

Definition at line 226 of file vq_elites.py.

◆ stats()

qdpy.algorithms.vq_elites.VQElites.stats ( self)
Return cumulative work, including measurements supplied with observe().

Definition at line 123 of file vq_elites.py.


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