[论文解读] Improving Neural Network Quantization without Retraining using Outlier Channel Splitting
论文提出 Outlier Channel Splitting (OCS) 在无需重新训练的情况下对浮点 DNN 进行量化,在CNNs和RNNs上对比 clipping 表现更好,硬件开销最小。
Quantization can improve the execution latency and energy efficiency of neural networks on both commodity GPUs and specialized accelerators. The majority of existing literature focuses on training quantized DNNs, while this work examines the less-studied topic of quantizing a floating-point model without (re)training. DNN weights and activations follow a bell-shaped distribution post-training, while practical hardware uses a linear quantization grid. This leads to challenges in dealing with outliers in the distribution. Prior work has addressed this by clipping the outliers or using specialized hardware. In this work, we propose outlier channel splitting (OCS), which duplicates channels containing outliers, then halves the channel values. The network remains functionally identical, but affected outliers are moved toward the center of the distribution. OCS requires no additional training and works on commodity hardware. Experimental evaluation on ImageNet classification and language modeling shows that OCS can outperform state-of-the-art clipping techniques with only minor overhead.
研究动机与目标
- 激励在真实场景部署中无需重新训练的后训练量化。
- 通过重塑数值分布来处理由异常值引起的量化误差。
- 引入 Outlier Channel Splitting (OCS) 作为一个实用、硬件友好的变换。
- 系统地比较 OCS 与 clipping 及其他量化技术在 CNN 和 RNN 模型上的表现。
提出的方法
- 识别每层中绝对值最大的异常通道。
- 复制选定通道,并将通道输出减半或将输出权重减半以保持功能等价性(Net2WiderNet 转换)。
- 应用量化感知(QA)拆分以在拆分时保持量化值。
- 使用扩张比 r 选择每层的拆分数量(每层向上取整 Ceil(r*C))。
- 离线对权重应用 OCS,并插入一个小型运行时层以在普通硬件上处理激活。
- 在 ImageNet CNN 和一个语言模型上,对权重和激活量化进行 OCS 与 clipping 方法(MSE、ACIQ、KL)的比较。
实验结果
研究问题
- RQ1通过通道级异常值操作,后训练量化能否在不重新训练的情况下达到高精度?
- RQ2OCS 在不同位宽下对权重和激活的量化相比 clipping 基于方法如何?
- RQ3应用 OCS 时,模型大小开销与量化精度之间的权衡是什么?
- RQ4对所有位宽而言,量化感知拆分是否有必要以保持精度?
- RQ5OCS 能否有效扩展到基于 RNN 的语言模型,除了 CNN?
主要发现
- OCS 在权重量化方面可以超越最先进的 clipping 方法,且网络扩展适中(小 r)。
- QA 拆分保留量化结果,并在激活/权重场景中优于 naïve 的 Net2WiderNet 拆分。
- 对于激活量化,clipping 一般仍然有效,而 OCS 收益有限,在缺乏动态通道选择时效果较差。
- OCS 与 clipping 结合在极低精度下可以超越任一单独方法。
- 在 ImageNet CNNs 与 WikiText-2 的实验显示,OCS 在无需重新训练的情况下实现改进的后训练量化,且开销可控。
- OCS 内存开销与扩展比 r 紧密相关(权重/激活大约增长为 1+r)。
更好的研究,从现在开始
从论文设计到论文写作,大幅缩短您的研究时间。
无需绑定信用卡
本解读由 AI 生成,并经人工编辑审核。