使用 Vowpal Wabbit 时计算 AUC

编程入门 行业动态 更新时间:2024-10-24 12:28:24
本文介绍了使用 Vowpal Wabbit 时计算 AUC的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

无论如何可以在 Vowpal Wabbit 中计算 AUC 吗?

Is there anyway to compute AUC within Vowpal Wabbit?

我使用 Vowpal Wabbit 的原因之一是数据文件很大.我可以使用 Vowpal Wabbit 的输出计算 Vowpal Wabbit 环境之外的 AUC,但如果数据文件很大,这可能会出现问题.

One of the reasons I am using Vowpal Wabbit is the large size of the data file. I can calculate the AUC outside of the Vowpal Wabbit environment using the output of Vowpal Wabbit but this might be problematic if the data file is large.

推荐答案

目前,大众无法报告 AUC.更糟糕的是,它不能直接针对 AUC 进行优化.优化 AUC 与在线学习不兼容,但有一些适合优化的 AUC 近似值.

Currently, VW cannot report AUC. What is worse, it cannot optimize directly for AUC. Optimizing for AUC is not compatible with online learning, but there are some approximations of AUC suitable for optimizing.

关于您的问题,您不需要将带有原始预测的中间文件存储在磁盘上.您可以将其直接通过管道传输到外部评估工具(在本例中为 perf):

Concerning your question, you don't need to store the intermediate file with raw predictions on disk. You can pipe it directly to the external evaluation tool (perf in this case):

vw -d test.data -t -i model.vw -r /dev/stdout | perf -roc -files gold /dev/stdin

John Langford 确认一般可以通过改变误报和误报的比率来优化 AUC负损失.在大众中,这意味着为正例和负例设置不同的重要性权重.您需要使用保持集(或交叉验证,或一次性学习的渐进验证损失)来调整最佳权重.

John Langford confirmed that AUC can generally be optimized by changing the ratio of false positive and false negative loss. In VW, this means setting a different importance weight for positive and negative examples. You need to tune the optimal weight using a hold out set (or cross validation, or progressive validation loss for one-pass learning).

更多推荐

使用 Vowpal Wabbit 时计算 AUC

本文发布于:2023-10-24 09:38:36,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1523596.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:时计   Vowpal   Wabbit   AUC

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!