This repository is the official implementation of the paper ScribFormer: Transformer Makes CNN Work Better for Scribble-based Medical Image Segmentation. Arxiv, ResearchGate, IEEEXplore
- The ACDC dataset with mask annotations can be downloaded from ACDC.
- The scribble annotations of ACDC have been released in ACDC scribbles.
- The pre-processed ACDC data used for training could be directly downloaded from ACDC_dataset.
- The MSCMR dataset with mask annotations can be downloaded from MSCMRseg.
- The scribble annotations of MSCMRseg have been released in MSCMR_scribbles.
- The scribble-annotated MSCMR dataset used for training could be directly downloaded from MSCMR_dataset.
Some important required packages include:
- Python 3.8
- CUDA 11.3
- Pytorch 1.10.1.
- torchvision 0.11.2
- Some basic python packages such as Numpy, Scikit-image, SimpleITK, Scipy ......
Follow official guidance to install Pytorch.
To train the model, run this command:
python train.py --root_path <dataset_path> --exp <path_to_save_model> --bilinear --linear_layer --fold MAAGfold --max_epoches 200 --weight_cam_subloss 0.25 0.5 0.75 1 --weight_cam 0.1
To evaluate the model, run this command:
python test.py --bilinear --linear_layer --fold MAAGfold --exp <path_to_save_model> --save_prediction
@article{li2023lvit,
title={ScribFormer: Transformer Makes CNN Work Better for Scribble-based Medical Image Segmentation},
author={Li, Zihan and Zheng, Yuan and Shan, Dandan and Yang, Shuzhou and Li, Qingde and Wang, Beizhan and Hong, Qingqi and Shen, Dinggang},
journal={IEEE Transactions on Medical Imaging},
year={2024},
publisher={IEEE}
}