在使用H2o AutoML在SageMaker实例上训练作业时,在运行代码后出现消息“此H2OFrame为空”,该怎么办才能解决问题?
/opt/ml/input/config/hyperparameters.json
All Parameters:
{'nfolds': '5', 'training': "{'classification': 'true', 'target': 'y'}", 'max_runtime_secs': '3600'}
/opt/ml/input/config/resourceconfig.json
All Resources:
{'current_host': 'algo-1', 'hosts': ['algo-1'], 'network_interface_name': 'eth0'}
Waiting until DNS resolves: 1
10.0.182.83
Starting up H2O-3
Creating Connection to H2O-3
Attempt 0: H2O-3 not running yet...
Connecting to H2O server at http://127.0.0.1:54321... successful.
-------------------------- ----------------------------------------
-------------------------- ----------------------------------------
Beginning Model Training
Parse progress: |█████████████████████████████████████████████████████████| 100%
Classification - If you want to do a regression instead, set "classification":"false" in "training" params, inhyperparamters.json
Converting specified columns to categorical values:
[]
AutoML progress: |████████████████████████████████████████████████████████| 100%
This H2OFrame is empty.
Exception during training: Argument `model` should be a ModelBase, got NoneType None
Traceback (most recent call last):
File "/opt/program/train", line 138, in _train_model
h2o.save_model(aml.leader, path=model_path)
File "/root/.local/lib/python3.7/site-packages/h2o/h2o.py", line 969, in save_model
assert_is_type(model, ModelBase)
File "/root/.local/lib/python3.7/site-packages/h2o/utils/typechecks.py", line 457, in assert_is_type
skip_frames=skip_frames)
h2o.exceptions.H2OTypeError: Argument `model` should be a ModelBase, got NoneType None
H2O session _sid_8aba closed.
我想知道这是否是由于max_runtime_secs而引起的问题,我的数据大约有500行和250000列。
答案 0 :(得分:1)
感谢@Marcel Mendes Reis在评论中关注您的解决方案。我将在这里转贴,以便其他人轻松找到:
我意识到这个问题是由于max_runtime引起的。当我花更多时间训练模型时,我就没有问题了。
答案 1 :(得分:0)
进行一些测试后,我意识到问题是由于max_runtime造成的,我认为我对模型的训练不够。