ChatPaper.aiChatPaper

I&S-ViT: Een inclusieve en stabiele methode om de grenzen van post-training kwantisatie van ViTs te verleggen

I&S-ViT: An Inclusive & Stable Method for Pushing the Limit of Post-Training ViTs Quantization

November 16, 2023
Auteurs: Yunshan Zhong, Jiawei Hu, Mingbao Lin, Mengzhao Chen, Rongrong Ji
cs.AI

Samenvatting

Hoewel vision transformers (ViTs) schaalbare prestaties bieden, ondermijnen de hoge rekenkosten (training en inferentie) hun positie in industriële toepassingen. Post-training quantisatie (PTQ), waarbij ViTs worden afgestemd met een kleine dataset en uitgevoerd in een laag-bitformaat, lost het kostenprobleem goed op, maar helaas leidt dit tot grotere prestatieverliezen in lagere-bitgevallen. In dit artikel introduceren we I&S-ViT, een nieuwe methode die de PTQ van ViTs op een inclusieve en stabiele manier reguleert. I&S-ViT identificeert eerst twee problemen in de PTQ van ViTs: (1) Quantisatie-inefficiëntie in de veelgebruikte log2-quantisator voor post-Softmax-activaties; (2) Een ruw en versterkt verlieslandschap in grofkorrelige quantisatiegranulariteit voor post-LayerNorm-activaties. Vervolgens lost I&S-ViT deze problemen op door het introduceren van: (1) Een nieuwe shift-uniform-log2-quantisator (SULQ) die een shiftmechanisme combineert met uniforme quantisatie om zowel een inclusieve domeinrepresentatie als een nauwkeurige distributiebenadering te bereiken; (2) Een drietraps gladde optimalisatiestrategie (SOS) die de sterke punten van kanaalsgewijze en laagsgewijze quantisatie combineert om stabiel leren mogelijk te maken. Uitgebreide evaluaties over diverse visietaken valideren de superioriteit van I&S-ViT ten opzichte van bestaande PTQ-methoden voor ViTs, met name in lage-bit-scenario's. Zo verbetert I&S-ViT de prestaties van een 3-bit ViT-B met indrukwekkende 50,68%.
English
Albeit the scalable performance of vision transformers (ViTs), the dense computational costs (training & inference) undermine their position in industrial applications. Post-training quantization (PTQ), tuning ViTs with a tiny dataset and running in a low-bit format, well addresses the cost issue but unluckily bears more performance drops in lower-bit cases. In this paper, we introduce I&S-ViT, a novel method that regulates the PTQ of ViTs in an inclusive and stable fashion. I&S-ViT first identifies two issues in the PTQ of ViTs: (1) Quantization inefficiency in the prevalent log2 quantizer for post-Softmax activations; (2) Rugged and magnified loss landscape in coarse-grained quantization granularity for post-LayerNorm activations. Then, I&S-ViT addresses these issues by introducing: (1) A novel shift-uniform-log2 quantizer (SULQ) that incorporates a shift mechanism followed by uniform quantization to achieve both an inclusive domain representation and accurate distribution approximation; (2) A three-stage smooth optimization strategy (SOS) that amalgamates the strengths of channel-wise and layer-wise quantization to enable stable learning. Comprehensive evaluations across diverse vision tasks validate I&S-ViT' superiority over existing PTQ of ViTs methods, particularly in low-bit scenarios. For instance, I&S-ViT elevates the performance of 3-bit ViT-B by an impressive 50.68%.
PDF100December 15, 2024