📖

【随時更新】【論文】 Open-Vocabulary Segmentationまとめ

に公開

Open-Vocabulary Segmentation系の論文について、気が向いたときに簡単にまとめています。
随時更新です。
各図表は紹介している論文のものを使用しています。

LANGUAGE-DRIVEN SEMANTIC SEGMENTATION (ICLR2022) [1]

従来のセマンティックセグメンテーションは,学習時に固定されたラベル集合のみ推定する。
そこで,任意のテキストラベルを後から与えても推論可能なLanguage-Driven Semantic Segmentation(LSeg)を提案。
CLIPと同様に,画像とテキストを同一埋め込み空間に写像し,そこで相関を取るだけで未学習クラスに汎化。

input labelをtext encoderに入力し、text embeddingを出力。
入力画像からDense Prediction Transformerでimage embeddingsを推定。
image embeddingsとtext embeddingsの内積を計算し、Word-pixel correlation tensorを得る。
それらをdepth-wise convとmax poolingで構成されるSpatial Regularization Blockでアップサンプリング。
推論時にはSpatial Regularization Block の出力にチャンネル方向 softmax を適用し,argmax でピクセルラベルを決定する。

Decoupling Zero-Shot Semantic Segmentation (CVPR2022)[2]

従来手法では、ピクセルごとにsemantic word embeddingと対応付けして分類。ただし、人間はセグメント単位で認識するため、pixel-level は直感的でない。また、CLIPのようなvision-language modelsはpixel単位ではなく、segmentやimageレベルでの特徴に適している。
そこで、ピクセルをグループ化してその後でsegmentごとにsemantic labelingを行う
ピクセルを class-agnostic にグルーピングし、その後、セグメントごとにsemantic labelを割り当てるZegformerを提案。

Zegformerでは、Maskformerから得られるsegment-level embeddingsに対してprojection layerを適用することでmask embeddingsとsemantic embeddingsを生成する。得られたmask embeddingsとpixel decoderの特徴マップからclass-agnostic maskを推定する。
一方、Text encoderにはprompt template((e.g. “A photo of a {class name} in the scene”)が入力され、text embeddingsを得る。また、“no object”領域のために、extra learnable embeddingsも導入されている。
最終的にtext embeddings、learnable embeddingsとsemantic embeddingsのcosine similarityを計算することでclass probabilityを計算する。

GroupViT: Semantic Segmentation Emerges from Text Supervision(CVPR2022)[3]

セグメンテーションのようなタスクでは、per-pixel annotationを人手でつけることはコストが高く、また、セグメンテーションモデルは少数カテゴリのみを学習して未知カテゴリには対応できない。
そこで、ピクセルレベルのラベルを使わずにtext supervisionのみでzero-shot semantic segmentationを行うGroupViTを提案。

入力画像は重複領域のないNパッチに分割され、linear projectionによってinput image tokensに変換される。
これらimage tokensはlearnable group tokensとともにTransformer layerおよびGrouping Blockによって段階的に処理される。
Transformer layerではimage tokensとM個のlearnable group tokensのattentionを行う。その後Grouping Blockでは、group tokensとの類似度に基づいてimage tokensをM個にグループ化した、segment tokensを生成する。このプロセスは、segment tokensを次の段階のinput tokenとして再びTransformer layerとGrouping Blockに渡すことで繰り返される。
なお、group tokensは深い層になるごとに徐々に数が減っていく。
最終的に得られたsegment tokensはAvgPoolingMLPによってfinal global image representationへと変換される。これと対応するext embeddingとの類似度を計算し、マッチしたimage-textペアはお互い近くなるように、そうでないペアは遠くなるようにcontrastive learningによって学習が行われる。

推論時

A Simple Baseline for Open-Vocabulary Semantic Segmentation with Pre-trained Vision-language Model (ECCV2022)[4]

Scaling Open-Vocabulary Image Segmentation with Image-Level Labels (ECCV2022)[5]

CLIPやALIGNはvisual-semantic alignmentsの学習前に、ピクセルをグルーピングするステップが欠落しているため、「何が写っているか」は分かっても「どこに写っているか」を高精度に示すことができない。
本研究では、画像をピクセルラベルではなく,任意のテキストで参照できる領域で表現し,キャプションだけでも大規模に学習できるopen-vocabulary image segmentationモデルであるOpenSegを提案。

Image Backboneからimage featuresを計算しつつ、class-agnostic maskも推定。これらの計算結果から、class-agnostic mask領域ごとの特徴を計算し、N個のsegmentation region featureを作る。
また、画像に対応するキャプションから名詞と形容詞にあたる単語を抜き出したリストを作成し、pretrained text encoderでword featureを計算。
その後、segmentation region featureとword featureのcosine similarityを計算し、どのキャプションがどの領域にあたるかを推定。

Open-Vocabulary Semantic Segmentation with Mask-adapted CLIP (CVPR2023)[6]


これまでのOpen-Vocabulary Segmentationモデルはclass-agnostic mask proposalsを生成し、CLIPでopen-vocabulary classificationを行う方式であった。
しかし、GTマスクをregion proposalとしてCLIPで識別してもmIoUは20%程度に留まる一方で、MaskFormerの出力マスクにGTクラスを割り当てると66%近くの性能が出ることを確認し、ボトルネックはCLIPがマスク画像を識別できないことであるということがわかった。
CLIPは最小限のaugmentationを使用して自然画像で事前学習を行っているのに対し、mask proposalsは元画像からcropやリサイズされ、さらにnoisyなsegmentation masksを使用していることが原因であると考えられる。
そこで、(i)マスク付き画像で CLIP を適応するmask-adapted CLIPと、(ii)背景ゼロパッチを学習可能トークンに置換するMask Prompt Tuningを組み合わせたOVSegを提案。
具体的には、COCO Captionsから抽出した名詞と、事前学習済みMaskFormerが生成するclass-agnostic maskをCLIPの類似度で対応付け、得られた(masked image, noun)ペアでCLIP画像エンコーダをファインチューニングすることでマスク入力への汎化性能を獲得する。一方、Mask Prompt Tuningはbackground領域に学習可能tokenを適用し、CLIPの重みを変更せずに背景情報欠落を緩和。


推論時は既存手法と同様にMaskFormerとCLIPを使用して、image embeddingとtext embeddingのコサイン類似度を計算する。さらに、各マスクで画像をcrop/resizeしてCLIP(+MPT)に入力し、得られた text embeddingとの内積から最終予測を得る。
ファインチューニングにはCOCOに含まれないクラスも含め、キャプションから抜き出した多様な名詞を用いる。
実験ではMPT単独でも性能向上が確認された。また、MPTとmask-adapted CLIPを併用するとOpen-Vocabularyセグメンテーション性能がさらに向上。

Generalized Decoding for Pixel, Image, and Language (CVPR2023)[7]

Side Adapter Network for Open-Vocabulary Semantic Segmentation (CVPR2023)[8]

two-stage系手法(SimSeg、MaskCLIPなど)は、mask generatorでclass-agnostic mask proposalsを作り、その後にCLIPで各proposalのカテゴリを認識する。しかしmask generatorがCLIPから独立しているためCLIP unawareであり、かつ推論が遅く計算コストも大きい。またCLIPをsegmentation用に fine-tuneするとopen-vocabulary性能が劣化するという課題があった。
そこでSide Adapter Network(SAN)を提案。CLIPの重みを固定したまま、その横に軽量なside networkを付加し、学習することでCLIP-awareなmask predictionとカテゴリ認識を両立させる。

Side Adapter Network:

  • Mask proposal branch
    learnable query tokensとCLIPの浅い層のvisual tokensの内積を計算し、N個の mask proposals を生成。
  • Attention bias branch
    同じqueryから生成したattention biasをCLIPの深い層のself-attentionに注入し、各maskのproposal-wise logitsを得る。
    mask predictionとmask recognitionをdecoupledに設計し、認識に必要な領域とmask自体の領域の不一致に対応。
  • Shadow CLS tokens (SLS)
    CLIP の [CLS] を複製した SLS tokens を導入。SLS はvisual tokensから一方向に更新され、attention biasにより各maskのクラスを推定。
  • Asymmetric resolution
    segmentation では高解像度が必須だが、CLIPは224²を想定。
    CLIP には低解像度、SANには高解像度(640²)を入力することで性能を維持しつつ計算量を抑制。
  • 学習
    CLIP重みは固定し、SANのみを学習。

Open-Vocabulary Panoptic Segmentation with Text-to-Image Diffusion Models (CVPR2023)[9]


Open-vocabulary recognitionでは、学習時に出現しない無限に近いカテゴリまで理解する能力が求められる。しかしCLIPなどのtext-image discriminative modelsは個別領域の分類には強い一方で、画素レベルの空間的関係を十分に捉えられず、open-vocabulary panoptic segmentationに対するボトルネックとなっている。一方、Stable Diffusionなどのtext-to-image diffusion modelsはテキストと画像のクロスアテンションを通じて学習しており、その内部表現が空間的にも意味的にも豊かなことが知られている。しかし、この潜在表現を下流のセグメンテーションに活用した試みはほぼ無かった.

そこで、ODISE (Open-vocabulary DIffusion-based panoptic SEgmentation)を提案。
ODISEはtext-to-image diffusion model(Stable Diffusion UNet)とtext-image discriminative model(CLIP)をいずれも重みを固定したまま活用し、28Mパラメータfine-tuningのみでOpen-Vocabulary Panoptic Segmentationを実現。

手法

  1. Implicit Captioner: キャプションの無い入力画像に対し、CLIP image encoderと学習可能なMLPを用いてimplicit text embeddingを生成。これをdiffusion UNetへ入力し、時間ステップt=0で得たvisual representation fを下流に供給。
  2. Mask Generator: Mask2Formerを採用し、fからクラス非依存のバイナリマスクN = 100と対応するmask embedding zを生成し、binary mask lossを適用。
  3. Mask Classification
  • Category Label Supervision: zとtext encoderで得た埋め込みとの類似度をCross-Entropy (L_C) で学習。
  • Image Caption Supervision: 画像キャプション中の名詞集合とzの類似度をgrounding lossで弱教師あり学習。
  1. Open-Vocabulary Inference: 予測 mask ごとに (i) diffusion modelのembedding と (ii) CLIP feature mapをマスクプーリングしたembeddingの両方で類似度を計算。
    Geometric meanで最終カテゴリを決定し,thing/stuff を統合してpanoptic出力を得る。

A Simple Framework for Open-Vocabulary Segmentation and Detection (ICCV2023)[10]


物体検出とセグメンテーションを統合的に学習するOpen-VocabularyモデルであるOpenSeeDを提案。
タスク間の性質の違いに対して、デコーダ内部でForeground QueryとBackground Queryを分離し、別々にマッチング・学習を行うDecoupled Foreground and Background Decodingを導入。
また、アノテーション粒度の違い(boxのみ、box+mask)に対しては、Conditioned Mask Decodingにより検出データからもマスク生成が可能な学習方式を設計。
これらの工夫により、OpenSeeDは検出とセグメンテーションの両方のデータを同時に活かしながら、単一モデルで二つのタスクに対するOpen-Vocabulary性能を実現。
https://zenn.dev/cvdlhub/articles/00295b27fb4da5

CAT-Seg: Cost Aggregation for Open-Vocabulary Semantic Segmentation (CVPR2024)[11]

これまで、Open Vocabulary Segmentationでは、image-levelの認識能力からpixel-levelのtaskへと拡張するために、CLIP encoderをfine-tuningすると既知クラスにoverfittingしてしまう問題があった。そのため、ほとんどの手法がCLIP encoderを固定して使用している。
新しいcost-based frameworkを導入し、fine-tuningによってCLIPをopen-vocabulary semantic segmentationに適応させた、Cost AggregaTion approach for open-vocabulary semantic Segmentation(CAT-Seg)を提案。cost volumeベースの手法を使用することで、CLIPがfine-tuningによってopen vocabulary segmentationに適応できることが分かった。

(a)CLIPのCost Volume、(b)fine-tuning済みのCLIPのCost Volume、(c)CAT-Segによって集約されたcost の可視化。上段は既知クラスの椅子、下段は未知クラスのsofaを示している。

手法


画像を最終層のpoolingを除去したCLIP image encoderに入力し、image embeddingを得る。各テキストクラスをCLIP text encoderで埋め込み、image embeddingの各ピクセルとtext embeddingの各クラスに関するcosine similarity計算してcost volumeを得る。
Cost Volumeのaggregationは、spatial aggregationとclass aggregationの2つのモジュールに分かれている。

Spatial Cost Aggregation

image-text cost volumeにおける、画像のspatial smoothnessを考慮した手法。cost volumeに対して、swin transformerのself-attentionを適用する。attentionはclassごとに個別に行われる。

Class Cost Aggregation

image-text cost volumeにおける、異なるクラス間の関係性を捉えるための手法。cost volumeに対して、position embeddingを使用しないlinear transformer layerを適用する。

Upsampling decoder

Aggregated costをbilinear upsampleし、CLIP encoderの中間特徴とconcat → 3×3 convを繰り返して高解像度マスクを生成。

結果

Analysis on fine-tuning of CLIP


image encoder、text encoder両方のquery、value projectionのみをfine-tuningした場合に最も性能が高い。

SED: A Simple Encoder-Decoder for Open-Vocabulary Semantic Segmentation (CVPR2024)[12]

Open-vocabulary semantic segmentationにおける既存手法はtwo-stageとsingle-stageの手法に分かれているが、どちらの手法にもそれぞれ課題がある。
OVSegなどのtwo-stage手法は、はじめにclass-agnostic mask proposalsを生成し、それらにpre-trained vision-language modelsを適用することで各proposalのカテゴリを識別している。Mask proposalとclassificationに2つの別々のネットワークを用いるため計算効率が悪く、さらに、文脈情報を十分に活用していない。
Single-stage手法であるMaskCLIPはCLIP image encoderの最終層のglobal poolingを削除し、得られたembeddingsとtext embeddingsを使用して直接的にpixelレベルのsegmentation mapを推定する。また、CAT-Segはpixel-level image-text cost mapを作成し、cost mapを空間方向及びクラス方向の集約によって洗練することで良好な性能を達成している。一方、これらのone-stage手法はplain ViTをbackboneとして採用しており、局所的な特徴抽出や低解像な入力への弱さに対して問題がある。CAT-Segはこれに対処するために空間情報を補完する追加ネットワークを導入しているが、これは計算コストの増加を引き起こす。また、CAT-Segはcost mapを導入しているため、カテゴリ数が多くなると急激に計算コストが増加する。
これらを解決するために、本論文ではhierarchical encoder-based cost map generationとgradual fusion decoder with category early rejectionを提案。
hierarchical encoder-based cost map generationでは、ViTの代わりにCNNベースのhierarchical encoderを採用する。マルチスケール特徴を抽出し局所情報をよりよく捉え、入力画像サイズに対しても線形な計算コストとすることができる。
gradual fusion decoderではhierarchical backboneから得られるマルチスケール特徴マップとcost mapを組み合わせる。また、デコーダの浅い層において画像内に存在しないカテゴリをcost mapの計算から削除することによって推論速度の向上を図るcategory early rejectionを導入。

hierarchical encoderにはConvNeXtを採用。Image embeddingsとtext embeddingsのcosine類似度からカテゴリに対するピクセルごとのcost mapを計算する。
デコーダへのskip connectionについて、直接勾配の逆伝播をimage encoderへ行うとopen-vocabulary semantic segmentationの性能が損なわれることがCAT-Segで示されているため、stop-gradientを行っている。


Category Early Rejection
Cost map計算時にはすべてのカテゴリについて考慮しているが、実際に画像に含まれるカテゴリは数個である。
Category Early Rejectionでは訓練時にはデコーダの各層に補助的なconvolutional branchを追加し、segmentation mapを予測して学習を行う。推論時には各ピクセルのtop-kカテゴリのみを残したcost mapとすることで推論速度を向上。


先行研究に対して性能および推論速度向上を達成。

Exploring Simple Open-Vocabulary Semantic Segmentation (CVPR2025) [13]

Open-Vocabulary Segmentationにおける主な障壁は、すべてのラベルについてピクセルレベルのアノテーションを提供するデータセットを構築することが不可能であること。また、これまでの手法はCLIPのようなimage-text alignmentを学習したモデルの採用や、Open-Vocabulary Segmentationのためのcustom-designed modelsを使用してきた。
本論文では人手のアノテーションやCLIPのようなimage-level VLMを使用しない、pseudo-maskと言語を使用してMaskFormerを学習させるシンプルなフレームワークS‐Segを提案。

S-Segはweb datasetにおけるimage-text pairsをもとに学習し、人手でのアノテーションを使用しない。
pseudo-mask generatorから生成されたsegmentation mapsをmask supervisionとして使用。また、language modelから得られるlanguage embeddingsを使用してMaskFormerが出力するmask featuresとのimage-text contrastive learningを行う。
通常の設定であればmaskとlabelのアノテーションが紐づけされているが、ここでのpseudo-maskと言語はそうでないことに注意。
Pseudo-mask generatorにはDINOで学習済みのViTを使用。出力トークンに対してK-Meansを行い、クラスタリングされたマップをmask supervisionとする。

推論時の概要図


S-Seg+はtest時にself-trainingを行った結果。Self-trainingでは評価データセットにおけるtrain-setに対してS-Segの出力結果を疑似GTとして使用する。

LPOSS: Label Propagation Over Patches and Pixels for Open-vocabulary Semantic Segmentation (CVPR2025) [14]




Semantic Library Adaptation: LoRA Retrieval and Fusion for Open-Vocabulary Semantic Segmentation (CVPR2025) [15]

Open vocabulary(OV) semantic segmentationモデルは、学習したデータセットとは異なる分布のデータ(domain shift)に対しては性能が低下しやすく、これは実世界のアプリケーションにおいて問題となる。また、OV semantic segmentationに特化したドメイン適応手法は提案されていない。
そこで、SemLAを提案。
example
SemLAでは、まず各データセットにおいてLoRAを用いた個別のadapterを学習し、それぞれのドメインを表現するための特徴としてCLIP embeddingsのセントロイドを計算する。各LoRA adapterとセントロイドはペアで保存しておき、LoRA Adapters Libraryを構築する。テスト時には入力画像のCLIP embeddingsとセントロイドの距離をもとにlibraryから使用するadapterを選択し、ドメインに適応した推論を行う。

https://zenn.dev/cvdlhub/articles/98dd8ab71dbb2b

Mask-Adapter: The Devil is in the Masks for Open-Vocabulary Segmentation (CVPR2025) [16]



ADE20KでのUpper bound analysis
これまでのOpen-Vocabulary Segmentationモデルはmask croppingやmask poolingを使用してmask embeddingsを構成してきたが、それらはupper bound(GTを用いたclosedな実験)においても性能が限られている。
mask croppingはmasked imageと、CLIPの事前学習で使用されるnatural imagesの間のギャップが大きいことが原因であると考えられる。
また、mask poolingはfeature aggregationの際に、詳細なsemanticおよびcontextual情報が得られないことが原因であると考えられる。
そこで、このボトルネックを解消するために、mask embeddingsにsemantic activation mapsを使用する新しい手法であるMask-Adapterを提案する。
Mask Adapterの導入によって、以下の利点がある。

  1. 画像全体を考慮した特徴集約
    マスク領域だけでなく、周辺の文脈も含めてmask embeddingを構成することで、より豊かなcontext情報を取り入れることができる。
  2. 重要領域の選択的強調
    mask poolingとは異なり、semantic activation mapsにより意味的に重要な領域を強調し、情報量の少ない領域を抑制することにより特徴識別性能が向上する。


SparseInstと同じように、CLIP特徴マップからactivation mapを作成。その後、activaton mapとCLIP特徴マップの内積によってmask embeddingsを構成。
また、ground truthマスクと予測マスクembeddingsを近づけるために、cosine similarityを使用した損失も提案。

脚注
  1. Li, Boyi, et al. "Language-driven semantic segmentation." arXiv preprint arXiv:2201.03546 (2022). ↩︎

  2. Ding, Jian, et al. "Decoupling zero-shot semantic segmentation." Proceedings of the IEEE/CVF conference on computer vision and pattern recognition. 2022. ↩︎

  3. Xu, Jiarui, et al. "Groupvit: Semantic segmentation emerges from text supervision." Proceedings of the IEEE/CVF conference on computer vision and pattern recognition. 2022. ↩︎

  4. Xu, Mengde, et al. "A simple baseline for open-vocabulary semantic segmentation with pre-trained vision-language model." European Conference on Computer Vision. Cham: Springer Nature Switzerland, 2022. ↩︎

  5. Ghiasi, Golnaz, et al. "Scaling open-vocabulary image segmentation with image-level labels." European conference on computer vision. Cham: Springer Nature Switzerland, 2022. ↩︎

  6. Liang, Feng, et al. "Open-vocabulary semantic segmentation with mask-adapted clip." Proceedings of the IEEE/CVF conference on computer vision and pattern recognition. 2023. ↩︎

  7. Zou, Xueyan, et al. "Generalized decoding for pixel, image, and language." Proceedings of the IEEE/CVF conference on computer vision and pattern recognition. 2023. ↩︎

  8. Xu, Mengde, et al. "Side adapter network for open-vocabulary semantic segmentation." Proceedings of the IEEE/CVF conference on computer vision and pattern recognition. 2023. ↩︎

  9. Xu, Jiarui, et al. "Open-vocabulary panoptic segmentation with text-to-image diffusion models." Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition. 2023. ↩︎

  10. Zhang, Hao, et al. "A simple framework for open-vocabulary segmentation and detection." Proceedings of the IEEE/CVF International Conference on Computer Vision. 2023. ↩︎

  11. Cho, Seokju, et al. "Cat-seg: Cost aggregation for open-vocabulary semantic segmentation." Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition. 2024. ↩︎

  12. Xie, Bin, et al. "Sed: A simple encoder-decoder for open-vocabulary semantic segmentation." Proceedings of the IEEE/CVF conference on computer vision and pattern recognition. 2024. ↩︎

  13. Lai, Zihang. "Exploring Simple Open-Vocabulary Semantic Segmentation." arXiv preprint arXiv:2401.12217 (2024). ↩︎

  14. Stojnić, Vladan, et al. "LPOSS: Label Propagation Over Patches and Pixels for Open-vocabulary Semantic Segmentation." arXiv preprint arXiv:2503.19777 (2025). ↩︎

  15. Qorbani, Reza, et al. "Semantic Library Adaptation: LoRA Retrieval and Fusion for Open-Vocabulary Semantic Segmentation." arXiv preprint arXiv:2503.21780 (2025). ↩︎

  16. Li, Yongkang, et al. "Mask-Adapter: The Devil is in the Masks for Open-Vocabulary Segmentation." arXiv preprint arXiv:2412.04533 (2024). ↩︎

Discussion