Learning to Prompt with Text Only Supervision for Vision-Language Models

要約

CLIPのような基礎的な視覚言語モデルは、その優れた汎化能力により、視覚の新しいパラダイムになりつつある。しかし、汎化能力を維持したまま、これらのモデルを下流のタスクに適応させることは、依然として課題である。文献的には、視覚情報を用いてプロンプトを学習することで、CLIPを適応させる手法がある。効果的ではあるが、これらの手法の大半はラベル付きデータを必要とするため実用的ではなく、また元データのオーバーフィッティングにより新しいデータセットへの汎化に苦戦することが多い。別のアプローチとして、大規模言語モデル(LLM)からクラス記述を生成し、プロンプトのアンサンブルを実行することで、トレーニングを必要としない方法に頼る。しかし、これらの方法はしばしば他のクラスに移行できないクラス固有のプロンプトを生成し、各クラスのLLM記述を個別に生成することでより高いコストが発生する。本研究では、LLMから得られるテキストデータのみを用いてプロンプトを学習することで、これら2つの手法の長所を組み合わせることを提案する。プロンプトの教師付き学習は画像がないために容易ではないため、我々はプロンプトがLLMデータから豊富な文脈知識を抽出できるような学習アプローチを開発する。さらに、学習したプロンプトにLLMの文脈データをマッピングすることで、新しいクラスやデータセットへのプロンプトのゼロショット転送を可能にし、LLMプロンプトのエンジニアリングコストを削減できる可能性がある。我々の知る限り、これはテキストのみのデータを用いて一般化されたプロンプトを学習する最初の研究である。我々は4つのベンチマークで広範な評価を行ったが、その結果、我々の手法は、ラベル付き画像を利用した手法に引けを取らない一方で、先行するアンサンブル手法よりも優れていた。我々のコードと事前学習済みモデルは https://github.com/muzairkhattak/ProText で入手可能である。

要約(オリジナル)

Foundational vision-language models such as CLIP are becoming a new paradigm in vision, due to their excellent generalization abilities. However, adapting these models for downstream tasks while maintaining their generalization remains a challenge. In literature, one branch of methods adapts CLIP by learning prompts using visual information. While effective, most of these works require labeled data which is not practical, and often struggle to generalize towards new datasets due to over-fitting on the source data. An alternative approach resorts to training-free methods by generating class descriptions from large language models (LLMs) and perform prompt ensembling. However, these methods often generate class specific prompts that cannot be transferred to other classes, which incur higher costs by generating LLM descriptions for each class separately. In this work, we propose to combine the strengths of these both streams of methods by learning prompts using only text data derived from LLMs. As supervised training of prompts is not trivial due to absence of images, we develop a training approach that allows prompts to extract rich contextual knowledge from LLM data. Moreover, with LLM contextual data mapped within the learned prompts, it enables zero-shot transfer of prompts to new classes and datasets potentially cutting the LLM prompt engineering cost. To the best of our knowledge, this is the first work that learns generalized prompts using text only data. We perform extensive evaluations on 4 benchmarks where our method improves over prior ensembling works while being competitive to those utilizing labeled images. Our code and pre-trained models are available at https://github.com/muzairkhattak/ProText.

arxiv情報

著者 Muhammad Uzair Khattak,Muhammad Ferjad Naeem,Muzammal Naseer,Luc Van Gool,Federico Tombari
発行日 2024-01-04 18:59:49+00:00
arxivサイト arxiv_id(pdf)

提供元, 利用サービス

arxiv.jp, DeepL

カテゴリー: cs.CV パーマリンク