[论文解读] BOAT: Bilateral Local Attention Vision Transformer
BOAT 引入了一种双边本地注意力机制,将图像空间本地注意力与特征空间本地注意力结合,通过分层聚类实现平衡,提升在若干视觉任务上相对于 Swin 和 CSWin 骨干的性能。它在 BOAT-Swin 与 BOAT-CSWin 上均有一致提升。
Vision Transformers achieved outstanding performance in many computer vision tasks. Early Vision Transformers such as ViT and DeiT adopt global self-attention, which is computationally expensive when the number of patches is large. To improve efficiency, recent Vision Transformers adopt local self-attention mechanisms, where self-attention is computed within local windows. Despite the fact that window-based local self-attention significantly boosts efficiency, it fails to capture the relationships between distant but similar patches in the image plane. To overcome this limitation of image-space local attention, in this paper, we further exploit the locality of patches in the feature space. We group the patches into multiple clusters using their features, and self-attention is computed within every cluster. Such feature-space local attention effectively captures the connections between patches across different local windows but still relevant. We propose a Bilateral lOcal Attention vision Transformer (BOAT), which integrates feature-space local attention with image-space local attention. We further integrate BOAT with both Swin and CSWin models, and extensive experiments on several benchmark datasets demonstrate that our BOAT-CSWin model clearly and consistently outperforms existing state-of-the-art CNN models and vision Transformers.
研究动机与目标
- 推动通过在图像空间和特征空间同时捕捉远端关系来提高 Vision Transformer 的效率与准确性。
- 提出一个 Bilateral Local Attention (BLA) 模块,将 image-space local attention (ISLA) 与 feature-space local attention (FSLA) 相融合。
- 引入平衡层次聚类以形成等大小的特征空间聚类,从而实现高效的 FSLA 计算。
- 在图像分类、语义分割和目标检测基准上证明相对于最先进的局部注意力变换器的改进。
提出的方法
- 实现一个 Bilateral Local Attention (BLA) 模块,包含:一个 image-space local attention (ISLA) 模块、一个 feature-space local attention (FSLA) 模块、LN 层,以及带残差连接的 MLP。
- FSLA 使用多级平衡层次聚类按内容对令牌分组,形成等大小的聚类,从而在聚类内实现高效的并行注意力。
- 引入重叠的平衡层次聚类,在最后一级扩大感受野。
- 在 FSLA 中应用局部增强的位置编码,以在基于特征的注意力中保留空间信息。
实验结果
研究问题
- RQ1特征空间本地注意力是否可以补充图像空间本地注意力,以捕获距离较远但相关内容的补丁关系?
- RQ2平衡层次聚类是否能够在不牺牲并行性或性能的前提下实现高效而有效的 FSLA?
- RQ3BOAT 的变体在分类、分割和检测任务上是否始终优于它们各自的 Swin 和 CSWin 基线?
主要发现
- BOAT-Swin-T 和 BOAT-CSWin-T 在 ImageNet-1K 上优于各自的 vanilla 对应模型,精度提高且参数及 FLOP 负载适度。
- BOAT-Swin-S 和 BOAT-CSWin-S 在 Tiny、Small、Base 设置下均获得比基线模型更高的 Top-1 精度。
- BOAT-Swin-B 和 BOAT-CSWin-B 在准确性方面分别相对于 Swin-B 和 CSWin-B 显示出持续的提升。
- 消融结果显示 FSLA 比单独的 ISLA 更有效(Tiny 变体表3中 82.3% 对 81.5%),且重叠的平衡层次聚类比非重叠版本具有更高的准确性(例如 BOAT-CSWin-T 的 83.7% 对 83.3%)。
- 在 ADE20K 的语义分割上,BOAT-Swin-T/S 和 BOAT-CSWin-T/S 相对于其 vanilla 对应模型获得更高的 mIoU;BOAT-Swin-B/CSWin-B 也观察到类似的提升。
- 在使用 Mask R-CNN 的 MS-COCO 目标检测中,BOAT-Swin-T/S 在相近预算下在 mAP Box 和 mAP Mask 上优于 Swin-T/S。
阅读本论文
在 Nubint 阅读器中打开原文,边读边就任意段落提问。
在 Nubint 中阅读本论文本解读由 AI 根据论文原文生成,引用前请核对原文。