H2O 本地服务器意外死机

问题描述

我在重现 AutoML tutorial in H2O documentation 时遇到问题。初始化我的 h2o 本地服务器 (h2o.init()) 后,我得到以下输出,这听起来是正确的:

Checking whether there is an H2O instance running at http://localhost:54321 ..... not found.
Attempting to start a local H2O server...
  Java Version: java version "1.8.0_181"; Java(TM) SE Runtime Environment (build 1.8.0_181-b13); Java HotSpot(TM) 64-Bit Server VM (build 25.181-b13,mixed mode)
  Starting server from /home/cdsw/.local/lib/python3.8/site-packages/h2o/backend/bin/h2o.jar
  Ice root: /tmp/tmp3nh32di4
  JVM stdout: /tmp/tmp3nh32di4/h2o_cdsw_started_from_python.out
  JVM stderr: /tmp/tmp3nh32di4/h2o_cdsw_started_from_python.err
  Server is running at http://127.0.0.1:54321
Connecting to H2O server at http://127.0.0.1:54321 ... successful.
H2O_cluster_uptime: 01 secs
H2O_cluster_timezone:   Etc/UTC
H2O_data_parsing_timezone:  UTC
H2O_cluster_version:    3.32.1.3
H2O_cluster_version_age:    14 days,20 hours and 29 minutes
H2O_cluster_name:   H2O_from_python_cdsw_cpcrap
H2O_cluster_total_nodes:    1
H2O_cluster_free_memory:    13.98 Gb
H2O_cluster_total_cores:    32
H2O_cluster_allowed_cores:  32
H2O_cluster_status: accepting new members,healthy
H2O_connection_url: http://127.0.0.1:54321
H2O_connection_proxy:   {"http": null,"https": null}
H2O_internal_security:  False
H2O_API_Extensions: Amazon S3,XGBoost,Algos,AutoML,Core V3,TargetEncoder,Core V4
Python_version: 3.8.5 final

接下来,我按照教程的指定导入数据集:

# Identify predictors and response
x = train.columns
y = "response"
x.remove(y)

# For binary classification,response should be a factor
train[y] = train[y].asfactor()
test[y] = test[y].asfactor()

最后,我训练我的 AutoML 模型:

# Run AutoML for 20 base models (limited to 1 hour max runtime by default)
aml = H2OAutoML(max_models=20,seed=1)
aml.train(x=x,y=y,training_frame=train)

那是当它崩溃并显示以下消息时:

AutoML progress: |██Failed polling AutoML progress log: Local server has died unexpectedly. RIP.
Job request Failed Local server has died unexpectedly. RIP.,will retry after 3s.
Job request Failed Local server has died unexpectedly. RIP.,will retry after 3s.

尝试了不同的数据集,包括一些样本,以防它是内存问题,但无济于事。错误为准。

有人知道我应该怎么做才能解决这个问题吗?

非常感谢!

问候。

解决方法

我想我能够解决它。使用 htop 命令进行一些监控后,我认为问题实际上是内存问题。我重新启动了 h2o,将内存限制为 1GB 和 2 个线程(也许这不是绝对必要的),并且看起来我能够运行一切正常。

h2o.init(max_mem_size="1G",nthreads=2)

希望对遇到同样问题的人有所帮助。

相关问答

Selenium Web驱动程序和Java。元素在(x,y)点处不可单击。其...
Python-如何使用点“。” 访问字典成员?
Java 字符串是不可变的。到底是什么意思?
Java中的“ final”关键字如何工作?(我仍然可以修改对象。...
“loop:”在Java代码中。这是什么,为什么要编译?
java.lang.ClassNotFoundException:sun.jdbc.odbc.JdbcOdbc...