Demystify Transformers & Convolutions in Modern Image Deep Networks

📅 2022-11-10
🏛️ IEEE Transactions on Pattern Analysis and Machine Intelligence
📈 Citations: 11
Influential: 1
📄 PDF

career value

184K/year
🤖 AI Summary
This work investigates the fundamental differences between spatial token mixers (STMs)—the spatial feature aggregation mechanisms—in Vision Transformers and convolutional networks. To enable a fair, architecture-agnostic comparison, we propose a unified STM modeling paradigm that decouples network-level design from the spatial aggregation module, implementing both convolutional and attention-based STMs on a neutral backbone. Our methodology includes: (1) designing a modular, swappable STM interface; (2) systematically analyzing inductive biases—including receptive field size, translation invariance, and adversarial robustness; and (3) conducting multi-task performance benchmarking. Results show that while modern network-level designs yield substantial gains, intrinsic performance gaps among STMs persist. Crucially, we quantitatively demonstrate for the first time that convolutions exhibit superior translation invariance and local robustness, whereas attention achieves larger effective receptive fields but is more vulnerable to input perturbations.
📝 Abstract
Vision transformers have gained popularity recently, leading to the development of new vision backbones with improved features and consistent performance gains. However, these advancements are not solely attributable to novel feature transformation designs; certain benefits also arise from advanced network-level and block-level architectures. This paper aims to identify the real gains of popular convolution and attention operators through a detailed study. We find that the key difference among these feature transformation modules, such as attention or convolution, lies in their spatial feature aggregation approach, known as the “spatial token mixer” (STM). To facilitate an impartial comparison, we introduce a unified architecture to neutralize the impact of divergent network-level and block-level designs. Subsequently, various STMs are integrated into this unified framework for comprehensive comparative analysis. Our experiments on various tasks and an analysis of inductive bias show a significant performance boost due to advanced network-level and block-level designs, but performance differences persist among different STMs. Our detailed analysis also reveals various findings about different STMs, including effective receptive fields, invariance, and adversarial robustness tests.
Problem

Research questions and friction points this paper is trying to address.

Compare spatial token mixers in vision backbones
Unify architecture to isolate feature transformation effects
Analyze performance differences in attention vs convolution
Innovation

Methods, ideas, or system contributions that make the work stand out.

Unified architecture neutralizes divergent designs
Spatial token mixer (STM) enables fair comparison
Analyzes STMs via receptive fields and robustness
🔎 Similar Papers
No similar papers found.
Jifeng Dai
Jifeng Dai
Associate Professor of EE, Tsinghua University
computer visiondeep learning
M
Min Shi
Shanghai Artificial Intelligence Laboratory, Shanghai, China; Huazhong University of Science and Technology, Wuhan, China
Weiyun Wang
Weiyun Wang
Shanghai AI Laboratory; Fudan University
Vision-Language ModelMLLMFoundation Model
S
Sitong Wu
Shanghai Artificial Intelligence Laboratory, Shanghai, China; The Chinese University of Hong Kong, Shatin, Hong Kong
L
Linjie Xing
Shanghai Artificial Intelligence Laboratory, Shanghai, China
W
Wenhai Wang
Shanghai Artificial Intelligence Laboratory, Shanghai, China
Xizhou Zhu
Xizhou Zhu
Tsinghua University
Lewei Lu
Lewei Lu
Research Director (We're Hiring, luotto@sensetime.com) @ SenseTime Research
Computer VisionDeep Learning
J
Jie Zhou
Tsinghua University, Beijing, China
X
Xiaogang Wang
The Chinese University of Hong Kong, Shatin, Hong Kong
Y
Yu Qiao
Shanghai Artificial Intelligence Laboratory, Shanghai, China
X
Xiaowei Hu
South China University of Technology, Guangzhou, China