[Paper Review] Understanding The Robustness in Vision Transformers
This paper analyzes how self-attention contributes to robustness in Vision Transformers (ViTs) and introduces Fully Attentional Networks (FANs) with attentional channel processing to significantly improve robustness on ImageNet-C and downstream tasks, achieving state-of-the-art results.
Recent studies show that Vision Transformers(ViTs) exhibit strong robustness against various corruptions. Although this property is partly attributed to the self-attention mechanism, there is still a lack of systematic understanding. In this paper, we examine the role of self-attention in learning robust representations. Our study is motivated by the intriguing properties of the emerging visual grouping in Vision Transformers, which indicates that self-attention may promote robustness through improved mid-level representations. We further propose a family of fully attentional networks (FANs) that strengthen this capability by incorporating an attentional channel processing design. We validate the design comprehensively on various hierarchical backbones. Our model achieves a state-of-the-art 87.1% accuracy and 35.8% mCE on ImageNet-1k and ImageNet-C with 76.8M parameters. We also demonstrate state-of-the-art accuracy and robustness in two downstream tasks: semantic segmentation and object detection. Code is available at: https://github.com/NVlabs/FAN.
Motivation & Objective
- Investigate the role of self-attention in learning robust representations for ViTs.
- Understand how visual grouping and mid-level representations relate to robustness.
- Propose a fully attentional backbone (FAN) with attentional channel processing to enhance robustness.
Proposed method
- Interpret self-attention through an information bottleneck (IB) lens and connect it to clustering/grouping of token representations.
- Introduce the FAN block that adds channel attention (CA) to the self-attention pipeline and remove the post-MLP projection to form a fully attentional design.
- Develop Efficient Channel Self-attention (ECA) to reweight channels with a token prototype and sigmoid normalization for efficiency.
- Compare FAN variants (FAN-T/S/B/L) across backbone families and depths on ImageNet-1K and robustness benchmarks (ImageNet-C, Cityscapes-C, COCO-C).
- Conduct ablations to isolate effects of training tricks, attention mechanisms, and downsampling on robustness.
Experimental results
Research questions
- RQ1Does self-attention contribute to robustness via improved mid-level representations and grouping in ViTs?
- RQ2Can a fully attentional design with attentional channel processing further boost robustness without prohibitive cost?
- RQ3How does FAN compare to CNNs and other ViTs in clean accuracy and corruption robustness across tasks?
- RQ4What is the impact of efficient channel attention and different architectural variants on robustness gains?
- RQ5Do the robustness gains transfer to downstream tasks like segmentation and object detection?
Key findings
- FANs improve both clean accuracy and corruption robustness across sizes (Tiny to Large) and outperform baselines on ImageNet-C in terms of retention and mCE.
- FAN-S, FAN-B, and FAN-L achieve high robustness, e.g., FAN-S-ViT: retention 76, mCE 51.4%; FAN-B-ViT: retention 78, mCE 47.7% (various configurations).
- Efficient Channel Attention (ECA) and channel self-attention (CSA) yield the best robustness with comparable memory to SE; CSA delivers strongest robustness in tests (IN-C, Retention, mCE).
- The FAN block boosts robustness for ViT and Swin backbones; FAN-Hybrid and FAN-SWIN variants show substantial robustness gains over their non-FAN counterparts.
- Across downstream tasks, FAN-Hybrid achieves competitive robustness in semantic segmentation (Cityscapes-C) and object detection (COCO-C).
- Compared with SOTA CNNs and Transformers, FAN models deliver superior robustness under corruption while maintaining competitive clean accuracy.
Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.