mlr-org/mlrMBO

"Human in the Loop MBO" breaks with AdaCB infill crit

mb706 opened this issue · 1 comments

mb706 commented

Example, adapted from the tutorial:

ps = makeParamSet(
  makeNumericParam("q", lower = -1, upper = 2),
  makeIntegerParam("v", lower = -2, upper = 3)
)
des = generateDesign(n = 7, par.set = ps)
des$y = c(1.20, 0.97, 0.91, 3.15, 0.58, 1.12, 0.50)
ctrl = makeMBOControl()
ctrl = setMBOControlInfill(ctrl, crit = makeMBOInfillCritAdaCB())  # !!!!!!!!!!!!
opt.state = initSMBO(par.set = ps, design = des, control = ctrl, minimize = TRUE, noisy = FALSE)
proposePoints(opt.state)
x = data.frame(q = 1.7, v = 1)
updateSMBO(opt.state, x = x, y = 2.19)

gives error

Error in control$infill.crit$fun(points = x, models = getOptStateModels(opt.state)[[1]],  : 
  unused argument (designs = getOptStateDesigns(opt.state))

Okay, this is not an easy fix because naturally the Adaptive Infill Crit needs a progress value which is not necessarily present for SMBO.

Options:

  1. Error if AdaCB is used with SMBO
  2. If adaptive infill, the progress has to be passed
  3. Progress is always 0 (it is the case now)
  4. Progress is 0 by default but can be manually overwritten (eg. setOptStateProgress())