[Paper Review] SAM2-Adapter: Evaluating & Adapting Segment Anything 2 in Downstream Tasks: Camouflage, Shadow, Medical Image Segmentation, and More
SAM2-Adapter augments SAM2 with a multi-adapter design to adapt its segmentation backbone to downstream tasks, achieving new SOTA results in camouflaged object detection, shadow detection, and polyp segmentation.
The advent of large models, also known as foundation models, has significantly transformed the AI research landscape, with models like Segment Anything (SAM) achieving notable success in diverse image segmentation scenarios. Despite its advancements, SAM encountered limitations in handling some complex low-level segmentation tasks like camouflaged object and medical imaging. In response, in 2023, we introduced SAM-Adapter, which demonstrated improved performance on these challenging tasks. Now, with the release of Segment Anything 2 (SAM2), a successor with enhanced architecture and a larger training corpus, we reassess these challenges. This paper introduces SAM2-Adapter, the first adapter designed to overcome the persistent limitations observed in SAM2 and achieve new state-of-the-art (SOTA) results in specific downstream tasks including medical image segmentation, camouflaged (concealed) object detection, and shadow detection. SAM2-Adapter builds on the SAM-Adapter's strengths, offering enhanced generalizability and composability for diverse applications. We present extensive experimental results demonstrating SAM2-Adapter's effectiveness. We show the potential and encourage the research community to leverage the SAM2 model with our SAM2-Adapter for achieving superior segmentation outcomes. Code, pre-trained models, and data processing protocols are available at http://tianrun-chen.github.io/SAM-Adaptor/
Motivation & Objective
- Assess limitations of SAM2 on challenging downstream segmentation tasks (camouflage, shadow, medical imaging).
- Develop SAM2-Adapter to integrate task-specific knowledge with SAM2 using a multi-adapter strategy.
- Demonstrate SOTA performance across CAMO/CAMO COD10K, ISTD shadow detection, and kvasir-SEG polyp segmentation.
- Show that SAM2-Adapter benefits from SAM2’s backbone and specialized adapters for better generalization and composability.
Proposed method
- Use SAM2 as backbone with frozen Hiera image encoder and fine-tuned SAM2 mask decoder.
- Introduce task-specific adapters consisting of two MLPs per stage to generate prompts P^i via F^i, enabling prompt-based conditioning.
- Employ four adapters aligned to SAM2's four hierarchical stages (shared within each stage) to leverage multi-resolution features.
- Combine visual knowledge F^i (e.g., F_hfc and F_pe) to form prompts, enabling flexible task conditioning (F_i = sum_j w_j F_j).
- Train with task-specific supervision using appropriate losses (e.g., BCE for COD, BER for shadow detection, Dice/IoU for polyp segmentation).
- Evaluate on CAMO, CHAMELEON, COD10K (camouflaged object detection), ISTD (shadow detection), and kvasir-SEG (polyp segmentation).
Experimental results
Research questions
- RQ1Do SAM2's challenges in downstream segmentation persist despite its larger training corpus and architecture?
- RQ2Can a SAM2-Adapter with multi-stage adapters achieve state-of-the-art results on camouflaged object detection, shadow detection, and polyp segmentation?
- RQ3How does SAM2-Adapter compare to SAM-Adapter and SAM2 in terms of performance and adapter configuration?
- RQ4Is the performance gain due to the stronger SAM2 backbone, the adapter architecture, or their combination?
Key findings
- SAM2-Adapter achieves SOTA performance on camouflaged object detection datasets (COD10K, CAMO) and camouflaged benchmarks (CHAMELEON).
- In shadow detection (ISTD), SAM2-Adapter attains competitive results comparable to SAM-Adapter, illustrating effective prompting with SAM2 backbones.
- For polyp segmentation (kvasir-SEG), SAM2-Adapter outperforms SAM-Adapter, indicating better adaptation to medical segmentation tasks.
- Ablation shows that multi-adapter configuration (four stage-specific adapters) and SAM2 backbone both contribute to improved results versus single-adapter or SAM2-only setups.
- Table-level results indicate SAM2-Adapter surpasses SAM, SAM2, and SAM-Adapter across several metrics on camouflaged object detection tasks.
Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.