pulsatrix
Loading...
Searching...
No Matches
gp_bo.hpp File Reference

The GP-BO trial loop: random-initialize, then repeatedly fit a GP to every trial observed so far and propose the next point by maximizing an acquisition function over random candidates in the unit hypercube. More...

#include <algorithm>
#include <cmath>
#include <limits>
#include <random>
#include <stdexcept>
#include <vector>
#include "pulsatrix/acquisition_functions.hpp"
#include "pulsatrix/gaussian_process.hpp"
#include "pulsatrix/search_space.hpp"
#include "pulsatrix/trial.hpp"
Include dependency graph for gp_bo.hpp:

Go to the source code of this file.

Namespaces

namespace  pulsatrix
 

Enumerations

enum class  pulsatrix::AcquisitionKind { pulsatrix::ExpectedImprovement , pulsatrix::ProbabilityOfImprovement , pulsatrix::UpperConfidenceBound }
 Which acquisition function RunGPBOLoop maximizes over candidates each iteration. More...
 

Functions

Configuration pulsatrix::UnitCubeToConfiguration (const SearchSpace &space, const std::vector< float > &t)
 Maps a unit-hypercube point (one value per parameter, each in [0, 1]) to a Configuration, using space's own declared bounds.
 
template<typename ObjectiveFn , typename RNG >
std::vector< Trial > pulsatrix::RunGPBOLoop (const SearchSpace &space, ObjectiveFn objective_fn, size_t num_initial_random, size_t num_iterations, AcquisitionKind acquisition, size_t num_candidates, RNG &rng)
 Runs GP-BO: num_initial_random uniformly-random trials, then num_iterations trials each chosen by fitting a GP to every trial so far and maximizing acquisition over num_candidates random points in the unit hypercube.
 

Detailed Description

The GP-BO trial loop: random-initialize, then repeatedly fit a GP to every trial observed so far and propose the next point by maximizing an acquisition function over random candidates in the unit hypercube.

Note
GP-BO here supports Continuous/LogUniform parameters only – Integer/Categorical parameters (mixed/conditional search spaces) are explicitly TPE's job (Phase 2 Mission 2), not vanilla GP-BO's, per this campaign's own scope note. Attempting to run GP-BO over a SearchSpace containing an Integer/Categorical parameter throws.
Internally operates entirely in the unit hypercube [0, 1]^d, not the SearchSpace's own (possibly wildly different per-dimension) bounds – this is not just convenience: the GP kernel's single length_scale hyperparameter is only meaningfully comparable across dimensions if every dimension is on the same scale.