Skip to main content
QUICK REVIEW

[论文解读] DeepDiagnosis: Automatically Diagnosing Faults and Recommending Actionable Fixes in Deep Learning Programs

Mohammad Wardat, Breno Dantas Cruz|arXiv (Cornell University)|Dec 7, 2021
Software Engineering Research被引用 7
一句话总结

DeepDiagnosis 是一种动态分析框架,通过监控关键错误症状,能够在训练过程中自动检测、定位并诊断深度学习模型中的八类结构性错误。它在故障定位准确性和效率方面优于最先进的工具 UMLUAT 和 DeepLocalize,同时支持更广泛的模型类型,并能检测数值错误以外的非数值症状。

ABSTRACT

Deep Neural Networks (DNNs) are used in a wide variety of applications. However, as in any software application, DNN-based apps are afflicted with bugs. Previous work observed that DNN bug fix patterns are different from traditional bug fix patterns. Furthermore, those buggy models are non-trivial to diagnose and fix due to inexplicit errors with several options to fix them. To support developers in locating and fixing bugs, we propose DeepDiagnosis, a novel debugging approach that localizes the faults, reports error symptoms and suggests fixes for DNN programs. In the first phase, our technique monitors a training model, periodically checking for eight types of error conditions. Then, in case of problems, it reports messages containing sufficient information to perform actionable repairs to the model. In the evaluation, we thoroughly examine 444 models -53 real-world from GitHub and Stack Overflow, and 391 curated by AUTOTRAINER. DeepDiagnosis provides superior accuracy when compared to UMLUAT and DeepLocalize. Our technique is faster than AUTOTRAINER for fault localization. The results show that our approach can support additional types of models, while state-of-the-art was only able to handle classification ones. Our technique was able to report bugs that do not manifest as numerical errors during training. Also, it can provide actionable insights for fix whereas DeepLocalize can only report faults that lead to numerical errors during training. DeepDiagnosis manifests the best capabilities of fault detection, bug localization, and symptoms identification when compared to other approaches.

研究动机与目标

  • 为解决深度学习模型中不表现为数值错误的结构性错误诊断挑战。
  • 开发一种动态分析方法,识别超出数值异常的多种错误症状。
  • 为诊断出的故障提供可操作的、人类可读的修复建议,降低非专家的调试负担。
  • 支持比以往最先进工具更广泛的 DNN 架构,而不仅限于分类模型。
  • 创建一个公开可用的基准,包含 444 个真实且精心整理的有缺陷模型,用于评估未来故障定位与调试工具。

提出的方法

  • DeepDiagnosis 在 DNN 训练过程中执行动态监控,定期检查八种预定义的错误症状。
  • 通过分析中间层输出和训练指标,检测诸如梯度消失、梯度爆炸以及权重不变等症状。
  • 利用基于规则的系统和决策树将检测到的症状映射到根本原因,以缩小解决方案的搜索空间。
  • 生成人类可读的诊断信息,包含根本原因分析和开发人员可执行的修复建议。
  • 该方法作为深度学习框架的插件实现,无缝集成到训练循环中,无需重新训练模型。
  • 支持分类与非分类模型,扩展了以往工具(如 AUTOTRAINER)仅限于分类模型的局限。

实验结果

研究问题

  • RQ1动态分析方法能否检测在训练过程中不产生数值错误的 DNN 中的结构性错误?
  • RQ2与最先进工具(如 UMLUAT 和 DeepLocalize)相比,DeepDiagnosis 在故障定位方面的有效性如何?
  • RQ3DeepDiagnosis 能否为诊断出的故障提供可操作的修复建议?其建议质量与自动化修复工具(如 AUTOTRAINER)相比如何?
  • RQ4DeepDiagnosis 在不同 DNN 架构上的泛化能力如何,是否超越了分类模型?
  • RQ5与 AUTOTRAINER 相比,DeepDiagnosis 在故障定位和症状检测方面的性能与效率如何?

主要发现

  • 在 444 个模型的数据集中,DeepDiagnosis 的故障定位准确率优于 UMLUAT 和 DeepLocalize。
  • 其故障定位速度优于 AUTOTRAINER,同时保持更高的诊断精确度。
  • 该框架成功检测到非数值症状,如权重不变和准确率停滞,这些症状被先前工具所忽略。
  • DeepDiagnosis 为 8 种不同类型的结构性错误提供了可操作的修复建议,包括学习率和优化器配置错误。
  • 该方法展现出更广泛的模型兼容性,支持非分类模型,而最先进工具仅限于分类模型。
  • 作者发布了包含 444 个有缺陷模型及其解决方案的公开基准,支持未来调试工具的可复现评估。

更好的研究,从现在开始

从阅读论文到最终审阅,大幅缩短您的研究时间。

无需绑定信用卡

本解读由 AI 生成,并经人工编辑审核。