【问题标题】:h2o package: total cluster memory zeroh2o 包:集群总内存为零
【发布时间】:2018-01-14 05:48:42
【问题描述】:
data1.dl.r2 = vector()
for (i in 1:100) {
if (i==1) {
  data1.hex = as.h2o(data1)
} else {
  data1.hex = nextdata 
}
  data1.dl = h2o.deeplearning    (x=2:1000,y=1,training_frame=data1.hex,nfolds=5,activation="Tanh",hidden=30,seed=5,reproducible=TRUE)
  data1.dl.pred = h2o.predict(data1.dl,data1.hex)
  data1.dl.r2[i] = sum((as.matrix(data1.dl.pred)-mean(as.matrix(data1.hex[,1])))^2)/
sum((as.matrix(data1.hex[,1])-mean(as.matrix(data1.hex[,1])))^2) # R-squared

  prevdata = as.matrix(data1.hex)
  nextpred = as.matrix(h2o.predict(data1.dl,as.h2o(data0[i,])))
  colnames(nextpred) = "response"
  nextdata = as.h2o(rbind(prevdata,cbind(nextpred,data0[i,-1])))

  print(i)
}

这是我的代码,其中包含 100 个观察值和 1000 个特征的数据集 (data1)。 当我运行它时,它在第 50~60 次迭代时给了我一条错误消息 "

Error in .h2o.doSafeREST(h2oRestApiVersion = h2oRestApiVersion, urlSuffix = page,  : 


ERROR MESSAGE:

Total input file size of 87.5 KB is much larger than total cluster memory of Zero  , please use either a larger cluster or smaller data.

当我运行“h20.init()”时,它告诉我集群总内存为零。

    H2O cluster total nodes:    1 
    H2O cluster total memory:   0.00 GB 
    H2O cluster total cores:    8 
    H2O cluster allowed cores:  8 
    H2O cluster healthy:        TRUE 

所以我想知道为什么集群总内存为零, 以及为什么它在早期的迭代中没有出错。

【问题讨论】:

  • 当我关闭 R Studio 并再次打开时,它显示集群总内存为 3.56GB。

标签: memory memory-management deep-learning cluster-computing h2o


【解决方案1】:

对我来说,下面的命令有效

h2o.shutdown(prompt = FALSE)

【讨论】:

    【解决方案2】:

    您需要重新启动 H2O 集群。

    尝试h2o.cluster().shutdown(),然后尝试h2o.init()。

    您也可以通过h2o.init(min_mem_size_GB=8) 显式设置分配给H2O 的内存,这当然取决于您的机器有多少内存。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2022-01-09
      • 2016-06-23
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2023-03-30
      • 2019-02-24
      • 1970-01-01
      相关资源
      最近更新 更多