无论如何可以在 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/stdinJohn 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
发布评论