Skip to contents

Augmented Expected Improvement. Useful when working with noisy objectives. Currently only works correctly with "regr.km" as surrogate model and nugget.estim = TRUE or given.

Dictionary

This AcqFunction can be instantiated via the dictionary mlr_acqfunctions or with the associated sugar function acqf():

mlr_acqfunctions$get("aei")
acqf("aei")

Parameters

  • "c" (numeric(1))
    Constant \(c\) as used in Formula (14) of Huang (2012) to reflect the degree of risk aversion. Defaults to 1.

References

  • Huang D, Allen TT, Notz WI, Zheng N (2012). “Erratum To: Global Optimization of Stochastic Black-box Systems via Sequential Kriging Meta-Models.” Journal of Global Optimization, 54(2), 431--431.

Super classes

bbotk::Objective -> mlr3mbo::AcqFunction -> AcqFunctionAEI

Public fields

y_effective_best

(numeric(1))
Best effective objective value observed so far. In the case of maximization, this already includes the necessary change of sign.

noise_var

(numeric(1))
Estimate of the variance of the noise. This corresponds to the nugget estimate when using a mlr3learners as surrogate model.

Methods

Inherited methods


Method new()

Creates a new instance of this R6 class.

Usage

AcqFunctionAEI$new(surrogate = NULL, c = 1)

Arguments

surrogate

(NULL | SurrogateLearner).

c

(numeric(1)).


Method update()

Updates acquisition function and sets y_effective_best and noise_var.

Usage

AcqFunctionAEI$update()


Method clone()

The objects of this class are cloneable with this method.

Usage

AcqFunctionAEI$clone(deep = FALSE)

Arguments

deep

Whether to make a deep clone.

Examples

if (requireNamespace("mlr3learners") &
    requireNamespace("DiceKriging") &
    requireNamespace("rgenoud")) {
  library(bbotk)
  library(paradox)
  library(mlr3learners)
  library(data.table)

  set.seed(2906)
  fun = function(xs) {
    list(y = xs$x ^ 2 + rnorm(length(xs$x), mean = 0, sd = 1))
  }
  domain = ps(x = p_dbl(lower = -10, upper = 10))
  codomain = ps(y = p_dbl(tags = "minimize"))
  objective = ObjectiveRFun$new(fun = fun,
    domain = domain,
    codomain = codomain,
    properties = "noisy")

  instance = OptimInstanceSingleCrit$new(
    objective = objective,
    terminator = trm("evals", n_evals = 5))

  instance$eval_batch(data.table(x = c(-6, -5, 3, 9)))

  learner = lrn("regr.km",
    covtype = "matern5_2",
    optim.method = "gen",
    nugget.estim = TRUE,
    jitter = 1e-12,
    control = list(trace = FALSE))

  surrogate = srlrn(learner, archive = instance$archive)

  acq_function = acqf("aei", surrogate = surrogate)

  acq_function$surrogate$update()
  acq_function$update()
  acq_function$eval_dt(data.table(x = c(-1, 0, 1)))
}
#>     acq_aei
#>       <num>
#> 1: 7.583607
#> 2: 7.583607
#> 3: 7.583607