训练学习者后,将最终模型保存在哪里mlr3
--- learner$train(data)
?通过“最终模型”,我的意思是类似于由以下代码生成的列表:
model <- xgboost::xgb.train(data = data_train,
max.depth = 8, nthread = 2, nrounds = 15,
verbose = 0)
有没有办法提取这个列表/对象?
task <- TaskRegr$new("data", data, "y")
learner <- lrn("regr.xgboost")
preprocess <- po("scale", param_vals = list(center = TRUE, scale = TRUE))
pp <- preprocess %>>% learner
gg<- GraphLearner$new(pp)
gg$train(task)