Skip to main content
QUICK REVIEW

[论文解读] CMA-CLIP: Cross-Modality Attention CLIP for Image-Text Classification

Huidong Liu, Shaoyuan Xu|arXiv (Cornell University)|Dec 7, 2021
Multimodal Machine Learning Applications被引用 9
一句话总结

CMA-CLIP 提出了一种统一框架,通过整合序列级和模态级跨模态注意力机制,增强了 CLIP 在图像-文本分类任务中的表现。通过建模细粒度的图像块-标记关系,并根据相关性动态加权模态,该方法在 MRWPA 数据集上实现了 90% 精确率下 11.9% 的召回率提升,在 Fashion-Gen 上相比 SOTA 方法准确率提高 5.5%,同时展现出对噪声输入的强鲁棒性。

ABSTRACT

Modern Web systems such as social media and e-commerce contain rich contents expressed in images and text. Leveraging information from multi-modalities can improve the performance of machine learning tasks such as classification and recommendation. In this paper, we propose the Cross-Modality Attention Contrastive Language-Image Pre-training (CMA-CLIP), a new framework which unifies two types of cross-modality attentions, sequence-wise attention and modality-wise attention, to effectively fuse information from image and text pairs. The sequence-wise attention enables the framework to capture the fine-grained relationship between image patches and text tokens, while the modality-wise attention weighs each modality by its relevance to the downstream tasks. In addition, by adding task specific modality-wise attentions and multilayer perceptrons, our proposed framework is capable of performing multi-task classification with multi-modalities. We conduct experiments on a Major Retail Website Product Attribute (MRWPA) dataset and two public datasets, Food101 and Fashion-Gen. The results show that CMA-CLIP outperforms the pre-trained and fine-tuned CLIP by an average of 11.9% in recall at the same level of precision on the MRWPA dataset for multi-task classification. It also surpasses the state-of-the-art method on Fashion-Gen Dataset by 5.5% in accuracy and achieves competitive performance on Food101 Dataset. Through detailed ablation studies, we further demonstrate the effectiveness of both cross-modality attention modules and our method's robustness against noise in image and text inputs, which is a common challenge in practice.

研究动机与目标

  • 解决 CLIP 在微调用于分类任务时对细粒度图像-文本关系建模能力不足的问题。
  • 通过学习模态相关性权重,提升对噪声图像或文本输入的鲁棒性。
  • 通过任务特定的模态注意力和 MLP 头,实现单个统一网络的多任务分类。
  • 通过在训练和推理阶段同时利用两种模态,提升 CLIP 在下游分类任务中的性能,超越零样本能力。

提出的方法

  • 集成一种序列级注意力模块,利用基于 Transformer 的机制建模图像块与文本标记之间的细粒度相关性。
  • 采用一种模态级注意力模块,根据其与分类任务的相关性,学习图像和文本模态的动态权重。
  • 在 CLIP 主干网络基础上,增加任务特定的模态级注意力头和多层感知机(MLPs),以支持多任务学习。
  • 使用图像-文本对的对比损失进行端到端训练,优化整个架构。
  • 通过注意力可视化分析模型对相关图像块和文本标记的关注程度,以解释和验证模型行为。

实验结果

研究问题

  • RQ1建模图像块与文本标记之间的细粒度跨模态关系,是否能超越标准 CLIP 的分类性能?
  • RQ2学习模态特定的注意力权重是否能增强对噪声或无关图像或文本输入的鲁棒性?
  • RQ3统一的网络架构能否有效支持共享表示的多任务图像-文本分类?
  • RQ4在真实世界和公开基准数据集上,CMA-CLIP 与 SOTA 方法相比,在准确率和鲁棒性方面表现如何?

主要发现

  • 在 MRWPA 数据集上,CMA-CLIP 在相同精确率(90%)下,相较于微调后的 CLIP,在三个产品属性分类任务中平均召回率提升 11.9%。
  • 在 Fashion-Gen 数据集上,CMA-CLIP 达到 93.6% 的准确率,较之前 SOTA 方法(KaleidoBERT)高出 5.5 个百分点。
  • 消融实验表明,若移除模态级注意力模块,MRWPA 上的平均召回率将从 53.4% 降至 47.5%,证实其在过滤噪声输入中的关键作用。
  • 序列级注意力模块对性能有显著贡献,若将其移除,召回率将进一步从 47.5% 降至 45.8%。
  • 可视化结果表明,序列级注意力能正确识别与分类相关文本标记相关的图像块,该现象在全部三个数据集中均得到验证。
  • CMA-CLIP 在 Food101 上保持了具有竞争力的性能,准确率达到 93.1%,优于 MMBT 和 BERT 等强基线模型。

更好的研究,从现在开始

从阅读论文到最终审阅,大幅缩短您的研究时间。

无需绑定信用卡

本解读由 AI 生成,并经人工编辑审核。