To install requirements:
pip install -r requirements.txt
Please download dataset here:
Please download pre-trained weights here:
To train convolutional neural network (embedding):
cd Code
python TRAIN_crossentropy.py # for training unsupervised setting
python TRAIN_crossentropy_finetune_with_supcon.py # for finetuning
To evaluate and visualize before finetuning:
cd Code
python VISUALIZE_crossentropy.py
Clustering Results before Finetuning.
To evaluate and visualize after finetuning:
cd Code
python VISUALIZE_crossentropy_finetune_with_supcon.py
Clustering Results after Finetuning.