Home

Awesome

Novel Class Discovery in Semantic Segmentation

License <img alt="PyTorch" height="20" src="https://img.shields.io/badge/PyTorch-%23EE4C2C.svg?&style=for-the-badge&logo=PyTorch&logoColor=white" />

This repository contains the official implementation of our paper:

Novel Class Discovery in Semantic Segmentation, CVPR 2022

Yuyang Zhao, Zhun Zhong, Nicu Sebe, Gim Hee Lee

Paper: ArXiv<br> Project Page: Website

Abstract: We introduce a new setting of Novel Class Discovery in Semantic Segmentation (NCDSS), which aims at segmenting unlabeled images containing new classes given prior knowledge from a labeled set of disjoint classes. In contrast to existing approaches that look at novel class discovery in image classification, we focus on the more challenging semantic segmentation. In NCDSS, we need to distinguish the objects and background, and to handle the existence of multiple classes within an image, which increases the difficulty in using the unlabeled data. To tackle this new setting, we leverage the labeled base data and a saliency model to coarsely cluster novel classes for model training in our basic framework. Additionally, we propose the Entropy-based Uncertainty Modeling and Self-training (EUMS) framework to overcome noisy pseudo-labels, further improving the model performance on the novel classes. Our EUMS utilizes an entropy ranking technique and a dynamic reassignment to distill clean labels, thereby making full use of the noisy data via self-supervised learning. We build the NCDSS benchmark on the PASCAL-5^i dataset and COCO-20^i dataset. Extensive experiments demonstrate the feasibility of the basic framework (achieving an average mIoU of 49.81% on PASCAL-5^i) and the effectiveness of EUMS framework (outperforming the basic framework by 9.28% mIoU on PASCAL-5^i).

<br>
<p align="center"> <img src="./assets/ncdss_intro.png"/ width=50%> <br /> <em> Illustration of Novel Class Discovery in Semantic Segmentation (NCDSS). </em> </p> <br>

News

Requirements

Data preparation

PASCAL VOC

We follow MaskContrast to prepare the data.

Download PASCAL VOC 2012. Unzip the dataset and ensure the file structure is as follows:

VOCSegmentation
├── images
├── SegmentationClassAug
├── saliency_supervised_model
└── sets

COCO

Download COCO 2014. Unzip the dataset and preprocess the dataset with the following command:

cd data/data_preprocess
python coco.py train2014
python coco.py val2014

Download the saliency maps from Google Drive. The saliency maps are estimated via BASNet. Specifically, we directly download the BASNet pre-trained model and inference on the COCO dataset.

The file structure is as follows:

coco
├── train2014
├── val2014
├── masks_train2014
├── masks_val2014
├── saliency_supervised_model
├── val2014.txt
└── train2014.txt

Run

Inference

You can download the pre-trained models in this paper from Google Drive. Then run the command.

sh scripts/eval.sh

Training

COCO-20i

The training and evalution scripts for coco-20i dataset are available at:

scripts/coco/*.sh

Acknowledgement

This project is based on the following open-source projects. We thank their authors for making the source code publically available.

Citation

We hope you find our work useful. If you would like to acknowledge it in your project, please use the following citation:

@inproceedings{zhao2022ncdss,
title={Novel Class Discovery in Semantic Segmentation},
author={Zhao, Yuyang and Zhong, Zhun and Sebe, Nicu and Lee, Gim Hee},
booktitle={Proceedings of IEEE Conference on Computer Vision and Pattern Recognition (CVPR)},
year={2022}}

Contact me

If you have any questions about this code, please do not hesitate to contact me.

Yuyang Zhao