Skip to contents

Validates that a fitted learner is compatible with a given domain. Checks that the learner is fitted, that domain parameters match trained features, and validates type compatibility including factor level constraints.

Usage

assert_learner_domain(learner, domain, learner_name = NULL)

Arguments

learner

(mlr3::LearnerRegr)
A fitted regression learner.

domain

(paradox::ParamSet)
Parameter set describing the input space.

Value

TRUE invisibly if validation succeeds.

Details

Type compatibility:

  • ParamDbl -> numeric feature in training task

  • ParamInt -> integer or numeric feature in training task

  • ParamFct -> factor feature in training task, and domain levels must be a subset of the trained factor levels

  • ParamLgl -> logical feature in training task