我得到一个"对象' requireNamespaceQuietStop'找不到"使用Rmpi通过插入符运行模型时出错。没有Rmpi,我能够很好地运行模型。
这是一个最小的例子:
> library(mlbench)
> library(doMPI)
> library(caret)
> set.seed(998)
> cl <- startMPIcluster(count=8)
8 slaves are spawned successfully. 0 failed.
> registerDoMPI(cl)
> data(Sonar)
> inTraining <- createDataPartition(Sonar$Class, p = .75, list = FALSE)
> training <- Sonar[ inTraining,]
> testing <- Sonar[-inTraining,]
> fitControl <- trainControl(
method = "repeatedcv",
number = 10,
repeats = 10)
> gbmFit1 <- train(Class ~ ., data = training,
method = "gbm",
trControl = fitControl,
verbose = FALSE)
Error in { :
task 2 failed - "object 'requireNamespaceQuietStop' not found"
>
另外,这是我的会话信息:
> sessionInfo()
R version 3.5.0 (2018-04-23)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows >= 8 x64 (build 9200)
Matrix products: default
locale:
[1] LC_COLLATE=English_United States.1252 LC_CTYPE=English_United States.1252
[3] LC_MONETARY=English_United States.1252 LC_NUMERIC=C
[5] LC_TIME=English_United States.1252
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] caret_6.0-79 ggplot2_2.2.1 lattice_0.20-35 doMPI_0.2.2 Rmpi_0.6-7 iterators_1.0.9
[7] foreach_1.4.4 mlbench_2.1-1 h2o_3.18.0.8
loaded via a namespace (and not attached):
[1] Rcpp_0.12.16 lubridate_1.7.4 tidyr_0.8.0 class_7.3-14 assertthat_0.2.0
[6] glmnet_2.0-16 ipred_0.9-6 psych_1.8.3.3 R6_2.2.2 plyr_1.8.4
[11] magic_1.5-8 reprex_0.1.2 stats4_3.5.0 e1071_1.6-8 pillar_1.2.2
[16] rlang_0.2.0 lazyeval_0.2.1 kernlab_0.9-26 rpart_4.1-13 Matrix_1.2-14
[21] splines_3.5.0 CVST_0.2-1 ddalpha_1.3.3 gower_0.1.2 stringr_1.3.0
[26] foreign_0.8-70 RCurl_1.95-4.10 munsell_0.4.3 broom_0.4.4 compiler_3.5.0
[31] pkgconfig_2.0.1 mnormt_1.5-5 dimRed_0.1.0 gbm_2.1.3 nnet_7.3-12
[36] tidyselect_0.2.4 tibble_1.4.2 prodlim_2018.04.18 DRR_0.0.3 codetools_0.2-15
[41] RcppRoll_0.2.2 dplyr_0.7.4 withr_2.1.2 MASS_7.3-49 bitops_1.0-6
[46] recipes_0.1.2 ModelMetrics_1.1.0 grid_3.5.0 nlme_3.1-137 jsonlite_1.5
[51] gtable_0.2.0 magrittr_1.5 scales_0.5.0 stringi_1.1.7 reshape2_1.4.3
[56] bindrcpp_0.2.2 timeDate_3043.102 robustbase_0.93-0 geometry_0.3-6 lava_1.6.1
[61] tools_3.5.0 glue_1.2.0 DEoptimR_1.0-8 purrr_0.2.4 sfsmisc_1.1-2
[66] abind_1.4-5 parallel_3.5.0 survival_2.41-3 yaml_2.1.18 colorspace_1.3-2
[71] knitr_1.20 bindr_0.1.1
还有其他人有此错误吗?有解决方法吗?