Home

Awesome

HSNet: A Hybrid Semantic Network for Polyp Segmentation

We investigate a hybrid semantic network (HSNet) that adopts both the advantages of transformer and convolutional neural networks (CNN), aiming to improve polyp segmentation. The HSNet contains a cross-semantic attention module (CSA), a hybrid semantic complementary module (HSC), and a multi-scale prediction module (MSP).

The details of this project are presented in the following paper:

HSNet: A Hybrid Semantic Network for Polyp Segmentation [CIBM'22] <br>Wenchao Zhang, Chong Fu, Yu Zheng, Fangyuan Zhang, Yanli Zhao, and Chiu-Wing Sham<br>

Usage

Setup

Python 3.8
Pytorch 1.7.1
torchvision 0.8.2

Dataset

Download the training and test datasets and move them into ./dataset/, see Google Drive/Baidu Drive [code:dr1h].

Pre-trained model

Download the pre-trained model from Google Drive/Baidu Drive [code:w4vk], and then put it in the ./pretrained_pth folder for initialization.

Train the model

Clone the repository

git clone https://github.com/baiboat/HSNet.git
cd HSNet 
bash train.sh

Test the model

cd HSNet 
bash test.sh

Evaluate the trained model

cd HSNet 
python Eval.py

Well-trained model

Baidu Drive [code:hsnt] and put the model in directory ./model_pth.

License

The source code is free for research and education use only. Any commercial use should get formal permission first.

Any advice is welcomed ^.^; please get in touch with sylgzwc@163.com or pull the question.

Acknowledgement

Thanks PraNet, EAGRNet, MSEG and Polyp-PVT for serving as building blocks of HSNet.

Citation

If you find our work/code interesting, welcome to cite our paper >^.^<

@article{zhang2022hsnet,
  title={HSNet: A hybrid semantic network for polyp segmentation},
  author={Zhang, Wenchao and Fu, Chong and Zheng, Yu and Zhang, Fangyuan and Zhao, Yanli and Sham, Chiu-Wing},
  journal={Computers in Biology and Medicine},
  volume={150},
  pages={106173},
  year={2022},
  publisher={Elsevier}
}