繁体   English   中英

h2o model 性能提取

[英]h2o model performance extraction

在使用h2o H2ORandomForestEstimator训练了随机森林分类器后,我如何提取 model 不同指标的性能报告?

ModelMetricsBinomial: drf
** Reported on train data. **

MSE: 0.3585693234630144
RMSE: 0.5988065826817658
LogLoss: 1.042047808195111
Mean Per-Class Error: 0.3219540722169749
AUC: 0.7464490458314232
AUCPR: 0.751360355831092
Gini: 0.4928980916628465

Confusion Matrix (Act/Pred) for max f1 @ threshold = 0.06774124943480285: 
False   True    Error   Rate

...

例如,我使用此过程训练了许多不同的模型,并希望比较最终结果,因此最好保存 model_performance 以供以后使用。 我希望保存为:

 {model1 : model_performance_1,
  model2 : model_performance_2, ........}

此外,我如何提取 model 性能值? 例如如何提取混淆矩阵的值,就像提取混淆矩阵本身的值一样? perf.confusion_matrix() return h2o object,但是如何提取呢?

您可以通过调用各自的方法来调用 model 指标。 例如model1.mse()model1.auc()model1.gini()

对于您的第二个问题,尚不清楚您要提取什么。 您可以将其放入列表perf.confusion_matrix().to_list()

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM