A contrastive learning based semi-supervised segmentation network for medical image segmentation This repository contains the implementation of a novel contrastive learning based semi-segmentation networks to segment the surgical tools.
Fig. 1. The architecture of Min-Max Similarity.
🔥 NEWS 🔥 The full paper is available: Min-Max Similarity
- python==3.6
- packages:
conda install pytorch==1.8.0 torchvision==0.9.0 torchaudio==0.8.0 cudatoolkit=11.1 -c pytorch -c conda-forge
conda install opencv-python pillow numpy matplotlib
- Clone this repository
git clone https://github.com/AngeLouCN/Min_Max_Similarity
We use three dataset to test its performance:
- Kvasir-instrument
- EndoVis'17
- Cochlear Implant
File structure
|-- data
| |-- kvasir
| | |-- train
| | | |--image
| | | |--mask
| | |-- test
| | | |--image
| | | |--mask
| |-- EndoVis17
| | |-- train
| | | |--image
| | | |--mask
| | |-- test
| | | |--image
| | | |--mask
| |-- cochlear
| | |-- train
| | | |--image
| | | |--mask
| | |-- test
| | | |--image
| | | |--mask
You can also test on some other public medical image segmentation dataset with above file architecture
-
Training: You can change the hyper-parameters like labeled ratio, leanring rate, and e.g. in
train_mms.py
, and directly run the code. -
Testing: You can change the dataset name in
test.py
and run the code.
Fig. 2. Visual segmentation results.
Table 1. Segmentation results.
@article{lou2022min,
title={Min-Max Similarity: A Contrastive Learning Based Semi-Supervised Learning Network for Surgical Tools Segmentation},
author={Lou, Ange and Yao, Xing and Liu, Ziteng and Noble, Jack},
journal={arXiv preprint arXiv:2203.15177},
year={2022}
}