Causal Attention for Vision-Language Tasks

Abstract

We present a novel attention mechanism: Causal Attention (CATT), to remove the ever-elusive confounding effect in existing attention-based vision-language models. This effect causes harmful bias that misleads the attention module to focus on the spurious correlations in training data, damaging the model generalization. As the confounder is unobserved in general, we use the front-door adjustment to realize the causal intervention, which does not require any knowledge on the confounder. Specifically, CATT is implemented as a combination of 1) In-Sample Attention (IS-ATT) and 2) Cross-Sample Attention (CS-ATT), where the latter forcibly brings other samples into every IS-ATT, mimicking the causal intervention. CATT abides by the Q-K-V convention and hence can replace any attention module such as top-down attention and self-attention in Transformers. CATT improves various popular attention-based vision-language models by considerable margins. In particular, we show that CATT has great potential in large-scale pre-training, e.g., it can promote the lighter LXMERT [??], which uses fewer data and less computational power, comparable to the heavier UNITER [??]. Code is published in https://github.com/yangxuntu/lxmertcatt.

Cite

Text

Yang et al. "Causal Attention for Vision-Language Tasks." Conference on Computer Vision and Pattern Recognition, 2021. doi:10.1109/CVPR46437.2021.00972

Markdown

[Yang et al. "Causal Attention for Vision-Language Tasks." Conference on Computer Vision and Pattern Recognition, 2021.](https://mlanthology.org/cvpr/2021/yang2021cvpr-causal/) doi:10.1109/CVPR46437.2021.00972

BibTeX

@inproceedings{yang2021cvpr-causal,
  title     = {{Causal Attention for Vision-Language Tasks}},
  author    = {Yang, Xu and Zhang, Hanwang and Qi, Guojun and Cai, Jianfei},
  booktitle = {Conference on Computer Vision and Pattern Recognition},
  year      = {2021},
  pages     = {9847-9857},
  doi       = {10.1109/CVPR46437.2021.00972},
  url       = {https://mlanthology.org/cvpr/2021/yang2021cvpr-causal/}
}