Skip to contents

This function reconstructs an EAGGA model from a mlr3tuning::TuningInstanceMultiCrit and TunerEAGGA and a model unique hash (uhash) value after a completed tuning run

Usage

reconstruct_eagga_model(instance, tuner, model_uhash)

Arguments

instance

(mlr3tuning::TuningInstanceMultiCrit)
The terminated tuning instance.

tuner

(TunerEAGGA)
The tuner that optimized the instance.

model_uhash

(character(1)
A character string representing the unique hash (uhash) of the model to be reconstructed. See instance$archive$data$uhash for possible values.

Value

The reconstructed EAGGA model in the form of the (mlr3::Learner) passed during construction of the mlr3tuning::TuningInstanceMultiCrit trained on the full mlr3::Task.

Details

This function reconstructs an EAGGA model observed during tuning specified by its unique hash by extracting the necessary information from the provided mlr3tuning::TuningInstanceMultiCrit and TunerEAGGA object. It clones the learner and task from the tuning instance, sets the learner's hyperparameter values according to the values logged into the archive matching the given unique hash of the model and trains the learner on the task. Note that if no random seed was specified during construction of the TunerEAGGA (via the seed_calculate_proxy_measures parameter), exact reconstruction may not be possible. As the learner is trained on the complete task, the model can be readily used on new data. It should no longer be used for performance estimation unless you do have access to another task containing hold-out test data that was not seen during tuning.