arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2407.05266cs.CVcs.AIeess.IV
收藏

CLAMP-ViT:面向 ViT 自适应训练后量化的对比无数据学习

CLAMP-ViT: Contrastive Data-Free Learning for Adaptive Post-Training Quantization of ViTs

Georgia Institute of Technology(佐治亚理工学院);Intel Labs(英特尔实验室)

Akshat Ramachandran, Souvik Kundu, Tushar Krishna

AI总结:

本文提出无数据训练后量化方法 CLAMP-ViT,通过图像块级对比数据生成与逐层进化搜索,提升 ViT 在分类、检测和分割任务中的量化性能。

摘要:

我们提出 CLAMP-ViT,这是一种用于视觉 Transformer(ViT)的无数据训练后量化方法。我们指出了近期技术的局限性,尤其是它们无法利用有意义的图像块间关系,导致生成的数据过于简单且语义模糊,从而影响量化精度。CLAMP-ViT 采用两阶段方法,在数据生成与模型量化之间循环自适应。具体而言,我们引入图像块级对比学习方案,以生成更丰富、具有语义意义的数据。此外,我们在面向固定精度和混合精度量化的逐层进化搜索中利用对比学习,以识别最优量化参数,同时缓解非平滑损失曲面的影响。跨多种视觉任务的广泛评估证明了 CLAMP-ViT 的优越性:在与现有替代方法相似或更优的压缩率下,分类任务 top-1 准确率最高提升 3%,目标检测提升 0.6 mAP,分割任务提升 1.5 mIoU。代码可在 https://github.com/georgia-tech-synergy-lab/CLAMP-ViT.git 获取。

英文摘要:

We present CLAMP-ViT, a data-free post-training quantization method for vision transformers (ViTs). We identify the limitations of recent techniques, notably their inability to leverage meaningful inter-patch relationships, leading to the generation of simplistic and semantically vague data, impacting quantization accuracy. CLAMP-ViT employs a two-stage approach, cyclically adapting between data generation and model quantization. Specifically, we incorporate a patch-level contrastive learning scheme to generate richer, semantically meaningful data. Furthermore, we leverage contrastive learning in layer-wise evolutionary search for fixed- and mixed-precision quantization to identify optimal quantization parameters while mitigating the effects of a non-smooth loss landscape. Extensive evaluations across various vision tasks demonstrate the superiority of CLAMP-ViT, with performance improvements of up to 3% in top-1 accuracy for classification, 0.6 mAP for object detection, and 1.5 mIoU for segmentation at similar or better compression ratio over existing alternatives. Code is available at https://github.com/georgia-tech-synergy-lab/CLAMP-ViT.git

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

↑