从损失景观中学习:通过自适应锐度感知梯度对齐实现可泛化的混合精度量化
Learning from Loss Landscape: Generalizable Mixed-Precision Quantization via Adaptive Sharpness-Aware Gradient Aligning
AI总结:
针对现有混合精度量化方法需在大规模数据集上高成本搜索策略的问题,提出结合锐度感知最小化、隐式梯度对齐与自适应扰动半径的新方法,仅用小数据集搜索策略即可泛化到大规模数据集,大幅降低成本并提升效率。
摘要:
混合精度量化(Mixed Precision Quantization, MPQ)已成为通过为每层确定最优位宽来优化神经网络的关键技术。然而,现有MPQ方法面临一大障碍:它们需要在大规模数据集上进行计算成本高昂的量化策略搜索。为解决这一问题,我们提出了一种新方法:先在小数据集上搜索量化策略,再将其泛化到大规模数据集。该方法简化了流程,无需进行大规模量化微调,仅需调整模型权重。我们的方法包含三项核心技术:用于提升量化泛化性的锐度感知最小化、用于处理不同优化目标间梯度冲突的隐式梯度方向对齐,以及用于加速优化的自适应扰动半径。理论分析与实验结果均验证了我们方法的有效性。使用仅为ImageNet训练数据规模0.5%的CIFAR10数据集进行MPQ策略搜索,我们在ImageNet上取得了相当的准确率,且计算成本显著降低,效率相比基线方法最高提升150%。
英文摘要:
Mixed Precision Quantization (MPQ) has become an essential technique for optimizing neural network by determining the optimal bitwidth per layer. Existing MPQ methods, however, face a major hurdle: they require a computationally expensive search for quantization policies on large-scale datasets. To resolve this issue, we introduce a novel approach that first searches for quantization policies on small datasets and then generalizes them to large-scale datasets. This approach simplifies the process, eliminating the need for large-scale quantization fine-tuning and only necessitating model weight adjustment. Our method is characterized by three key techniques: sharpness-aware minimization for enhanced quantization generalization, implicit gradient direction alignment to handle gradient conflicts among different optimization objectives, and an adaptive perturbation radius to accelerate optimization. Both theoretical analysis and experimental results validate our approach. Using the CIFAR10 dataset (just 0.5\% the size of ImageNet training data) for MPQ policy search, we achieved equivalent accuracy on ImageNet with a significantly lower computational cost, while improving efficiency by up to 150% over the baselines.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。