An innovative few-shot anomaly detection approach is pre-sented, leveraging the pre-trained CLIP model for medical data, and adapting it for both image-level anomaly classification (AC) and pixel-level anomaly segmentation (AS). A dual-branch design is proposed to separately capture normal and abnormal features through learnable adapters in the CLIP vision encoder. To improve semantic alignment, learnable text prompts are employed to link visual features. Furthermore, SigLIP loss is applied to effectively handle the many-to-one relationship between images and unpaired text prompts, showcasing its adaptation in the medical field for the first time. Our approach is validated on multi-ple m odalities,demonstratingsuperiorperformanceoverexistingmeth-odsforACandAS,inbothsame-datasetandcross-datasetevaluations.Unlikepriorwork,itdoesnotrelyonsyntheticdataormemorybanks,andanablationstudyconfirmsthecontributionofeachcomponent.Thecodeisavailableathttps://github.com/mahshid1998/MadCLIP.

MadCLIP: Few-shot Medical Anomaly Detection with CLIP

Mahshid Shiri
Software
;
Cigdem Beyan
Supervision
;
Vittorio Murino
Supervision
2025-01-01

Abstract

An innovative few-shot anomaly detection approach is pre-sented, leveraging the pre-trained CLIP model for medical data, and adapting it for both image-level anomaly classification (AC) and pixel-level anomaly segmentation (AS). A dual-branch design is proposed to separately capture normal and abnormal features through learnable adapters in the CLIP vision encoder. To improve semantic alignment, learnable text prompts are employed to link visual features. Furthermore, SigLIP loss is applied to effectively handle the many-to-one relationship between images and unpaired text prompts, showcasing its adaptation in the medical field for the first time. Our approach is validated on multi-ple m odalities,demonstratingsuperiorperformanceoverexistingmeth-odsforACandAS,inbothsame-datasetandcross-datasetevaluations.Unlikepriorwork,itdoesnotrelyonsyntheticdataormemorybanks,andanablationstudyconfirmsthecontributionofeachcomponent.Thecodeisavailableathttps://github.com/mahshid1998/MadCLIP.
2025
Medical Anomaly Detection, CLIP, Adapters, Learnable prompts, Few-shot
File in questo prodotto:
File Dimensione Formato  
Paper-1787.pdf

solo utenti autorizzati

Tipologia: Documento in Pre-print
Licenza: Copyright dell'editore
Dimensione 587.98 kB
Formato Adobe PDF
587.98 kB Adobe PDF   Visualizza/Apri   Richiedi una copia

I documenti in IRIS sono protetti da copyright e tutti i diritti sono riservati, salvo diversa indicazione.

Utilizza questo identificativo per citare o creare un link a questo documento: https://hdl.handle.net/11562/1172990
Citazioni
  • ???jsp.display-item.citation.pmc??? ND
  • Scopus ND
  • ???jsp.display-item.citation.isi??? ND
social impact