SYQ:学习对称Quantization以实现高效的深度神经网络
SYQ: Learning Symmetric Quantization For Efficient Deep Neural Networks
摘要:
最先进的深度神经网络的推理在计算上是昂贵的,使得它们难以在受限的硬件环境中部署。降低这种复杂性的有效方法是通过用有限的条目码本近似它们的分布来在训练期间对权重参数和/或激活进行量化。对于非常低的精度,例如具有1-8位激活的二进制或三进制网络,由于前向和后向函数之间的大梯度失配,量化的信息丢失导致显著的精度降低。在本文中,我们介绍了一种量化方法,以减少这种损失,通过学习一个对称的码本特定的权重子群。这些子组是基于它们在权重矩阵中的位置来确定的,使得低精度表示的硬件简单性得以保留。从经验上讲,我们表明对称量化可以大大提高具有极低精度权重和激活的网络的准确性。我们还表明,这种表示施加最小或没有硬件的影响,更粗粒度的方法。源代码可在https://www.github.com/julianfaraone/SYQ上获得。
英文摘要:
Inference for state-of-the-art deep neural networks is computationally expensive, making them difficult to deploy on constrained hardware environments. An efficient way to reduce this complexity is to quantize the weight parameters and/or activations during training by approximating their distributions with a limited entry codebook. For very low-precisions, such as binary or ternary networks with 1-8-bit activations, the information loss from quantization leads to significant accuracy degradation due to large gradient mismatches between the forward and backward functions. In this paper, we introduce a quantization method to reduce this loss by learning a symmetric codebook for particular weight subgroups. These subgroups are determined based on their locality in the weight matrix, such that the hardware simplicity of the low-precision representations is preserved. Empirically, we show that symmetric quantization can substantially improve accuracy for networks with extremely low-precision weights and activations. We also demonstrate that this representation imposes minimal or no hardware implications to more coarse-grained approaches. Source code is available at https://www.github.com/julianfaraone/SYQ.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。