Expand description
Multi-Fidelity Bayesian Optimization.
Implements multi-fidelity BO using an auto-regressive (AR(1)) coregionalization model across fidelity levels. Cheap, low-fidelity evaluations are used to inform the surrogate of the expensive, high-fidelity objective, letting the optimizer spend its budget efficiently.
§Approach
The AR(1) coregionalization model (Kennedy & O’Hagan 2000) assumes:
f_{l}(x) = rho_l * f_{l-1}(x) + delta_l(x)where delta_l is an independent GP correction at each fidelity level.
Each level l is fitted as a GP whose training target is y_l - rho_l * mu_{l-1}(x).
The acquisition function is the cost-normalized Expected Improvement
EI_cost(x, l) = EI(x, model_l) / cost_lwhich automatically selects both the next evaluation point and the fidelity level to use.
§Quick Start
use scirs2_optimize::bayesian::multi_fidelity::{
MultiFidelityBo, FidelityLevel, MultiFidelityConfig,
};
// Two-level example: level 0 is cheap (cost 1), level 1 is expensive (cost 10)
let levels = vec![
FidelityLevel { cost: 1.0, noise: 0.05, correlation: 1.0 },
FidelityLevel { cost: 10.0, noise: 0.001, correlation: 0.95 },
];
let bounds = vec![(-2.0_f64, 2.0_f64), (-2.0, 2.0)];
let mut mfbo = MultiFidelityBo::new(levels, bounds, MultiFidelityConfig::default())
.expect("build mfbo");
// Low-fidelity oracle (cheap)
let lf_fn = |x: &[f64]| x[0].powi(2) + x[1].powi(2) + 0.1 * (x[0] * x[1]);
// High-fidelity oracle (expensive)
let hf_fn = |x: &[f64]| x[0].powi(2) + x[1].powi(2);
let fns: Vec<Box<dyn Fn(&[f64]) -> f64>> = vec![
Box::new(lf_fn),
Box::new(hf_fn),
];
let result = mfbo.optimize(&fns, 30.0).expect("optimize");
println!("Best x: {:?}, f: {:.4}", result.x_best, result.f_best);Structs§
- Auto
Regressive Gp - AR(1) coregionalization multi-output GP.
- Fidelity
Level - Descriptor of a single fidelity level.
- Multi
Fidelity Bo - Multi-Fidelity Bayesian Optimizer.
- Multi
Fidelity Config - Configuration for multi-fidelity Bayesian optimization.
- Multi
Fidelity Result - Result of multi-fidelity Bayesian optimization.
Functions§
- extended_
ei - Compute the cost-normalized Expected Improvement at a candidate point.
- mfbo_
optimize - Run multi-fidelity Bayesian optimization.