TernaryBERT: Distillation-aware Ultra-low Bit BERT
Wei Zhang, Lu Hou, Yichun Yin, Lifeng Shang, Xiao Chen, Xin Jiang, Qun Liu
摘要
Transformer-based pre-training models like BERT have achieved remarkable performance in many natural language processing tasks. However, these models are both computation and memory expensive, hindering their deployment to resource-constrained devices. In this work, we propose TernaryBERT, which ternarizes the weights in a fine-tuned BERT model. Specifically, we use both approximation-based and loss-aware ternarization methods and empirically investigate the ternarization granularity of different parts of BERT. Moreover, to reduce the accuracy degradation caused by the lower capacity of low bits, we leverage the knowledge distillation technique (Jiao et al., 2019) in the training process. Experiments on the GLUE benchmark and SQuAD show that our proposed TernaryBERT outperforms the other BERT quantization methods, and even achieves comparable performance as the fullprecision model while being 14.9x smaller.
问 Lune
几分钟读透这篇 Paper,不用再花一下午。
Lune 能读完全文,也能读引用它的顶会 Paper,讲清它的结论、证据和局限,每一点都注明出自哪篇 Paper。不用硬啃,也不靠猜。
已有 64 篇顶会 Paper 引用了它。别等审稿人问起,先弄清它们发现了什么。
脉络
- TinyBERT: Distilling BERT for Natural Language Understanding 引用了 ALBERT: A Lite BERT for Self-supervised Learning of Language Representations
- TinyBERT: Distilling BERT for Natural Language Understanding 引用了 MiniLM: Deep Self-Attention Distillation for Task-Agnostic Compression of Pre-Trained Transformers
- TinyBERT: Distilling BERT for Natural Language Understanding 引用了 Q-BERT: Hessian Based Ultra Low Precision Quantization of BERT
- TinyBERT: Distilling BERT for Natural Language Understanding 引用了 Reducing Transformer Depth on Demand with Structured Dropout
- ZeroQuant: Efficient and Affordable Post-Training Quantization for Large-Scale Transformers 引用了 ALBERT: A Lite BERT for Self-supervised Learning of Language Representations
- ZeroQuant: Efficient and Affordable Post-Training Quantization for Large-Scale Transformers 引用了 Post-Training Quantization for Vision Transformer
- ZeroQuant: Efficient and Affordable Post-Training Quantization for Large-Scale Transformers 引用了 Q-BERT: Hessian Based Ultra Low Precision Quantization of BERT
- ZeroQuant: Efficient and Affordable Post-Training Quantization for Large-Scale Transformers 引用了 Reducing Transformer Depth on Demand with Structured Dropout
- Post-Training Quantization for Vision Transformer 引用了 Q-BERT: Hessian Based Ultra Low Precision Quantization of BERT
- DuQuant: Distributing Outliers via Dual Transformation Makes Stronger Quantized LLMs 引用了 ZeroQuant: Efficient and Affordable Post-Training Quantization for Large-Scale Transformers
- Outlier Suppression: Pushing the Limit of Low-bit Transformer Language Models 引用了 Q-BERT: Hessian Based Ultra Low Precision Quantization of BERT
引用它的顶会 Paper64
- GPT3.int8(): 8-bit Matrix Multiplication for Transformers at ScaleTim Dettmers, Mike Lewis, Younes Belkada, Luke ZettlemoyerNeurIPS 2022 · 1,012 次引用
- ZeroQuant: Efficient and Affordable Post-Training Quantization for Large-Scale TransformersZhewei Yao, Reza Yazdani Aminabadi, Minjia Zhang, Xiaoxia Wu 等NeurIPS 2022 · 816 次引用
- Post-Training Quantization for Vision TransformerZhenhua Liu, Yunhe Wang, Kai Han, Wei Zhang 等NeurIPS 2021 · 528 次引用
- Outlier Suppression: Pushing the Limit of Low-bit Transformer Language ModelsXiuying Wei, Yunchen Zhang, Xiangguo Zhang, Ruihao Gong 等NeurIPS 2022 · 238 次引用
- DuQuant: Distributing Outliers via Dual Transformation Makes Stronger Quantized LLMsHaokun Lin, Haobo Xu, Yichen Wu, Jingzhi Cui 等NeurIPS 2024 · 206 次引用
它引用的 Paper10
- ALBERT: A Lite BERT for Self-supervised Learning of Language RepresentationsZhenzhong Lan, Mingda Chen, Sebastian Goodman, Kevin Gimpel 等ICLR 2020 · 7,418 次引用
- MiniLM: Deep Self-Attention Distillation for Task-Agnostic Compression of Pre-Trained TransformersWenhui Wang, Furu Wei, Li Dong, Hangbo Bao 等NeurIPS 2020 · 2,727 次引用
- TinyBERT: Distilling BERT for Natural Language UnderstandingXiaoqi Jiao, Yichun Yin, Lifeng Shang, Xin Jiang 等EMNLP Findings 2020 · 1,787 次引用
- Reducing Transformer Depth on Demand with Structured DropoutAngela Fan, Edouard Grave, Armand JoulinICLR 2020 · 695 次引用
- Q-BERT: Hessian Based Ultra Low Precision Quantization of BERTSheng Shen, Zhen Dong, Jiayu Ye, Linjian Ma 等AAAI 2020 · 656 次引用
相关 Paper
- BinaryBERT: Pushing the Limit of BERT QuantizationHaoli Bai, Wei Zhang, Lu Hou, Lifeng Shang 等ACL 2021
- Partially-Random Initialization: A Smoking Gun for Binarization Hypothesis of BERTArash ArdakaniEMNLP Findings 2022 · 1 次引用
- BiBERT: Accurate Fully Binarized BERTHaotong Qin, Yifu Ding, Mingyuan Zhang, Qinghua Yan 等ICLR 2022 · 121 次引用
- Understanding and Overcoming the Challenges of Efficient Transformer QuantizationYelysei Bondarenko, Markus Nagel, Tijmen BlankevoortEMNLP 2021 · 74 次引用
- XTC: Extreme Compression for Pre-trained Transformers Made Simple and EfficientXiaoxia Wu, Zhewei Yao, Minjia Zhang, Conglong Li 等NeurIPS 2022 · 1 次引用
