arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2507.16624cs.CV
收藏

A2Mamba:面向视觉识别的注意力增强状态空间模型

A2Mamba: Attention-augmented State Space Models for Visual Recognition

School of Computing and Data Science, The University of Hong Kong(计算与数据科学学院,香港大学)

Meng Lou, Yunxiang Fu, Yizhou Yu

AI总结:

本文提出 A2Mamba,通过多尺度注意力增强状态空间模型实现 Transformer 与 Mamba 的深度融合,在图像分类、分割和检测等视觉识别任务上超越此前架构并保持高效。

摘要:

Transformer 和 Mamba 最初为自然语言处理而发明,现已启发视觉识别的主干架构设计。近期研究将局部注意力 Transformer 与 Mamba 集成,以同时捕获局部细节和全局上下文。尽管性能具有竞争力,但这些方法仅限于简单堆叠 Transformer 和 Mamba 层,二者之间缺乏任何交互机制。因此,Transformer 与 Mamba 层的深度融合仍是一个未解决的问题。我们通过提出 A2Mamba 来解决这一问题,这是一种强大的 Transformer-Mamba 混合网络架构,其特点是新型 token 混合器,称为多尺度注意力增强状态空间模型(MASS),其中多尺度注意力图被集成到注意力增强 SSM(A2SSM)中。A2SSM 的关键步骤通过使用多尺度注意力图对 SSM 的隐藏状态进行空间聚合,执行一种交叉注意力的变体,从而增强与二维空间相关的空间依赖性,同时提升 SSM 的动态建模能力。我们的 A2Mamba 在视觉识别任务中优于所有先前的基于 ConvNet、Transformer 和 Mamba 的架构。例如,A2Mamba-L 在 ImageNet-1K 上取得了令人瞩目的 86.1% top-1 准确率。在语义分割中,A2Mamba-B 在 mIoU 上超过 CAFormer-S36 达 2.5%,同时具有更高的效率。在使用 Cascade Mask R-CNN 的目标检测和实例分割中,A2Mamba-S 在 AP^b/AP^m 上超过 MambaVision-B 达 1.2%/0.9%,而参数量减少 40%。代码公开于 https://github.com/LMMMEng/A2Mamba。

英文摘要:

Transformers and Mamba, initially invented for natural language processing, have inspired backbone architectures for visual recognition. Recent studies integrated Local Attention Transformers with Mamba to capture both local details and global contexts. Despite competitive performance, these methods are limited to simple stacking of Transformer and Mamba layers without any interaction mechanism between them. Thus, deep integration between Transformer and Mamba layers remains an open problem. We address this problem by proposing A2Mamba, a powerful Transformer-Mamba hybrid network architecture, featuring a new token mixer termed Multi-scale Attention-augmented State Space Model (MASS), where multi-scale attention maps are integrated into an attention-augmented SSM (A2SSM). A key step of A2SSM performs a variant of cross-attention by spatially aggregating the SSM's hidden states using the multi-scale attention maps, which enhances spatial dependencies pertaining to a two-dimensional space while improving the dynamic modeling capabilities of SSMs. Our A2Mamba outperforms all previous ConvNet-, Transformer-, and Mamba-based architectures in visual recognition tasks. For instance, A2Mamba-L achieves an impressive 86.1% top-1 accuracy on ImageNet-1K. In semantic segmentation, A2Mamba-B exceeds CAFormer-S36 by 2.5% in mIoU, while exhibiting higher efficiency. In object detection and instance segmentation with Cascade Mask R-CNN, A2Mamba-S surpasses MambaVision-B by 1.2%/0.9% in AP^b/AP^m, while having 40% fewer parameters. Code is publicly available at https://github.com/LMMMEng/A2Mamba.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑