Bridge the Points: Graph-based Few-shot Segment Anything Semantically
Anqi Zhang, Guangyu Gao, Jianbo Jiao, Chi Harold Liu, Yunchao Wei
Abstract
The recent advancements in large-scale pre-training techniques have significantly enhanced the capabilities of vision foundation models, notably the Segment Anything Model (SAM), which can generate precise masks based on point and box prompts. Recent studies extend SAM to Few-shot Semantic Segmentation (FSS), focusing on prompt generation for SAM-based automatic semantic segmentation. However, these methods struggle with selecting suitable prompts, require specific hyperparameter settings for different scenarios, and experience prolonged one-shot inference times due to the overuse of SAM, resulting in low efficiency and limited automation ability. To address these issues, we propose a simple yet effective approach based on graph analysis. In particular, a Positive-Negative Alignment module dynamically selects the point prompts for generating masks, especially uncovering the potential of the background context as the negative reference. Another subsequent Point-Mask Clustering module aligns the granularity of masks and selected points as a directed graph, based on mask coverage over points. These points are then aggregated by decomposing the weakly connected components of the directed graph in an efficient manner, constructing distinct natural clusters. Finally, the positive and overshooting gating, benefiting from graph-based granularity alignment, aggregate high-confident masks and filter out the false-positive masks for final prediction, reducing the usage of additional hyperparameters and redundant mask generation. Extensive experimental analysis across standard FSS, One-shot Part Segmentation, and Cross Domain FSS datasets validate the effectiveness and efficiency of the proposed approach, surpassing state-of-the-art generalist models with a mIoU of 58.7% on COCO-20i and 35.2% on LVIS-92i. The code is available in https://andyzaq.github.io/GF-SAM/.
Ask about this paper
Your agent reads all of it.
Lune indexed this paper to the last equation, along with the top-tier papers that cite it. Ask a question and the answer quotes them.
Your agent calls
Luneget_paper_fulltext
Free to start. No credit card required.
Terminal
Install the CLIlune papers fulltext ed790c64-2930-4dbe-9a17-2cbef45ea4c1Cited by top-tier papers7
- INSID3: Training-Free In-Context Segmentation with DINOv3Claudia Cuttano, Gabriele Trivigno, Christoph Reich, Daniel Cremers et al.CVPR 2026 · 13 citations
- SANSA: Unleashing the Hidden Semantics in SAM2 for Few-Shot SegmentationClaudia Cuttano, Gabriele Trivigno, Giuseppe Averta, Carlo MasoneNeurIPS 2025 · 9 citations
- Rethinking MLLM Itself as a Segmenter with a Single Segmentation TokenAnqi Zhang, Xiaokang Ji, Guangyu Gao, Jianbo Jiao et al.CVPR 2026 · 3 citations
- Unlocking the Power of SAM 2 for Few-Shot SegmentationQianxiong Xu, Lanyun Zhu, Xuanyi Liu, Guosheng Lin et al.ICML 2025
- Pointing at Parts: Training-Free Few-Shot Grounding in Multimodal LLMsShiang-Feng Tsai, Yuan-Hong Liao, Jin-Cheng Jhang, Nan Qiao et al.CVPR 2026
Builds on30
- Learning Transferable Visual Models From Natural Language SupervisionAlec Radford, Jong Wook Kim, Chris Hallacy, Aditya Ramesh et al.ICML 2021 · 47,906 citations
- An Image is Worth 16x16 Words: Transformers for Image Recognition at ScaleAlexey Dosovitskiy, Lucas Beyer, Alexander Kolesnikov, Dirk Weissenborn et al.ICLR 2021 · 21,477 citations
- Segment AnythingAlexander Kirillov, Eric Mintun, Nikhila Ravi, Hanzi Mao et al.ICCV 2023 · 13,211 citations
- SegFormer: Simple and Efficient Design for Semantic Segmentation with TransformersEnze Xie, Wenhai Wang, Zhiding Yu, Anima Anandkumar et al.NeurIPS 2021 · 9,661 citations
- Per-Pixel Classification is Not All You Need for Semantic SegmentationBowen Cheng, Alexander G. Schwing, Alexander KirillovNeurIPS 2021 · 2,196 citations
Related papers
- AoP-SAM: Automation of Prompts for Efficient SegmentationYi Chen, Muyoung Son, Chuanbo Hua, Joo-Young KimAAAI 2025 · 9 citations
- APSeg: Auto-Prompt Network for Cross-Domain Few-Shot Semantic SegmentationWeizhao He, Yang Zhang, Wei Zhuo, Linlin Shen et al.CVPR 2024
- SAM-Aware Graph Prompt Reasoning Network for Cross-Domain Few-Shot SegmentationShi-Feng Peng, Guolei Sun, Yong Li, Hongsong Wang et al.AAAI 2025 · 7 citations
- MM-Prompt: Multi-modality and Multi-granularity Prompts for Few-Shot SegmentationHang Xiong, Runmin Cong, Jinpeng Chen, Chen Zhang et al.ACM MM 2025
- PR-MaGIC: Prompt Refinement Via Mask Decoder Gradient Flow For In-Context SegmentationMinjae Lee, Sungwoo Hur, Soojin Hwang, Won Hwa KimCVPR 2026
