我正在尝试通过 R 在 H2O 中运行 gbm 模型并得到以下错误之一:
|========================== | 25%
Polling fails:
<simpleError in .h2o.__poll(client, job_key): Got exception 'class java.lang.RuntimeException', with msg 'java.lang.AssertionError: NewChunk.dst.len = 0, oc._len = 1235'
java.lang.RuntimeException: java.lang.AssertionError: NewChunk.dst.len = 0, oc._len = 1235
at hex.FrameExtractor.getResult(FrameExtractor.java:77)
at water.util.CrossValUtils.crossValidate(CrossValUtils.java:29)
at hex.gbm.GBM.execImpl(GBM.java:201)
at water.Func.exec(Func.java:42)
at water.Job$3.compute2(Job.java:333)
at water.H2O$H2OCountedCompleter.compute(H2O.java:647)
at jsr166y.CountedCompleter.exec(CountedCompleter.java:429)
at jsr166y.ForkJoinTask.doExec(ForkJoinTask.java:263)
at jsr166y.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:974)
at jsr166y.ForkJoinPool.runWorker(ForkJoinPool.java:1477)
at jsr166y.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:104)
Caused by: java.lang.AssertionError: NewChunk.dst.len = 0, oc._len = 1235
at water.fvec.ChunkSplitter.extractChunkPart(ChunkSplitter.java:44)
at hex.NFoldFrameExtractor$FoldExtractTask.map(NFoldFrameExtractor.java:105)
at water.MRTask2.compute2(MRTask2.java:404)
... 6 more
>
|=========================================================================================================| 100%
Error in .h2o.__remoteSend(data@h2o, model_view, `_modelKey` = xvalKey[i]) :
http://127.0.0.1:54321/2/GBMModelView.json returned the following error:
Model 'GBM_a1b17d68e29d7ba49cb6243293344b69_xval0' not found!
或者这个版本:
|=================== | 25%
Polling fails:
<simpleError in .h2o.__poll(client, job_key): Got exception 'class java.lang.AssertionError', with msg 'null'
java.lang.AssertionError
at hex.gbm.GBM.buildNextKTrees(GBM.java:505)
at hex.gbm.GBM.buildModel(GBM.java:296)
at hex.gbm.GBM.buildModel(GBM.java:26)
at hex.gbm.SharedTreeModelBuilder.buildModel(SharedTreeModelBuilder.java:276)
at hex.gbm.GBM.execImpl(GBM.java:200)
at water.Func.exec(Func.java:42)
at water.Job.invoke(Job.java:353)
at water.Job$ValidatedJob.genericCrossValidation(Job.java:889)
at hex.gbm.GBM.crossValidate(GBM.java:709)
at water.util.CrossValUtils.crossValidate(CrossValUtils.java:32)
at hex.gbm.GBM.execImpl(GBM.java:201)
at water.Func.exec(Func.java:42)
at water.Job$3.compute2(Job.java:333)
at water.H2O$H2OCountedCompleter.compute(H2O.java:647)
at jsr166y.CountedCompleter.exec(CountedCompleter.java:429)
at jsr166y.ForkJoinTask.doExec(ForkJoinTask.java:263)
at jsr166y.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:974)
at jsr166y.ForkJoinPool.runWorker(ForkJoinPool.java:1477)
at jsr166y.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:104)
>
|============================================================================| 100%
Error in tail(res$cms, 1)[[1]] : subscript out of bounds
这是导致错误的行:
dat1.gbm <- h2o.gbm(y = 'click_target2', x = xVars, data = train1.hex
, nfolds = 3
, importance = T
, distribution = 'bernoulli'
, n.trees = 200
, interaction.depth = 10,
# , n.minobsinnode = 2
, shrinkage = 0.01
)
关于导致此错误的任何建议?
编辑:
我一直在尝试诊断 csv 文件本身是否存在问题,看来这可能是问题所在。我最终在 python 中编写了一个脚本,以将大文件按 week_number 分解为单个 csv 文件。通过读取文件大约 2/3 的方式我得到一个 NULL 字节异常错误。我仍在努力寻找解决此问题的方法。