Medical images often exhibit distribution shifts due to variations in imaging protocols and scanners across different medical centers. Domain Generalization (DG) methods aim to train models on source domains that can generalize to unseen target domains. Recently, the segment anything model (SAM) has demonstrated strong generalization capabilities due to its prompt-based design, and has gained significant attention in image segmentation tasks. Existing SAM-based approaches attempt to address the need for manual prompts by introducing prompt generators that automatically generate these prompts. However, we argue that auto-generated prompts may not be sufficiently accurate under distribution shifts, potentially leading to incorrect predictions that still require manual verification and correction by clinicians. To address this challenge, we propose a method for 2D medical image segmentation called Self-Correcting SAM (CoSAM). Our approach begins by generating coarse masks using SAM in a prompt-free manner, providing prior prompts for the subsequent stages, and eliminating the need for prompt generators. To automatically refine these coarse masks, we introduce a generalized error decoder that simulates the correction process typically performed by clinicians. Furthermore, we generate diverse prompts as feedback based on the corrected masks, which are used to iteratively refine the predictions within a self-correcting loop, enhancing the generalization performance of our model. Extensive experiments on two medical image segmentation benchmarks across multiple scenarios demonstrate the superiority of CoSAM over state-of-the-art SAM-based methods.
翻译:医学图像常因不同医疗中心的成像协议和扫描仪差异而呈现分布偏移。领域泛化(DG)方法旨在训练源域模型,使其能够泛化至未见目标域。近期,基于提示设计的Segment Anything Model(SAM)展现出强大的泛化能力,在图像分割任务中获得广泛关注。现有基于SAM的方法试图通过引入提示生成器自动生成提示来满足手动提示的需求。然而,我们认为在分布偏移下自动生成的提示可能不够精确,可能导致仍需临床医生手动验证和修正的错误预测。为应对这一挑战,我们提出了一种名为自校正SAM(CoSAM)的二维医学图像分割方法。本方法首先以无提示方式使用SAM生成粗掩码,为后续阶段提供先验提示,从而无需提示生成器。为自动优化这些粗掩码,我们引入了模拟临床医生典型校正过程的广义误差解码器。此外,我们基于校正后的掩码生成多样化提示作为反馈,通过自校正循环迭代优化预测,从而提升模型的泛化性能。在多种场景下对两个医学图像分割基准进行的广泛实验表明,CoSAM优于当前最先进的基于SAM的方法。