
Overfitting diagnostic (Geron Ch 4, morie.fn hmovf)
Source:R/geron_ml2_native.R
morie_geron_overfitting.RdGeneralisation gap E_val - E_train with the early-stopping point.
best_epoch is 0-based, as in Python.
Value
List with gap, gaps, ratio, overfitting,
best_epoch, best_val, epochs_past_best, verdict,
estimate, n.
Examples
V <- c(1, 2, 3, 4, 5, 6, 7, 8)
morie_geron_overfitting(V, V)
#> $gap
#> [1] 0
#>
#> $gaps
#> [1] 0 0 0 0 0 0 0 0
#>
#> $ratio
#> [1] 1
#>
#> $overfitting
#> [1] FALSE
#>
#> $best_epoch
#> [1] 0
#>
#> $best_val
#> [1] 1
#>
#> $epochs_past_best
#> [1] 7
#>
#> $verdict
#> [1] "no overfitting gap: errors agree, so look at their LEVEL for underfitting"
#>
#> $estimate
#> [1] 0
#>
#> $n
#> [1] 8
#>
#> $method
#> [1] "Generalisation gap E_val - E_train with early-stopping point"
#>