| AcqFunction {mlr3mbo} | R Documentation |
Acquisition Function Base Class
Description
Abstract acquisition function class.
Based on the predictions of a Surrogate, the acquisition function encodes the preference to evaluate a new point.
Super class
bbotk::Objective -> AcqFunction
Active bindings
direction(
"same"|"minimize"|"maximize")
Optimization direction of the acquisition function relative to the direction of the objective function of the bbotk::OptimInstance. Must be"same","minimize", or"maximize".surrogate_max_to_min(
-1|1)
Multiplicative factor to correct for minimization or maximization of the acquisition function.label(
character(1))
Label for this object.man(
character(1))
String in the format[pkg]::[topic]pointing to a manual page for this object.archive(bbotk::Archive)
Points to the bbotk::Archive of the surrogate.fun(
function)
Points to the private acquisition function to be implemented by subclasses.surrogate(Surrogate)
Surrogate.requires_predict_type_se(
logical(1))
Whether the acquisition function requires the surrogate to have"se"as$predict_type.packages(
character())
Set of required packages.
Methods
Public methods
Inherited methods
Method new()
Creates a new instance of this R6 class.
Note that the surrogate can be initialized lazy and can later be set via the active binding $surrogate.
Usage
AcqFunction$new( id, constants = ParamSet$new(), surrogate, requires_predict_type_se, direction, packages = NULL, label = NA_character_, man = NA_character_ )
Arguments
id(
character(1)).constants(paradox::ParamSet). Changeable constants or parameters.
surrogate(
NULL| Surrogate). Surrogate whose predictions are used in the acquisition function.requires_predict_type_se(
logical(1))
Whether the acquisition function requires the surrogate to have"se"as$predict_type.direction(
"same"|"minimize"|"maximize"). Optimization direction of the acquisition function relative to the direction of the objective function of the bbotk::OptimInstance. Must be"same","minimize", or"maximize".packages(
character())
Set of required packages. A warning is signaled prior to construction if at least one of the packages is not installed, but loaded (not attached) later on-demand viarequireNamespace().label(
character(1))
Label for this object.man(
character(1))
String in the format[pkg]::[topic]pointing to a manual page for this object.
Method update()
Update the acquisition function.
Can be implemented by subclasses.
Usage
AcqFunction$update()
Method eval_many()
Evaluates multiple input values on the objective function.
Usage
AcqFunction$eval_many(xss)
Arguments
xss(
list())
A list of lists that contains multiple x values, e.g.list(list(x1 = 1, x2 = 2), list(x1 = 3, x2 = 4)).
Returns
data.table::data.table() that contains one y-column for
single-objective functions and multiple y-columns for multi-objective functions,
e.g. data.table(y = 1:2) or data.table(y1 = 1:2, y2 = 3:4).
Method eval_dt()
Evaluates multiple input values on the objective function
Usage
AcqFunction$eval_dt(xdt)
Arguments
xdt(
data.table::data.table())
One point per row, e.g.data.table(x1 = c(1, 3), x2 = c(2, 4)).
Returns
data.table::data.table() that contains one y-column for
single-objective functions and multiple y-columns for multi-objective
functions, e.g. data.table(y = 1:2) or data.table(y1 = 1:2, y2 = 3:4).
Method clone()
The objects of this class are cloneable with this method.
Usage
AcqFunction$clone(deep = FALSE)
Arguments
deepWhether to make a deep clone.
See Also
Other Acquisition Function:
mlr_acqfunctions,
mlr_acqfunctions_aei,
mlr_acqfunctions_cb,
mlr_acqfunctions_ehvi,
mlr_acqfunctions_ehvigh,
mlr_acqfunctions_ei,
mlr_acqfunctions_eips,
mlr_acqfunctions_mean,
mlr_acqfunctions_pi,
mlr_acqfunctions_sd,
mlr_acqfunctions_smsego