Deep learning h2o深度学习检查点模型

Deep learning h2o深度学习检查点模型,deep-learning,h2o,checkpointing,Deep Learning,H2o,Checkpointing,各位 我在尝试从提供验证框架的检查点模型恢复R中的h2o深度学习时遇到一些问题。它说“验证数据集必须与检查点模型相同”,我相信我有相同的验证数据集。若我将validation_frame留空,那个么检查点模型可以正常工作。我在下面附上我的代码: localh2o <- h2o.init(nthreads = -1) train_image.hex <- read.csv("mnist_train.csv",header=FALSE) train_image.hex[,785] <

各位

我在尝试从提供验证框架的检查点模型恢复R中的h2o深度学习时遇到一些问题。它说“验证数据集必须与检查点模型相同”,我相信我有相同的验证数据集。若我将validation_frame留空,那个么检查点模型可以正常工作。我在下面附上我的代码:

localh2o <- h2o.init(nthreads = -1)
train_image.hex <- read.csv("mnist_train.csv",header=FALSE)
train_image.hex[,785] <- factor(train_image.hex[,785])
train_image.hex <- as.h2o(train_image.hex)
test_image.hex <- read.csv("mnist_test.csv",header=FALSE)
test_image.hex[,785] <- factor(test_image.hex[,785])
test_image.hex <- as.h2o(test_image.hex)


mnist_model <- h2o.deeplearning(x=1:784, y = 785,
training_frame= train_image.hex, 
validation_frame = test_image.hex,
activation = "RectifierWithDropout", hidden = c(500,1000),
input_dropout_ratio = 0.2,
hidden_dropout_ratios = c(0.5,0.5), adaptive_rate=TRUE,
rho=0.98, epsilon = 1e-7,
l1 = 1e-8, l2 = 1e-7, max_w2 = 10, 
epochs = 10, export_weights_and_biases = TRUE,
variable_importances = FALSE
)
h2o.saveModel(mnist_model, path="/tmp",force=TRUE)

localh2o感谢您向我们指出这一点。我添加了一个JIRA,您可以在此处跟踪其进度:

你可以期待这个问题很快得到解决

谢谢


Avni

请使用最新版本重试。现在应该可以了。

请提供其他上下文,如版本号、更改日志摘录等。
localh2o <- h2o.init(nthreads = -1)
train_image.hex <- read.csv("mnist_train.csv",header=FALSE)
train_image.hex[,785] <- factor(train_image.hex[,785])
train_image.hex <- as.h2o(train_image.hex)
test_image.hex <- read.csv("mnist_test.csv",header=FALSE)
test_image.hex[,785] <- factor(test_image.hex[,785])
test_image.hex <- as.h2o(test_image.hex)
startmodel <- h2o.loadModel("/tmp/DeepLearning_model_R_1443812402059_20", localh2o)

mnist_model <- h2o.deeplearning(x=1:784, y = 785,
checkpoint = startmodel@model_id,
training_frame= train_image.hex, 
validation_frame = test_image.hex,
activation = "RectifierWithDropout", hidden = c(500,1000),
input_dropout_ratio = 0.2,
hidden_dropout_ratios = c(0.5,0.5), adaptive_rate=TRUE,
rho=0.98, epsilon = 1e-7,
l1 = 1e-8, l2 = 1e-7, max_w2 = 10, 
epochs = 10, export_weights_and_biases = TRUE,
variable_importances = FALSE
)