The official implementation of Few-Shot, Now for Real: Medical VLMs Adaptation without Balanced Sets or Validation.
📜 Medical Image Computing and Computer Assisted Intervention (MICCAI)
Julio Silva-Rodríguez1,
Fereshteh Shakeri1,2,
Houda Bahig2,
Jose Dolz1,2,
Ismail Ben Ayed1,2
1ÉTS Montréal ⋅ 2 Centre Hospitalier de l’Université de Montréal (CRCHUM)
| Conference | ArXiv |
- Install in your environment a compatible torch version with your GPU. For example:
conda create -n sstext python=3.11 -y
conda activate sstext
pip install torch==2.6.0 torchvision==0.21.0 torchaudio==2.6.0 --index-url https://download.pytorch.org/whl/cu124
git clone https://github.com/jusiro/SS-Text.git
cd SS-Text
pip install -r requirements.txt
- Configure data paths (see
./local_data/constants.py). - Download, and configure datasets (see
./local_data/datasets/README.md).
We present the basic usage here.
(a) Features extraction:
python extract_features.py --task MESSIDOR
(b) Standard adaptation:
python adapt.py --task MESSIDOR --k 4 --scenario standard --adapt SStext+
(c) Relaxed adaptation scenario:
python adapt.py --task MESSIDOR --k 4 --scenario relaxed --adapt SStext+
(d) Realistic adaptation scenario:
python adapt.py --task MESSIDOR --k 4 --scenario realistic --adapt SStext+
You will find the results upon training at ./local_data/results/.
If you find this repository useful, please consider citing the following sources.
- For the original SS-Text publication (LINK), designed for fast conformal prediction:
@inproceedings{fca25,
title={Full Conformal Adaptation of Medical Vision-Language Models},
author={Julio Silva-Rodríguez and Leo Fillioux and Paul-Henry Cournède and Maria Vakalopoulou and
Stergios Christodoulidis and Ismail {Ben Ayed} and Jose Dolz},
booktitle={Information Processing in Medical Imaging (IPMI)},
year={2025}
}
- For SS-Text+, designed for imbalanced scenarios, and realistic few-shot settings:
@inproceedings{sstext25,
title={Few-Shot, Now for Real: Medical VLMs Adaptation without Balanced Sets or Validation},
author={Julio Silva-Rodríguez and Fereshteh Shakeri and Houda Bahig and Jose Dolz and Ismail {Ben Ayed}},
booktitle={Medical Image Computing and Computer Assisted Intervention (MICCAI)},
year={2025}
}