Proceedings

Chop Chop BERT: Visual Question Answering by Chopping VisualBERT’s Heads

Download BibTeX Cite

Proceedings of the Thirtieth International Joint Conference on Artificial Intelligence. Main Track. Pages 664-670.

https://doi.org/10.24963/ijcai.2021/92

Abstract

Vision-and-Language (VL) pre-training has shown great potential on many related downstream tasks, such as Visual Question Answering (VQA), one of the most popular problems in the VL field. All of these pre-trained models (such as VisualBERT, ViLBERT, LXMERT and UNITER) are built with Transformer, which extends the classical attention mechanism to multiple layers and heads. To investigate why and how these models work on VQA so well, in this paper we explore the roles of individual heads and layers in Transformer models when handling 12 different types of questions. Specifically, we manually remove (chop) heads (or layers) from a pre-trained VisualBERT model at a time, and test it on different levels of questions to record its performance. As shown in the interesting echelon shape of the result matrices, experiments reveal different heads and layers are responsible for different question types, with higher-level layers activated by higher-level visual reasoning questions. Based on this observation, we design a dynamic chopping module that can automatically remove heads and layers of the VisualBERT at an instance level when dealing with different questions. Our dynamic chopping module can effectively reduce the parameters of the original model by 50%, while only damaging the accuracy by less than 1% on the VQA task.

  1. [Andreas et al., 2016] Jacob Andreas, Marcus Rohrbach, Trevor Darrell, and Dan Klein. Neural module networks. pages 39-48, 2016.
  2. [Chen et al., 2015] Xinlei Chen, Hao Fang, Tsung-Yi Lin, Ramakrishna Vedantam, Saurabh Gupta, Piotr Dollár, and C Lawrence Zitnick. Microsoft COCO Captions: Data collection and evaluation server. arXiv preprint arXiv:1504.00325, 2015.
  3. [Chen et al., 2020] Yen-Chun Chen, Linjie Li, Licheng Yu, Ahmed El Kholy, Faisal Ahmed, Zhe Gan, Yu Cheng, and Jingjing Liu. UNITER: Learning universal image-text rep- resentations. In Proc. Eur. Conf. Comp. Vis., 2020.
  4. [Dai et al., 2019] Zihang Dai, Zhilin Yang, Yiming Yang, Jaime Carbonell, Quoc V Le, and Ruslan Salakhutdi- nov. Transformer-XL: Attentive language models beyond a fixed-length context. In Proc. Conf. Association for Com- putational Linguistics, 2019.
  5. [Devlin et al., 2018] Jacob Devlin, Ming-Wei Chang, Ken- ton Lee, and Kristina Toutanova. BERT: Pre-training of deep bidirectional transformers for language understand- ing. arXiv preprint arXiv:1810.04805, 2018.
  6. [Egonmwan and Chali, 2019] Elozino Egonmwan and Yllias Chali. Transformer-based model for single documents neural summarization. In Proceedings of the 3rd Work- shop on Neural Generation and Translation, pages 70-79, 2019.
  7. [Goyal et al., 2017] Yash Goyal, Tejas Khot, Douglas Summers-Stay, Dhruv Batra, and Devi Parikh. Making the V in VQA matter: Elevating the role of image under- standing in visual question answering. In Proc. IEEE Conf. Comp. Vis. Patt. Recogn., pages 6904-6913, 2017.
  8. [He et al., 2016] Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. Deep residual learning for image recog- nition. In Proc. IEEE Conf. Comp. Vis. Patt. Recogn., pages 770-778, 2016.
  9. [Kafle and Kanan, 2017a] Kushal Kafle and Christopher Kanan. An analysis of visual question answering algo- rithms. In Proc. IEEE Int. Conf. Comp. Vis., pages 1965- 1973, 2017.
  10. [Kafle and Kanan, 2017b] Kushal Kafle and Christopher Kanan. Visual question answering: Datasets, algorithms, and future challenges. Computer Vision and Image Under- standing, 163:3-20, 2017.
  11. [Krishna et al., 2017] Ranjay Krishna, Yuke Zhu, Oliver Groth, Justin Johnson, Kenji Hata, Joshua Kravitz, Stephanie Chen, Yannis Kalantidis, Li-Jia Li, David A Shamma, et al. Visual Genome: Connecting language and vision using crowdsourced dense image annotations. Int. J. Comput. Vision, 123(1):32-73, 2017.
  12. [Li et al., 2020] Liunian Harold Li, Mark Yatskar, Da Yin, Cho-Jui Hsieh, and Kai-Wei Chang. VisualBERT: A sim- ple and performant baseline for vision and language. In Proc. Conf. Association for Computational Linguistics, 2020.
  13. [Lu et al., 2019] Jiasen Lu, Dhruv Batra, Devi Parikh, and Stefan Lee. ViLBERT: Pretraining task-agnostic visiolin- guistic representations for vision-and-language tasks. In Proc. Advances in Neural Inf. Process. Syst., pages 13-23, 2019.
  14. [Ma et al., 2019] Xindian Ma, Peng Zhang, Shuai Zhang, Nan Duan, Yuexian Hou, Ming Zhou, and Dawei Song. A tensorized transformer for language modeling. In Proc. Advances in Neural Inf. Process. Syst., pages 2232-2242, 2019.
  15. [Michel et al., 2019] Paul Michel, Omer Levy, and Graham Neubig. Are sixteen heads really better than one? In Proc. Advances in Neural Inf. Process. Syst., pages 14014- 14024, 2019.
  16. [Noh and Han, 2016] Hyeonwoo Noh and Bohyung Han. Training recurrent answering units with joint loss mini- mization for vqa. arXiv preprint arXiv:1606.03647, 2016.
  17. [Ren et al., 2015] Shaoqing Ren, Kaiming He, Ross Gir- shick, and Jian Sun. Faster R-CNN: Towards real-time object detection with region proposal networks. In Proc. Advances in Neural Inf. Process. Syst., pages 91-99, 2015.
  18. Sanh et al., ] Victor Sanh, Lysandre Debut, Julien Chau- mond, and Thomas Wolf. DistilBERT, a distilled version of bert: smaller, faster, cheaper and lighter. In Proceed- ings of 5th Workshop on Energy Efficient Machine Learn- ing and Cognitive Computing -NeurIPS 2019.
  19. [Shao et al., 2019] Taihua Shao, Yupu Guo, Honghui Chen, and Zepeng Hao. Transformer-based neural network for answer selection in question answering. IEEE Access, 7:26146-26156, 2019.
  20. [Shi et al., 2018] Yang Shi, Tommaso Furlanello, Sheng Zha, and Animashree Anandkumar. Question type guided attention in visual question answering. In Proc. Eur. Conf. Comp. Vis., pages 151-166, 2018.
  21. [Su et al., 2020] Weijie Su, Xizhou Zhu, Yue Cao, Bin Li, Lewei Lu, Furu Wei, and Jifeng Dai. VL-BERT: Pre- training of generic visual-linguistic representations. In Proc. Int. Conf. Learn. Representations, 2020.
  22. [Tan and Bansal, 2019] Hao Tan and Mohit Bansal. LXMERT: Learning cross-modality encoder represen- tations from transformers. In Proc. Conf. Empirical Methods in Natural Language Processing, 2019.
  23. [Vaswani et al., 2017] Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Łukasz Kaiser, and Illia Polosukhin. Attention is all you need. In Proc. Advances in Neural Inf. Process. Syst., pages 5998-6008, 2017.
  24. [Xu et al., 2020] Jiacheng Xu, Zhe Gan, Yu Cheng, and Jingjing Liu. Discourse-aware neural extractive text sum- marization. In Proc. Conf. Association for Computational Linguistics, pages 5021-5031, 2020.

References were extracted automatically from the PDF and may contain errors.

Welcome Future Conferences AI Journal Division IJCAI Proceedings About IJCAI IJCAI Awards