Lune

ICLR2022Top-tier venue

BiBERT: Accurate Fully Binarized BERT

Haotong Qin, Yifu Ding, Mingyuan Zhang, Qinghua Yan, Aishan Liu, Qingqing Dang, Ziwei Liu, Xianglong Liu

Abstract

The large pre-trained BERT has achieved remarkable performance on Natural Language Processing (NLP) tasks but is also computation and memory expensive. As one of the powerful compression approaches, binarization extremely reduces the computation and memory consumption by utilizing 1-bit parameters and bitwise operations. Unfortunately, the full binarization of BERT (i.e., 1-bit weight, embedding, and activation) usually suffer a significant performance drop, and there is rare study addressing this problem. In this paper, with the theoretical justification and empirical analysis, we identify that the severe performance drop can be mainly attributed to the information degradation and optimization direction mismatch respectively in the forward and backward propagation, and propose BiBERT, an accurate fully binarized BERT, to eliminate the performance bottlenecks. Specifically, BiBERT introduces an efficient Bi-Attention structure for maximizing representation information statistically and a Direction-Matching Distillation (DMD) scheme to optimize the full binarized BERT accurately. Extensive experiments show that BiBERT outperforms both the straightforward baseline and existing state-of-the-art quantized BERTs with ultra-low bit activations by convincing margins on the NLP benchmark. As the first fully binarized BERT, our method yields impressive 56.3 times and 31.2 times saving on FLOPs and model size, demonstrating the vast advantages and potential of the fully binarized BERT model in real-world resource-constrained scenarios.

Ask Lune

Know this paper in minutes, not an afternoon.

Lune can read every page of it and the top-tier papers that cite it, and gives you its claims, its evidence and its limits, each one cited to the paper it comes from. No skimming, no AI slop.

40 top-tier papers have cited it since. Know what they found before your reviewers do.

Questions to start from

Lune can draw on

the full paper · the top-tier papers that cite it · related work

Get the answer

Free to start. No credit card required.

Lineage

  • TinyBERT: Distilling BERT for Natural Language Understanding cites Q-BERT: Hessian Based Ultra Low Precision Quantization of BERT
  • BiViT: Extremely Compressed Binary Vision Transformers cites Q-ViT: Accurate and Fully Quantized Low-bit Vision Transformer
  • Q-ViT: Accurate and Fully Quantized Low-bit Vision Transformer cites Similarity-Preserving Knowledge Distillation
  • TernaryBERT: Distillation-aware Ultra-low Bit BERT cites TinyBERT: Distilling BERT for Natural Language Understanding
  • TernaryBERT: Distillation-aware Ultra-low Bit BERT cites Q-BERT: Hessian Based Ultra Low Precision Quantization of BERT
  • Q-DM: An Efficient Low-bit Quantized Diffusion Model cites Q-ViT: Accurate and Fully Quantized Low-bit Vision Transformer
  • PB-LLM: Partially Binarized Large Language Models cites BiT: Robustly Binarized Multi-distilled Transformer
  • BiT: Robustly Binarized Multi-distilled Transformer cites TernaryBERT: Distillation-aware Ultra-low Bit BERT
  • BiT: Robustly Binarized Multi-distilled Transformer cites Training binary neural networks with real-to-binary convolutions
  • BiT: Robustly Binarized Multi-distilled Transformer cites Q-BERT: Hessian Based Ultra Low Precision Quantization of BERT
Builds onCited byLeft to right by year; the more cited, the higher.

Cited by top-tier papers40

  1. Q-ViT: Accurate and Fully Quantized Low-bit Vision TransformerYanjing Li, Sheng Xu, Baochang Zhang, Xianbin Cao et al.NeurIPS 2022 · 185 citations
  2. BiT: Robustly Binarized Multi-distilled TransformerZechun Liu, Barlas Oguz, Aasish Pappu, Lin Xiao et al.NeurIPS 2022 · 93 citations
  3. PB-LLM: Partially Binarized Large Language ModelsZhihang Yuan, Yuzhang Shang, Zhen DongICLR 2024 · 91 citations
  4. Q-DM: An Efficient Low-bit Quantized Diffusion ModelYanjing Li, Sheng Xu, Xianbin Cao, Xiao Sun et al.NeurIPS 2023 · 70 citations
  5. BiViT: Extremely Compressed Binary Vision TransformersYefei He, Zhenyu Lou, Luoming Zhang, Jing Liu et al.ICCV 2023 · 44 citations

Builds on9

  1. TinyBERT: Distilling BERT for Natural Language UnderstandingXiaoqi Jiao, Yichun Yin, Lifeng Shang, Xin Jiang et al.EMNLP Findings 2020 · 1,787 citations
  2. Similarity-Preserving Knowledge DistillationFrederick Tung, Greg MoriICCV 2019 · 1,214 citations
  3. Q-BERT: Hessian Based Ultra Low Precision Quantization of BERTSheng Shen, Zhen Dong, Jiayu Ye, Linjian Ma et al.AAAI 2020 · 656 citations
  4. Training binary neural networks with real-to-binary convolutionsBrais Martínez, Jing Yang, Adrian Bulat, Georgios TzimiropoulosICLR 2020 · 251 citations
  5. TernaryBERT: Distillation-aware Ultra-low Bit BERTWei Zhang, Lu Hou, Yichun Yin, Lifeng Shang et al.EMNLP 2020 · 147 citations

Related papers

  1. Partially-Random Initialization: A Smoking Gun for Binarization Hypothesis of BERTArash ArdakaniEMNLP Findings 2022 · 1 citation
  2. BinaryBERT: Pushing the Limit of BERT QuantizationHaoli Bai, Wei Zhang, Lu Hou, Lifeng Shang et al.ACL 2021
  3. BiLLM: Pushing the Limit of Post-Training Quantization for LLMsWei Huang, Yangdong Liu, Haotong Qin, Ying Li et al.ICML 2024 · 161 citations
  4. BiDM: Pushing the Limit of Quantization for Diffusion ModelsXingyu Zheng, Xianglong Liu, Yichen Bian, Xudong Ma et al.NeurIPS 2024 · 12 citations
  5. BinaryAttention: One-Bit QK-Attention for Vision and Diffusion TransformersChaodong XIAO, Zhengqiang ZHANG, Lei ZhangCVPR 2026 · 1 citation
Dusk over the sea between two cliffs drawn in fine vertical lines