[论文解读] Prompt Vision Transformer for Domain Generalization
该论文提出 DoPrompt,一种用于视觉变换器(Vision Transformers)的新颖域泛化方法,通过使用特定于域的提示(domain-specific prompts)和提示适配器(prompt adapter),提升对未见域的零样本泛化能力。通过在训练过程中学习域提示,并在推理时通过域适配器动态调整这些提示,DoPrompt 在 ViT 上实现了比当前最先进方法(SOTA)平均 1.4% 的准确率提升,性能提升幅度是此前方法的 3.5 倍。
Though vision transformers (ViTs) have exhibited impressive ability for representation learning, we empirically find that they cannot generalize well to unseen domains with previous domain generalization algorithms. In this paper, we propose a novel approach DoPrompt based on prompt learning to embed the knowledge of source domains in domain prompts for target domain prediction. Specifically, domain prompts are prepended before ViT input tokens from the corresponding source domain. Each domain prompt learns domain-specific knowledge efficiently since it is optimized only for one domain. Meanwhile, we train a prompt adapter to produce a suitable prompt for each input image based on the learned source domain prompts. At test time, the adapted prompt generated by the prompt adapter can exploit the similarity between the feature of the out-of-domain image and source domains to properly integrate the source domain knowledge. Extensive experiments are conducted on four benchmark datasets. Our approach achieves 1.4% improvements in the averaged accuracy, which is 3.5 times the improvement of the state-of-the-art algorithm with a ViT backbone.
研究动机与目标
- 解决视觉变换器在域分布偏移下表现不佳的域泛化性能问题。
- 通过从源域中学习特定于域的知识,提升零样本泛化能力。
- 开发一种机制,在推理时自适应地组合源域知识,以应对未见的目标域。
- 克服先前域泛化方法仅使用部分网络参数或静态集成所带来的局限性。
- 在不微调 ViT 主干网络的前提下,实现有效的基于提示的自适应。
提出的方法
- 在训练过程中,将特定于域的提示附加到图像块标记(image patch tokens)之前,使每个提示能够通过自注意力机制学习特定于域的知识。
- 训练一个提示适配器网络,该网络接收输入图像的特征,并在推理时生成源域提示的加权组合。
- 使用两种损失函数优化提示适配器:一种用于区分域特征,另一种用于提升在目标域上的预测准确率。
- 在测试时使用经调整的提示,根据域之间的相似性,动态整合来自多个源域的知识。
- 端到端微调整个模型,包括提示适配器和域提示,以提升泛化能力。
- 利用 ViT 的自注意力机制,使提示标记能够与所有层交互,从而实现丰富的特征理解。
实验结果
研究问题
- RQ1提示学习能否有效捕捉视觉变换器中用于域泛化的特定于域的知识?
- RQ2可学习的提示适配器是否能通过动态组合源域知识,提升零样本泛化性能?
- RQ3在使用 ViT 主干网络时,DoPrompt 与 SOTA 方法相比,在准确率和泛化增益方面表现如何?
- RQ4域提示和提示适配器对性能的贡献程度如何?二者是否都不可或缺?
- RQ5提示适配器能否学习到源域与目标域之间的域相似性?
主要发现
- DoPrompt 在 ViT-Base 上相比 SOTA 基线实现了 1.4% 的平均准确率提升,该提升幅度是此前最佳方法的 3.5 倍。
- 提示适配器显著提升了性能,当其被移除时,平均准确率下降 1.2%(在 OfficeHome 数据集上从 76.0% 降至 74.8%)。
- 消融实验确认,域提示和提示适配器两个组件均至关重要,当移除域提示时,性能下降 1.7%。
- 权重分析表明,提示适配器会为与目标域更相似的源域分配更高的权重,例如在目标域为 Clipart 时,Art 域的提示权重更高。
- 仅使用提示微调而不微调主干网络会导致 2.0% 的准确率下降(74.0% 对比 76.0%),表明完整微调是必要的。
- 经调整的提示在所有目标域上均优于单一源域提示,证实了适配器能够生成更优、更具上下文感知能力的提示。
更好的研究,从现在开始
从阅读论文到最终审阅,大幅缩短您的研究时间。
无需绑定信用卡
本解读由 AI 生成,并经人工编辑审核。