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

通过一次性权重耦合学习实现无需重训练的模型量化

Retraining-free Model Quantization via One-Shot Weight-Coupling Learning

Tsinghua University(清华大学);The Chinese University of Hong Kong(香港中文大学)

Chen Tang, Yuan Meng, Jiacheng Jiang, Shuzhao Xie, Rongwei Lu, Xinzhu Ma, Zhi Wang, Wenwu Zhu

AI总结:

针对混合精度量化搜索后需重训练的问题,提出一次性权重耦合学习范式,通过位宽调度与信息失真缓解消除位宽干扰,并以仅推理贪心搜索获得高性能压缩配置。

摘要:

量化对于压缩过度参数化的深度神经模型并将其部署到资源受限设备上具有重要意义。固定精度量化由于数值表示能力有限而遭遇性能下降。相反,混合精度量化(MPQ)受到推崇,它通过为各层分配异构位宽来有效压缩模型。MPQ通常被组织为搜索-重训练两阶段流程。本文中,我们设计了一种用于混合精度模型压缩的一次性训练-搜索范式。具体而言,在第一阶段,所有潜在位宽配置被耦合,从而在一组共享权重内同时优化。然而,我们的观察揭示了优化期间高度耦合权重之间存在一种此前未见且严重的位宽干扰现象,在高压缩率下导致显著性能退化。为解决该问题,我们首先设计了位宽调度器,在训练期间动态冻结各层最不稳定的位宽,以确保其余位宽适当收敛。随后,受信息论启发,我们提出信息失真缓解技术,将表现不佳的位宽行为与表现良好的位宽对齐。在第二阶段,设计了仅推理的贪心搜索方案,用于评估配置优劣而不引入任何额外训练成本。在三个代表性模型和三个数据集上的大量实验证明了所提方法的有效性。代码可在 https://github.com/1hunters/re免训练-quantization 获取。

英文摘要:

Quantization is of significance for compressing the over-parameterized deep neural models and deploying them on resource-limited devices. Fixed-precision quantization suffers from performance drop due to the limited numerical representation ability. Conversely, mixed-precision quantization (MPQ) is advocated to compress the model effectively by allocating heterogeneous bit-width for layers. MPQ is typically organized into a searching-retraining two-stage process. In this paper, we devise a one-shot training-searching paradigm for mixed-precision model compression. Specifically, in the first stage, all potential bit-width configurations are coupled and thus optimized simultaneously within a set of shared weights. However, our observations reveal a previously unseen and severe bit-width interference phenomenon among highly coupled weights during optimization, leading to considerable performance degradation under a high compression ratio. To tackle this problem, we first design a bit-width scheduler to dynamically freeze the most turbulent bit-width of layers during training, to ensure the rest bit-widths converged properly. Then, taking inspiration from information theory, we present an information distortion mitigation technique to align the behavior of the bad-performing bit-widths to the well-performing ones. In the second stage, an inference-only greedy search scheme is devised to evaluate the goodness of configurations without introducing any additional training costs. Extensive experiments on three representative models and three datasets demonstrate the effectiveness of the proposed method. Code can be available on \href{https://www.github.com/1hunters/retraining-free-quantization}{https://github.com/1hunters/retraining-free-quantization}.

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

↑