How do you know how many deep academic eras have been done, from R?

Early stop is enabled by default for h2o.deeplearning(). But, from R, how do I know if it really was before, and how many eras he made? I tried this:

model = h2o.deeplearning(...) print(model)

which tells me information about layers, MSE, R2, etc., but nothing about how many eras have been completed.

Over on flow. I can see the information (for example, where the x axis stops in the table "Scoring History - Deviance" or in the table "Counting History").

+4
source share
2 answers

If your model is called m, then to get the total number of passed eras:last(m@model$scoring_history$epochs)

, ( , Flow) , str(m)

: summary(m) , print(m), ( ):

Scoring History: 
            timestamp   duration training_speed    epochs iterations       samples training_MSE training_deviance training_r2
1 2016-04-14 11:35:46  0.000 sec                  0.00000          0      0.000000
2 2016-04-14 11:35:52  5.218 sec 15139 rows/sec  10.00000          1  77150.000000      0.00000           0.00000     0.07884
...
7 2016-04-14 11:36:18 31.346 sec 25056 rows/sec 100.00000         10 771500.000000      0.00000           0.00000     0.72245

.. , .

BTW, h2o summary() ; R .

+3

, , overwrite_with_best_model=FALSE. , TRUE, , . , , h2o.grid m@model$scoring_history, .

epochs     validation_classification_error
0.00000    0.46562
1.43150    0.50000
100.31780  0.46562

, overwrite_with_best_model=TRUE, , . , , :

epochsList = m@model$scoring_history$epochs
bestEpochIndex = which.min(m@model$scoring_history$validation_classification_error)
bestEpoch = epochsList[bestEpochIndex]
print(sprintf("The best epoch is: %d", bestEpoch))
+2

All Articles