SAM-MI: A Mask-Injected Framework for Enhancing Open-Vocabulary Semantic Segmentation with SAM
Lin Chen, Yingjian Zhu, Qi Yang, Xin Niu, Kun Ding, Shiming Xiang
TL;DR
Open-vocabulary semantic segmentation seeks universal pixel-level recognition, but direct integration of SAM often yields over-segmentation and rigid mask-label coupling. SAM-MI mitigates this by a mask-injected pipeline comprising a Text-guided Sparse Point Prompter to accelerate mask generation, Shallow Mask Aggregation to merge redundant masks, and Decoupled Mask Injection to guide cost maps with SAM-derived context in low- and high-frequency channels. The approach yields strong gains across multiple OVSS benchmarks, notably a 16.7% relative mIoU improvement on MESS and a 1.6× speedup, while maintaining robustness to low-quality masks. These results demonstrate a practical pathway to couple SAM with OVSS for improved accuracy and efficiency, with potential extensions to broader dense-prediction tasks.
Abstract
Open-vocabulary semantic segmentation (OVSS) aims to segment and recognize objects universally. Trained on extensive high-quality segmentation data, the segment anything model (SAM) has demonstrated remarkable universal segmentation capabilities, offering valuable support for OVSS. Although previous methods have made progress in leveraging SAM for OVSS, there are still some challenges: (1) SAM's tendency to over-segment and (2) hard combinations between fixed masks and labels. This paper introduces a novel mask-injected framework, SAM-MI, which effectively integrates SAM with OVSS models to address these challenges. Initially, SAM-MI employs a Text-guided Sparse Point Prompter to sample sparse prompts for SAM instead of previous dense grid-like prompts, thus significantly accelerating the mask generation process. The framework then introduces Shallow Mask Aggregation (SMAgg) to merge partial masks to mitigate the SAM's over-segmentation issue. Finally, Decoupled Mask Injection (DMI) incorporates SAM-generated masks for guidance at low-frequency and high-frequency separately, rather than directly combining them with labels. Extensive experiments on multiple benchmarks validate the superiority of SAM-MI. Notably, the proposed method achieves a 16.7% relative improvement in mIoU over Grounded-SAM on the MESS benchmark, along with a 1.6$\times$ speedup. We hope SAM-MI can serve as an alternative methodology to effectively equip the OVSS model with SAM.
