arXiv:2411.15851cs.CV2024-11CVPR被引 40

让CLIP模型无需训练就能做像素级图文推理,效果显著提升。

ResCLIP: Residual Attention for Training-free Dense Vision-language Inference

  • 利用中间层交叉相关注意力重构最终层注意力,增强定位能力。
  • 在多个基准上超越现有无训练方法,实例分割任务提升超10%。
  • 模块化设计,可直接嵌入现有方法,适合快速部署密集视觉任务。

尽管视觉语言模型如CLIP在开放词汇任务中表现优异,但其应用仍局限于图像级任务,难以处理密集预测。现有方法常将此问题归因于最后一层自注意力机制,通过修改查询-键注意力为自相关注意力(如查询-查询、键-键)取得进展。然而这些方法忽略了查询-键之间的交叉相关性,该特性能捕捉丰富的空间对应关系。本文揭示:CLIP非最后一层的自注意力也具有定位特性。为此提出残差交叉相关自注意力(RCS)模块,利用中间层的交叉相关自注意力重塑最后一层注意力,有效重组空间信息,释放CLIP在密集视觉-语言推理中的潜力。为进一步强化同类区域关注与局部一致性,引入语义反馈精炼(SFR)模块,利用语义分割图调整注意力分数。结合两者后,所提方法ResCLIP可作为即插即用模块集成至现有方法中,在多个标准基准上显著提升性能,优于当前最先进的无训练方法。代码已公开于https://github.com/yvhangyang/ResCLIP。

原文摘要 · Abstract (English)

While vision-language models like CLIP have shown remarkable success in open-vocabulary tasks, their application is currently confined to image-level tasks, and they still struggle with dense predictions. Recent works often attribute such deficiency in dense predictions to the self-attention layers in the final block, and have achieved commendable results by modifying the original query-key attention to self-correlation attention, (e.g., query-query and key-key attention). However, these methods overlook the cross-correlation attention (query-key) properties, which capture the rich spatial correspondence. In this paper, we reveal that the cross-correlation of the self-attention in CLIP's non-final layers also exhibits localization properties. Therefore, we propose the Residual Cross-correlation Self-attention (RCS) module, which leverages the cross-correlation self-attention from intermediate layers to remold the attention in the final block. The RCS module effectively reorganizes spatial information, unleashing the localization potential within CLIP for dense vision-language inference. Furthermore, to enhance the focus on regions of the same categories and local consistency, we propose the Semantic Feedback Refinement (SFR) module, which utilizes semantic segmentation maps to further adjust the attention scores. By integrating these two strategies, our method, termed ResCLIP, can be easily incorporated into existing approaches as a plug-and-play module, significantly boosting their performance in dense vision-language inference. Extensive experiments across multiple standard benchmarks demonstrate that our method surpasses state-of-the-art training-free methods, validating the effectiveness of the proposed approach. Code is available at https://github.com/yvhangyang/ResCLIP.

视觉语言密集预测无训练注意力机制

Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。