Skip to main content
QUICK REVIEW

[论文解读] AUSN: Approximately Uniform Quantization by Adaptively Superimposing Non-uniform Distribution for Deep Neural Networks

Fangxin Liu, Wenbo Zhao|arXiv (Cornell University)|Jul 8, 2020
Image and Signal Denoising Methods参考文献 31被引用 4
一句话总结

AUSN 提出了一种新颖的量化框架,通过自适应叠加非均匀量化值来近似均匀量化,从而在无需微调的情况下实现高精度、低比特宽度的深度神经网络(DNN)推理。该方法通过消除解码器并采用移位-累加操作,使FPGA的能耗降低2倍,LUT/FF资源减少达4.4倍,同时在图像、语音和目标检测任务中保持了最先进水平的精度,比特宽度为4–5位。

ABSTRACT

Quantization is essential to simplify DNN inference in edge applications. Existing uniform and non-uniform quantization methods, however, exhibit an inherent conflict between the representing range and representing resolution, and thereby result in either underutilized bit-width or significant accuracy drop. Moreover, these methods encounter three drawbacks: i) the absence of a quantitative metric for in-depth analysis of the source of the quantization errors; ii) the limited focus on the image classification tasks based on CNNs; iii) the unawareness of the real hardware and energy consumption reduced by lowering the bit-width. In this paper, we first define two quantitative metrics, i.e., the Clipping Error and rounding error, to analyze the quantization error distribution. We observe that the boundary- and rounding- errors vary significantly across layers, models and tasks. Consequently, we propose a novel quantization method to quantize the weight and activation. The key idea is to Approximate the Uniform quantization by Adaptively Superposing multiple Non-uniform quantized values, namely AUSN. AUSN is consist of a decoder-free coding scheme that efficiently exploits the bit-width to its extreme, a superposition quantization algorithm that can adapt the coding scheme to different DNN layers, models and tasks without extra hardware design effort, and a rounding scheme that can eliminate the well-known bit-width overflow and re-quantization issues. Theoretical analysis~(see Appendix A) and accuracy evaluation on various DNN models of different tasks show the effectiveness and generalization of AUSN. The synthesis~(see Appendix B) results on FPGA show $2 imes$ reduction of the energy consumption, and $2 imes$ to $4 imes$ reduction of the hardware resource.

研究动机与目标

  • 为解决低比特量化中表示范围与分辨率之间的固有权衡问题,该问题常导致精度下降或比特宽度未被充分利用。
  • 开发一种适用于多种DNN任务(如图像分类、语音识别和目标检测)的统一量化框架,超越卷积神经网络(CNNs)的限制。
  • 通过设计无解码器、基于移位-累加的编码方案,消除解码器开销,降低边缘加速器的硬件成本与能耗。
  • 通过裁剪误差和舍入误差的定量分析,实现每层自适应的比特分配。
  • 为加速器设计建立量化比特宽度与真实硬件/能效效率之间的原则性关联。

提出的方法

  • AUSN 将比特宽度分解为符号部分和数据部分,其中数据部分进一步划分为‘基础’和‘细分’两部分,以分别控制表示范围和分辨率。
  • 通过叠加多个非均匀量化值来近似均匀量化,实现在不同层和模型间灵活且自适应的表示。
  • 采用无解码器的编码方案,将乘法运算替换为移位与加法操作,显著降低硬件复杂度与能耗。
  • 设计了自适应比特分配方案,根据每层权重分布动态重分配比特宽度,以最小化裁剪与舍入误差。
  • 提出一种新型舍入方案,通过确保推理过程中精度的一致性,防止比特宽度溢出和重新量化开销。
  • 该方法无需微调即可应用于权重和激活值,支持在多种模型和任务中实现4–5比特量化。

实验结果

研究问题

  • RQ1如何在不牺牲精度或效率的前提下,平衡低比特量化中的表示范围与分辨率?
  • RQ2现有方法中量化误差的主要来源是什么?如何实现其定量分析与缓解?
  • RQ3能否设计一种统一的量化框架,使其在无需微调的情况下泛化于图像、语音和目标检测任务?
  • RQ4如何在保持高精度表示的同时消除低比特DNN推理中的解码器开销?
  • RQ5低比特量化的真实硬件与能耗成本是什么?如何通过算法设计实现最小化?

主要发现

  • AUSN 在图像分类(如CIFAR-10上top-1准确率达93.15%)、语音识别(Speech Commands数据集上准确率达93.17%)和目标检测(COCO数据集上mAP达31.6%)任务中,均实现了4比特和5比特量化下的最先进精度,且精度下降小于0.5%。
  • 在FPGA上,与基线8比特实现相比,AUSN将能耗降低1.9倍,LUT减少2.0倍,FF减少4.4倍。
  • 该方法消除了对解码器的需求,仅通过移位与加法操作即可实现硬件友好的计算,显著降低DSP使用量与逻辑资源开销。
  • 自适应叠加方案根据每层特有的误差特性动态分配比特宽度,使top-1精度的裁剪与舍入误差降低最多达0.47%。
  • 理论分析表明,AUSN 最小化了信息损失,并为量化精度与硬件效率之间提供了原则性的权衡。
  • AUSN 在无需微调或任务特定适配的情况下,成功泛化于多种模型与任务,包括YOLOv3-tiny、CRNNs和TDNNs。

更好的研究,从现在开始

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

无需绑定信用卡

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