Visual Attention Network

20 Feb 2022  ยท  Meng-Hao Guo, Cheng-Ze Lu, Zheng-Ning Liu, Ming-Ming Cheng, Shi-Min Hu ยท

While originally designed for natural language processing tasks, the self-attention mechanism has recently taken various computer vision areas by storm. However, the 2D nature of images brings three challenges for applying self-attention in computer vision. (1) Treating images as 1D sequences neglects their 2D structures. (2) The quadratic complexity is too expensive for high-resolution images. (3) It only captures spatial adaptability but ignores channel adaptability. In this paper, we propose a novel linear attention named large kernel attention (LKA) to enable self-adaptive and long-range correlations in self-attention while avoiding its shortcomings. Furthermore, we present a neural network based on LKA, namely Visual Attention Network (VAN). While extremely simple, VAN surpasses similar size vision transformers(ViTs) and convolutional neural networks(CNNs) in various tasks, including image classification, object detection, semantic segmentation, panoptic segmentation, pose estimation, etc. For example, VAN-B6 achieves 87.8% accuracy on ImageNet benchmark and set new state-of-the-art performance (58.2 PQ) for panoptic segmentation. Besides, VAN-B2 surpasses Swin-T 4% mIoU (50.1 vs. 46.1) for semantic segmentation on ADE20K benchmark, 2.6% AP (48.8 vs. 46.2) for object detection on COCO dataset. It provides a novel method and a simple yet strong baseline for the community. Code is available at https://github.com/Visual-Attention-Network.

PDF Abstract
Task Dataset Model Metric Name Metric Value Global Rank Result Benchmark
Semantic Segmentation ADE20K VAN-Large Validation mIoU 48.1 # 142
Params (M) 49 # 49
Semantic Segmentation ADE20K VAN-Tiny Validation mIoU 38.5 # 213
Params (M) 8 # 61
Semantic Segmentation ADE20K VAN-Small Validation mIoU 42.9 # 205
Params (M) 18 # 57
Semantic Segmentation ADE20K VAN-B6 Validation mIoU 54.7 # 49
Semantic Segmentation ADE20K VAN-Base (Semantic-FPN) Validation mIoU 46.7 # 164
Semantic Segmentation ADE20K VAN-Large (HamNet) Validation mIoU 50.2 # 110
Params (M) 55 # 47
Panoptic Segmentation COCO minival Visual Attention Network (VAN-B6 + Mask2Former) PQ 58.2 # 6
PQth 64.8 # 4
PQst 48.2 # 8
Panoptic Segmentation COCO panoptic VAN-B6* PQ 58.2 # 1
Image Classification ImageNet VAN-B0 Top 1 Accuracy 75.4% # 873
Number of params 4.1M # 381
GFLOPs 0.9 # 100
Image Classification ImageNet VAN-B1 Top 1 Accuracy 81.1% # 604
Number of params 13.9M # 510
GFLOPs 2.5 # 161
Image Classification ImageNet VAN-B2 Top 1 Accuracy 82.8% # 450
Number of params 26.6M # 613
GFLOPs 5 # 231
Image Classification ImageNet VAN-B4 (22K, 384res) Top 1 Accuracy 86.6% # 130
Number of params 60M # 764
GFLOPs 35.9 # 403
Image Classification ImageNet VAN-B5 (22K) Top 1 Accuracy 86.3% # 151
Number of params 90M # 847
GFLOPs 17.2 # 355
Image Classification ImageNet VAN-B5 (22K, 384res) Top 1 Accuracy 87% # 110
Number of params 90M # 847
GFLOPs 50.6 # 424
Image Classification ImageNet VAN-B6 (22K, 384res) Top 1 Accuracy 87.8% # 73
Number of params 200M # 901
GFLOPs 114.3 # 456
Image Classification ImageNet VAN-B4 (22K) Top 1 Accuracy 85.7% # 197
Number of params 60M # 764
GFLOPs 12.2 # 315

Methods