param_set attribute is not populating properly #256
-
The param_set attribute does populate properly when I follow the examples in the online book. I always receive the response "Empty parameter set." This result does not change no matter which learner I use. I updated R and re-installed all the packages and am getting the same error every time. For example when I execute the code here: https://mlr3book.mlr-org.com/searchspace.html I still receive the 'Empty parameter set.' response. Code: Execution Result:
Thanks! |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
You can compare your environment with the below one. The mlr3book usually only uses the CRAN versions of the pkgs and we see no issues here. library("mlr3verse")
#> Loading required package: mlr3
task <- tsk("pima")
print(task)
#> <TaskClassif:pima> (768 x 9)
#> * Target: diabetes
#> * Properties: twoclass
#> * Features (8):
#> - dbl (8): age, glucose, insulin, mass, pedigree, pregnant, pressure,
#> triceps
task$backend # show that data is loading
#> <DataBackendDataTable> (768x10)
#> pregnant glucose pressure triceps insulin mass pedigree age diabetes ..row_id
#> 6 148 72 35 NA 33.6 0.627 50 pos 1
#> 1 85 66 29 NA 26.6 0.351 31 neg 2
#> 8 183 64 NA NA 23.3 0.672 32 pos 3
#> 1 89 66 23 94 28.1 0.167 21 neg 4
#> 0 137 40 35 168 43.1 2.288 33 pos 5
#> 5 116 74 NA NA 25.6 0.201 30 neg 6
#> [...] (762 rows omitted)
learner <- lrn("classif.rpart")
learner$param_set
#> <ParamSet>
#> id class lower upper nlevels default value
#> 1: cp ParamDbl 0 1 Inf 0.01
#> 2: keep_model ParamLgl NA NA 2 FALSE
#> 3: maxcompete ParamInt 0 Inf Inf 4
#> 4: maxdepth ParamInt 1 30 30 30
#> 5: maxsurrogate ParamInt 0 Inf Inf 5
#> 6: minbucket ParamInt 1 Inf Inf <NoDefault[3]>
#> 7: minsplit ParamInt 1 Inf Inf 20
#> 8: surrogatestyle ParamInt 0 1 2 0
#> 9: usesurrogate ParamInt 0 2 3 2
#> 10: xval ParamInt 0 Inf Inf 10 0 Created on 2021-08-26 by the reprex package (v2.0.1) Session infosessioninfo::session_info()
#> ─ Session info ───────────────────────────────────────────────────────────────
#> setting value
#> version R version 4.1.1 (2021-08-10)
#> os macOS Big Sur 10.16
#> system x86_64, darwin17.0
#> ui X11
#> language (EN)
#> collate en_US.UTF-8
#> ctype en_US.UTF-8
#> tz Europe/Zurich
#> date 2021-08-26
#>
#> ─ Packages ───────────────────────────────────────────────────────────────────
#> package * version date lib
#> assertthat 0.2.1 2019-03-21 [1]
#> backports 1.2.1 2020-12-09 [1]
#> bbotk 0.3.2 2021-03-18 [1]
#> checkmate 2.0.0 2020-02-06 [1]
#> cli 3.0.1 2021-07-17 [1]
#> clue 0.3-59 2021-04-16 [1]
#> cluster 2.1.2 2021-04-17 [1]
#> clusterCrit 1.2.8 2018-07-26 [1]
#> codetools 0.2-18 2020-11-04 [2]
#> colorspace 2.0-2 2021-06-24 [1]
#> crayon 1.4.1 2021-02-08 [1]
#> data.table 1.14.0 2021-02-21 [1]
#> DBI 1.1.1 2021-01-15 [1]
#> digest 0.6.27 2020-10-24 [1]
#> distr6 1.5.6 2021-07-17 [1]
#> dplyr 1.0.7 2021-06-18 [1]
#> ellipsis 0.3.2 2021-04-29 [1]
#> evaluate 0.14 2019-05-28 [1]
#> fansi 0.5.0 2021-05-25 [1]
#> fs 1.5.0 2020-07-31 [1]
#> future 1.21.0 2020-12-10 [1]
#> generics 0.1.0 2020-10-31 [1]
#> ggplot2 3.3.5 2021-06-25 [1]
#> globals 0.14.0 2020-11-22 [1]
#> glue 1.4.2 2020-08-27 [1]
#> gtable 0.3.0 2019-03-25 [1]
#> highr 0.9 2021-04-16 [1]
#> htmltools 0.5.1.1 2021-01-22 [1]
#> knitr 1.33 2021-04-24 [1]
#> lattice 0.20-44 2021-05-02 [2]
#> lgr 0.4.2 2021-01-10 [1]
#> lifecycle 1.0.0 2021-02-15 [1]
#> listenv 0.8.0 2019-12-05 [1]
#> magrittr 2.0.1 2020-11-17 [1]
#> Matrix 1.3-4 2021-06-01 [2]
#> mlr3 * 0.12.0-9000 2021-08-26 [1]
#> mlr3cluster 0.1.1 2020-11-15 [1]
#> mlr3data 0.5.0 2021-06-29 [1]
#> mlr3extralearners 0.5.1 2021-08-10 [1]
#> mlr3filters 0.4.2 2021-07-12 [1]
#> mlr3fselect 0.5.1 2021-03-09 [1]
#> mlr3learners 0.5.0 2021-08-17 [1]
#> mlr3misc 0.9.3.9000 2021-08-23 [1]
#> mlr3pipelines 0.3.5-1 2021-08-05 [1]
#> mlr3proba 0.4.0 2021-04-18 [1]
#> mlr3tuning 0.8.0 2021-03-12 [1]
#> mlr3verse * 0.2.2 2021-08-11 [1]
#> mlr3viz 0.5.5 2021-08-12 [1]
#> munsell 0.5.0 2018-06-12 [1]
#> palmerpenguins 0.1.0 2020-07-23 [1]
#> paradox 0.7.1 2021-03-07 [1]
#> parallelly 1.27.0-9001 2021-08-10 [1]
#> pillar 1.6.2 2021-07-29 [1]
#> pkgconfig 2.0.3 2019-09-22 [1]
#> purrr 0.3.4 2020-04-17 [1]
#> R.cache 0.15.0 2021-04-30 [1]
#> R.methodsS3 1.8.1 2020-08-26 [1]
#> R.oo 1.24.0 2020-08-26 [1]
#> R.utils 2.10.1 2020-08-26 [1]
#> R6 2.5.1 2021-08-19 [1]
#> R62S3 1.4.1 2020-03-09 [1]
#> Rcpp 1.0.7 2021-07-07 [1]
#> rematch2 2.1.2 2020-05-01 [1]
#> reprex 2.0.1 2021-08-05 [1]
#> rlang 0.4.11 2021-04-30 [1]
#> rmarkdown 2.10.4 2021-08-23 [1]
#> rstudioapi 0.13 2020-11-12 [1]
#> scales 1.1.1 2020-05-11 [1]
#> sessioninfo 1.1.1 2018-11-05 [1]
#> set6 0.2.3 2021-07-25 [1]
#> stringi 1.7.3 2021-07-16 [1]
#> stringr 1.4.0 2019-02-10 [1]
#> styler 1.5.1.9001 2021-08-23 [1]
#> survival 3.2-11 2021-04-26 [2]
#> tibble 3.1.3 2021-07-23 [1]
#> tidyselect 1.1.1 2021-04-30 [1]
#> utf8 1.2.2 2021-07-24 [1]
#> uuid 0.1-4 2020-02-26 [1]
#> vctrs 0.3.8 2021-04-29 [1]
#> withr 2.4.2 2021-04-18 [1]
#> xfun 0.25 2021-08-06 [1]
#> yaml 2.2.1 2020-02-01 [1]
#> source
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> standard (@2.0.0)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.1)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> standard (@0.5.1.1)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.1)
#> CRAN (R 4.1.0)
#> standard (@1.0.0)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.1)
#> local
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> Github (mlr-org/mlr3extralearners@3655cce)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.1)
#> Github (mlr-org/mlr3misc@e02079a)
#> CRAN (R 4.1.1)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.1)
#> CRAN (R 4.1.1)
#> standard (@0.5.0)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> Github (HenrikBengtsson/parallelly@d050eba)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> standard (@0.3.4)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.1)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> standard (@2.1.2)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> Github (rstudio/rmarkdown@75e8f71)
#> CRAN (R 4.1.0)
#> standard (@1.1.1)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> standard (@1.4.0)
#> Github (r-lib/styler@2b1eeac)
#> CRAN (R 4.1.1)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> CRAN (R 4.1.0)
#> standard (@2.2.1)
#>
#> [1] /Users/pjs/Library/R/x86_64/4.1/library
#> [2] /Library/Frameworks/R.framework/Versions/4.1/Resources/library |
Beta Was this translation helpful? Give feedback.
You can compare your environment with the below one. The mlr3book usually only uses the CRAN versions of the pkgs and we see no issues here.