一句话:提出四阶段深度学习框架转换故障定位与修复方法,在 TVM 上修复权重精度错误,使转换误差归零。
深度神经网络部署时,开发者常将模型从一个深度学习框架转换到另一个框架,但该过程容易出错并损害目标模型准确率。本文先对 MobileNetV2、ResNet101 和 InceptionV3 在 PyTorch、Keras、TensorFlow 与 TFLite 间的转换进行差分分析,发现大量模型崩溃及最高 72% 的输出标签差异。为缓解此类错误,作者提出一种面向预训练图像识别模型的深度学习框架转换故障定位与修复方法,包含转换工具、模型参数、模型超参数和图表示四个分析阶段,并提出相应修复策略。该方法实现于 Apache TVM 深度学习编译器之上,并以 InceptionV3 从 TF 到 TFLite 的转换进行初步故障定位验证。结果发现一个常见 DNN 转换工具引入权重精度误差、降低模型准确率;修复该问题后转换误差降至零。
When deploying Deep Neural Networks (DNNs), developers often convert models from one deep learning framework to another (e.g., TensorFlow to PyTorch). However, this process is error-prone and can impact target model accuracy. To identify the extent of such impact, we perform and briefly present a differential analysis against three DNNs widely used for image recognition (MobileNetV2, ResNet101, and InceptionV3)converted across four well-known deep learning frameworks (PyTorch, Keras, TensorFlow (TF), and TFLite), which revealed numerous model crashes and output label discrepancies of up to 72%. To mitigate such errors, we present a novel approach towards fault localization and repair of buggy deep learning framework conversions, focusing on pre-trained image recognition models. Our technique consists of four stages of analysis: 1) conversion tools, 2) model parameters, 3) model hyperparameters, and 4) graph representation. In addition, we propose various strategies towards fault repair of the faults detected. We implement our technique on top of the Apache TVM deep learning compiler, and we test it by conducting a preliminary fault localization analysis for the conversion of InceptionV3 from TF to TFLite. Our approach detected a fault in a common DNN converter tool, which introduced precision errors in weights, reducing model accuracy. After our fault localization, we repaired the issue, reducing our conversion error to zero.
DOI 原文 · arXiv · PDF(开放获取) · DBLP
@inproceedings{LouloudakisGCR23,
title = {Fault Localization for Buggy Deep Learning Framework Conversions in Image Recognition},
author = {Nikolaos Louloudakis and Perry Gibson and José Cano and Ajitha Rajan},
booktitle = {ASE},
year = {2023},
doi = {10.1109/ase56229.2023.00147}
}