arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2205.15437cs.LG
收藏

AMED:面向边缘设备的自动混合精度量化

AMED: Automatic Mixed-Precision Quantization for Edge Devices

Technion IIT(以色列理工学院)

Moshe Kimhi, Tal Rozen, Avi Mendelson, Chaim Baskin

AI总结:

AMED 将混合精度量化建模为马尔可夫决策过程,在训练中动态搜索最优位宽分配,从而在边缘设备上同时优化模型准确性与硬件效率。

摘要:

量化神经网络以在不大幅损害性能的情况下降低延迟、功耗和模型大小而闻名。这使得它们非常适合资源有限和低功耗容量的系统。混合精度量化能够更好地利用支持不同位宽算术运算的定制硬件。量化方法要么旨在在给定期望缩减量下最小化压缩损失,要么针对模型的特定属性(如 FLOPs 或模型大小)优化一个因变量;这两种方法在部署到特定硬件上时都会导致性能效率低下,但更重要的是,量化方法假设损失流形对于量化模型存在一个全局最小值,该最小值与全精度对应模型的全局最小值相对应。我们挑战这一假设,认为最优最小值会随着精度的变化而变化,因此,更好的做法是将量化视为一个随机过程,这为一种不同的神经网络量化方法奠定了基础。该方法在训练过程中将模型量化到不同精度,将比特分配视为马尔可夫决策过程,然后通过来自特定硬件架构的直接信号,找到用于测量特定设备上指定行为的最优位宽分配。通过这样做,我们避免了损失对于量化模型表现相同这一基本假设。面向边缘设备的自动混合精度量化(简称 AMED)在神经网络准确性与硬件效率之间的权衡方面展示了其相对于当前最先进方案的优越性,并得到了全面评估的支持。

英文摘要:

Quantized neural networks are well known for reducing the latency, power consumption, and model size without significant harm to the performance. This makes them highly appropriate for systems with limited resources and low power capacity. Mixed-precision quantization offers better utilization of customized hardware that supports arithmetic operations at different bitwidths. Quantization methods either aim to minimize the compression loss given a desired reduction or optimize a dependent variable for a specified property of the model (such as FLOPs or model size); both make the performance inefficient when deployed on specific hardware, but more importantly, quantization methods assume that the loss manifold holds a global minimum for a quantized model that copes with the global minimum of the full precision counterpart. Challenging this assumption, we argue that the optimal minimum changes as the precision changes, and thus, it is better to look at quantization as a random process, placing the foundation for a different approach to quantize neural networks, which, during the training procedure, quantizes the model to a different precision, looks at the bit allocation as a Markov Decision Process, and then, finds an optimal bitwidth allocation for measuring specified behaviors on a specific device via direct signals from the particular hardware architecture. By doing so, we avoid the basic assumption that the loss behaves the same way for a quantized model. Automatic Mixed-Precision Quantization for Edge Devices (dubbed AMED) demonstrates its superiority over current state-of-the-art schemes in terms of the trade-off between neural network accuracy and hardware efficiency, backed by a comprehensive evaluation.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑