paperbot · PL 论文追踪

全部论文 待读 收藏

P2 Balancing Effectiveness and Flakiness of Non-Deterministic Machine Learning Tests

平衡非确定性机器学习测试的有效性与不稳定率
ICSE 2023 IEEE/ACM 45th International Conference on Software Engineering (ICSE)2023匹配度 3/10 · 论文关注机器学习项目中的非确定性测试与断言边界优化,属于 PL/软件工程与 ML 系统交叉,但与用户核心方向(面向 ML/Agentic 程序的静态分析、LLM 改进静态分析/验证、浮点程序分析、贝叶斯程序分析)均无直接交集,也不涉及 LLM/Agent 或形式化验证。引用 5 inbox
Chunqiu Steven Xia, Saikat Dutta, Sasa Misailovic, Darko Marinov, Lingming Zhang
crossref: 2026-09-12dblp: 2026-09-12

AI 速览

一句话:提出 FASER,通过优化断言边界来权衡非确定性机器学习测试的故障检测有效性与不稳定率。

机器学习项目的测试面临算法固有非确定性和缺乏可靠参考结果的问题。开发者通常凭直觉设置测试断言中实际值与期望值的比较边界,并为了避免误报而过于保守,导致遗漏关键缺陷。本文提出 FASER,首个系统性地平衡非确定性测试故障检测有效性与不稳定率的方法,将断言边界的选择建模为两个竞争目标之间的优化问题。FASER 使用统计方法估计不稳定率,并使用变异测试估计故障检测有效性,从而计算最优断言边界。作者在来自 22 个流行机器学习项目的 87 个非确定性测试上评估 FASER,发现其中 23 个测试使用了保守边界,并给出了在限制不稳定率的同时最大化故障检测有效性的更紧断言边界。作者提交了 19 个修复测试的 pull request,其中 14 个已被接受。

问题
非确定性机器学习测试中,开发者难以选择断言边界:过松的边界会遗漏缺陷,过紧的边界则导致不稳定测试失败。
方法
FASER 将断言边界选择形式化为故障检测有效性与不稳定率之间的优化问题,用统计方法估计不稳定率,用变异测试估计故障检测有效性。
评估
在来自 22 个流行机器学习项目的 87 个非确定性测试上进行评估,识别出 23 个保守边界测试并提出更紧边界;向开发者提交 19 个 pull request,其中 14 个被接受。
原文摘要(Abstract)

Testing Machine Learning (ML) projects is challenging due to inherent non-determinism of various ML algorithms and the lack of reliable ways to compute reference results. Developers typically rely on their intuition when writing tests to check whether ML algorithms produce accurate results. However, this approach leads to conservative choices in selecting assertion bounds for comparing actual and expected results in test assertions. Because developers want to avoid false positive failures in tests, they often set the bounds to be too loose, potentially leading to missing critical bugs. We present FASER - the first systematic approach for balancing the trade-off between the fault-detection effectiveness and flakiness of non-deterministic tests by computing optimal assertion bounds. FASER frames this trade-off as an optimization problem between these competing objectives by varying the assertion bound. FASER leverages 1) statistical methods to estimate the flakiness rate, and 2) mutation testing to estimate the fault-detection effectiveness. We evaluate FASER on 87 non-deterministic tests collected from 22 popular ML projects. FASER finds that 23 out of 87 studied tests have conservative bounds and proposes tighter assertion bounds that maximizes the fault-detection effectiveness of the tests while limiting flakiness. We have sent 19 pull requests to developers, each fixing one test, out of which 14 pull requests have already been accepted.

链接与引用

DOI 原文 · DBLP

BibTeX
@inproceedings{XiaDMMZ23,
  title = {Balancing Effectiveness and Flakiness of Non-Deterministic Machine Learning Tests},
  author = {Chunqiu Steven Xia and Saikat Dutta and Sasa Misailovic and Darko Marinov and Lingming Zhang},
  booktitle = {ICSE},
  year = {2023},
  doi = {10.1109/icse48619.2023.00154}
}