我安装了 R 版本 3.5.1(在 Windows 7 x64 桌面 PC 上),然后是 Rtools 3.5 和 rstan(通过 install.packages())
Rstan 在多核支持方面失败,如下所示:
library(rstan)
rstan_options(auto_write = TRUE)
options(mc.cores = 3) # or any number above 2
fit <- stan(file = '8schools.stan', data = schools_dat,
iter = 3, chains = 4)
有错误:
Error in checkForRemoteErrors(val) :
4 nodes produced errors; first error: unable to load shared object 'C:/Users/ubashir/AppData/Local/Temp/RtmpIHGdm6/file194833bbb82.dll':
LoadLibrary failure: Access is denied.
但是,如果我将选项行更改为:
options(mc.cores = 1) # or any other number up to 8
该代码有效。除了仅使用 1 个核心之外,任何人都知道解决方案吗?谢谢