Home

Awesome

Deep-RTC [project page]

This repository contains the source code accompanying our ECCV 2020 paper.

<b>Solving Long-tailed Recognition with Deep Realistic Taxonomic Classifier</b>
Tz-Ying Wu, Pedro Morgado, Pei Wang, Chih-Hui Ho, Nuno Vasconcelos

@inproceedings{Wu20DeepRTC,
	title={Solving Long-tailed Recognition with Deep Realistic Taxonomic Classifier},
	author={Tz-Ying Wu and Pedro Morgado and Pei Wang and Chih-Hui Ho and Nuno Vasconcelos},
	booktitle={European Conference on Computer Vision (ECCV)},
	year={2020}
}

Dependencies

Data preparation

These datasets can be downloaded from the above links. Please organize the images in the hierarchical folders that represent the dataset hierarchy, and put the root folder under prepro/raw. For example,

prepro/raw/imagenet
--abstraction
----bubble
------ILSVRC2012_val_00014026.JPEG
------ILSVRC2012_val_00000697.JPEG
...
--physical_entity
----object
...

While CIFAR100 and iNaturalist have released taxonomies, we built the tree-type taxonomy of AWA2 and ImageNet with WordNet. All the taxonomies are provided in prepro/data/{dataset}/tree.npy, and the data splits are provided in prepro/splits/{dataset}/{split}.json. Please refer to prepro/README.md for more details. After the raw images are managed hierarchically, run

$ ./prepare_data.sh {dataset}

where {dataset}=awa2/cifar100/imagenet/inaturalist. This will automatically generate the data lists for all splits, and build the codeword matrices needed for training Deep-RTC. Note that our codes can be applied to other datasets once they are organized hierarchically.

Training and evaluation

To train and evaluate Deep-RTC, run

$ export PYTHONPATH=${PWD}/prepro:${PYTHONPATH}
$ ./run.sh {dataset}

where {dataset}=awa2/cifar100/imagenet/inaturalist. Our pretrained models can be downloaded here.