How to install datasets

March 24, 2026 · View on GitHub

Our study includes 16 biomedical image segmentation datasets. Place all the datasets in one directory under data to ease management. The file structure looks like

data/
├── <DATASET_NAME>/
│   ├── Prompts_Folder/
│   │   └── <prompt_files>        # text prompts (*.xlsx)
│   │
│   ├── Train_Folder/
│   │   ├── img/
│   │   │   └── <image_files>
│   │   └── label/
│   │       └── <mask_files>
│   │
│   ├── Val_Folder/
│   │   ├── img/
│   │   │   └── <image_files>
│   │   └── label/
│   │       └── <mask_files>
│   │
│   └── Test_Folder/
│       ├── img/
│       │   └── <image_files>
│       └── label/
│           └── <mask_files>

└── <DATASET_NAME_2>/
    └── (same structure as above)

Dataset Organization

Each dataset is split into training, validation, and testing splits.

The Prompts_Folder contains the text prompt files associated with each dataset. These include:

  • Prompt definitions used for data-efficiency experiments (e.g., 10%, 25%, 50% training and validation subsets)
  • Additional variant prompt designs explored in the study, such as alternative phrasing and semantic formulations

These prompt files enable flexible evaluation under different supervision regimes.

Dataset Summary

DatasetTrainValidationTestModalityOrgan
BUSI(62, 156, 312)(7, 19, 39)78UltrasoundBreast
BTMRI(273, 684, 1,369)(132, 330, 660)1,005MRIBrain
ISIC(80, 202, 404)(9, 22, 45)379DermatoscopySkin
Kvasir-SEG(80, 200, 400)(10, 25, 50)100EndoscopyColon
QaTa-COV19(571, 1,429, 2,858)(142, 357, 714)2,113X-rayChest
EUS(2,631, 6,579, 13,159)(175, 439, 879)10,090UltrasoundPancreas
BUSUC567122122UltrasoundBreast
BUSBRA1,311282282UltrasoundBreast
BUID1623535UltrasoundBreast
UDIAT1132525UltrasoundBreast
BRISC4,0001,0001,000MRIBrain
UWaterlooSkinCancer132041DermatoscopySkin
CVC-ColonDB200360EndoscopyColon
CVC-ClinicDB4906161EndoscopyColon
CVC-3006060EndoscopyColon
BKAI799100100EndoscopyColon

Download the datasets

All the datasets can be found on Hugging Face here. Download each dataset seperately:

After downloading each dataset, unzip and place each under data like the following

data/
├── BTMRI/
│   ├── Prompts_Folder/
│   │   └── <prompt_files>        # text prompts (*.xlsx)
│   │
│   ├── Train_Folder/
│   │   ├── img/
│   │   │   └── <image_files>
│   │   └── label/
│   │       └── <mask_files>
│   │
│   ├── Val_Folder/
│   │   ├── img/
│   │   │   └── <image_files>
│   │   └── label/
│   │       └── <mask_files>
│   │
│   └── Test_Folder/
│       ├── img/
│       │   └── <image_files>
│       └── label/
│           └── <mask_files>

Preprocessing EUS dataset

  • Download the EUS Healthy subset, place it in data/EUS, extract the data, and rename the extracted content to EUS_healthy

  • Download the EUS Cancer subset, place it in data/EUS, extract the data, and rename the extracted content to EUS_cancer

  • Run the preprocessing script:

    python utils/preprocess_EUS.py
    
  • Delete EUS_healthy and EUS_cancer