Skip to contents

Specialized bbotk::CallbackOptimization for feature selection. Callbacks allow customizing the behavior of processes in mlr3fselect. The callback_fselect() function creates a CallbackFSelect. Predefined callbacks are stored in the dictionary mlr_callbacks and can be retrieved with clbk(). For more information on callbacks see callback_fselect().

Super classes

mlr3misc::Callback -> bbotk::CallbackOptimization -> CallbackFSelect

Public fields

on_eval_after_design

(function())
Stage called after design is created. Called in ObjectiveFSelect$eval_many().

on_eval_after_benchmark

(function())
Stage called after feature sets are evaluated. Called in ObjectiveFSelect$eval_many().

on_eval_before_archive

(function())
Stage called before performance values are written to the archive. Called in ObjectiveFSelect$eval_many().

Methods

Public methods

Inherited methods


Method clone()

The objects of this class are cloneable with this method.

Usage

CallbackFSelect$clone(deep = FALSE)

Arguments

deep

Whether to make a deep clone.

Examples

# Write archive to disk
callback_fselect("mlr3fselect.backup",
  on_optimization_end = function(callback, context) {
    saveRDS(context$instance$archive, "archive.rds")
  }
)
#> <CallbackFSelect:mlr3fselect.backup>
#> * Active Stages: on_optimization_end