Skip to main content
QUICK REVIEW

[论文解读] AutoQ: Automated Kernel-Wise Neural Network Quantization

Qian Lou, Feng Guo|arXiv (Cornell University)|Feb 15, 2019
Advanced Neural Network Applications参考文献 34被引用 22
一句话总结

AutoQ 提出了一种分层深度强化学习(DRL)框架,可自动搜索卷积神经网络中各个权重核与激活层的最优量化位宽(QBN),在保持精度的同时显著降低推理延迟和能耗。通过高层控制器设定目标QBN,低层控制器优化每核量化,AutoQ 相较于最先进DRL方法实现54.06%的延迟降低与50.69%的能耗降低。

ABSTRACT

Network quantization is one of the most hardware friendly techniques to enable the deployment of convolutional neural networks (CNNs) on low-power mobile devices. Recent network quantization techniques quantize each weight kernel in a convolutional layer independently for higher inference accuracy, since the weight kernels in a layer exhibit different variances and hence have different amounts of redundancy. The quantization bitwidth or bit number (QBN) directly decides the inference accuracy, latency, energy and hardware overhead. To effectively reduce the redundancy and accelerate CNN inferences, various weight kernels should be quantized with different QBNs. However, prior works use only one QBN to quantize each convolutional layer or the entire CNN, because the design space of searching a QBN for each weight kernel is too large. The hand-crafted heuristic of the kernel-wise QBN search is so sophisticated that domain experts can obtain only sub-optimal results. It is difficult for even deep reinforcement learning (DRL) Deep Deterministic Policy Gradient (DDPG)-based agents to find a kernel-wise QBN configuration that can achieve reasonable inference accuracy. In this paper, we propose a hierarchical-DRL-based kernel-wise network quantization technique, AutoQ, to automatically search a QBN for each weight kernel, and choose another QBN for each activation layer. Compared to the models quantized by the state-of-the-art DRL-based schemes, on average, the same models quantized by AutoQ reduce the inference latency by 54.06\%, and decrease the inference energy consumption by 50.69\%, while achieving the same inference accuracy.

研究动机与目标

  • 为解决因每核位宽选择的搜索空间过大而导致的核粒度神经网络量化效率低下问题。
  • 克服现有DRL方法在核粒度量化中收敛困难与配置次优的局限性。
  • 通过自动确定每个权重核与激活层的最优QBN,实现在低功耗移动设备上准确、低延迟、低能耗的CNN部署。
  • 通过新颖的外在奖励函数,平衡推理精度、延迟、能耗与FPGA面积之间的权衡。

提出的方法

  • AutoQ 采用分层DRL架构,高层控制器(HLC)为权重核与激活层设定目标平均QBN。
  • 低层控制器(LLC)根据HLC的目标生成每核QBN,实现细粒度的核粒度量化。
  • 引入形状化的内在奖励,通过结合HLC目标达成与外在环境反馈,加速学习过程。
  • 外在奖励函数通过加权系数(ψ_acc=2, ψ_l=0.5, ψ_e=0.5, ψ_a=0.5)平衡推理精度、延迟、能耗与FPGA面积。
  • 该方法在时间域与空间域CNN加速器(包括BitFusion与基于FPGA的系统)上进行评估,以验证硬件效率。

实验结果

研究问题

  • RQ1分层DRL框架能否在保持高推理精度的前提下,有效探索每核量化位宽的巨大搜索空间?
  • RQ2与HIRO或DDPG等标准DRL智能体相比,形状化的内在奖励在多大程度上提升了学习效率?
  • RQ3在时间域与空间域CNN加速器上,核粒度量化能在多大程度上降低推理延迟与能耗?
  • RQ4外在奖励函数在搜索过程中能否有效平衡多种硬件与精度指标?
  • RQ5在基于Systolic阵列的空间加速器上,子核粒度量化是否能带来进一步优势?

主要发现

  • 与最先进DRL方法相比,AutoQ 在平均推理延迟上降低54.06%,能耗降低50.69%,且精度保持不变。
  • 分层DRL方法仅在200个训练周期内即达到约70%的推理精度,显著优于基于DDPG的方法,后者在250个周期前始终停滞在约20%的精度。
  • 在空间CNN加速器(BitFusion)上,与层粒度量化相比,核粒度量化使延迟降低39.04%,能耗降低33.34%。
  • 在Systolic阵列加速器上,子核粒度量化并未提升性能,因为单个核中最大的QBN仍决定硬件资源使用量。
  • 外在奖励使AutoQ能够识别出仅使用85% FPGA面积的QBN配置,优于对比方法所用的94%面积,证明了硬件资源优化的有效性。

更好的研究,从现在开始

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

无需绑定信用卡

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