Introduction
Few-shot segmentation (FSS) aims to segment novel object categories using only a limited number of annotated support examples. While the Segment Anything Model (SAM) has revolutionized class-agnostic segmentation, it possesses a significant "semantic blind spot"—it lacks the inherent category-level understanding required to distinguish specific classes in open-world scenarios. Previous attempts to adapt SAM for FSS often relied on prompts derived exclusively from support images, leading to two primary issues: limited semantic representation and biased decoding, where models tend to hallucinate familiar "base classes" when encountering novel ones.
To address these challenges, researchers have introduced Unbiased Semantic Decoding (USD). This framework integrates the precise geometric masking capabilities of SAM with the rich, high-level semantic knowledge of CLIP, effectively overcoming the limitations of previous class-agnostic approaches.
Methodology
USD leverages frozen vision foundation models (SAM and CLIP) and introduces three lightweight, trainable components to bridge the gap between geometric precision and semantic understanding. Crucially, the core encoders and decoders of SAM and CLIP remain frozen, with only small adapter layers requiring training.
Core Components:
- Global Supplement Module (GSM): This module utilizes CLIP’s image-level features to provide a "category indicator." By mapping CLIP’s broad semantic understanding into SAM’s feature space, it helps the model identify the general class of the target object.
- Local Guidance Module (LGM): To solve the spatial localization problem, LGM calculates pixel-level semantic affinity between the query image and target text descriptions (e.g., "a photo of a cow"). This creates a probability map that guides the SAM decoder to the correct region.
- Visual-Text Target Prompt Generator (VTPG): This generator synthesizes multi-modal prompts by interacting target text embeddings with visual features from both the support and query images. This "query-aware" approach makes the system more robust to variations in object appearance, lighting, and pose.
Experimental Results
The USD framework was evaluated on the PASCAL-5ⁱ and COCO-20ⁱ benchmarks, testing both 1-shot and 5-shot scenarios. The results demonstrate that USD significantly outperforms existing state-of-the-art (SOTA) methods.
On the PASCAL-5ⁱ dataset, USD achieved a Mean Intersection over Union (mIoU) of 78.4% for 1-shot tasks, representing a 6.5% improvement over the previous best SAM-based method, VRP-SAM. On the more complex COCO-20ⁱ dataset, USD set a new benchmark with an mIoU of 57.9% (1-shot).
Key Insights and Discussion
- The Query-Aware Advantage: Unlike traditional FSS models that rely solely on support images, USD’s query-aware prompting allows it to adapt to the specific context of the target image, drastically reducing base-class bias.
- Foundation Model Synergy: The research highlights the complementary nature of SAM and CLIP. CLIP provides the semantic "what," while SAM provides the geometric "how," resulting in a more holistic segmentation pipeline.
- Efficiency: By leveraging pre-trained weights and training only lightweight adapters, USD converges in approximately 50 epochs, nearly twice as fast as many traditional FSS architectures.
Limitations and Future Work
While USD sets a new standard for FSS, it is not without limitations. The model occasionally suffers from over-segmentation, where visually similar non-target objects (e.g., a fork vs. a knife) are incorrectly included in the mask. Additionally, the model's high sensitivity can lead to the segmentation of unannotated background objects, which, while semantically correct, can lower traditional accuracy scores. Future research will focus on refining textual prompts and developing better suppression techniques for non-target foreground areas.
Summary updated