by Feng Hong, Jiangchao Yao, Yueming Lyu, Zhihan Zhou, Ivor Tsang, Ya Zhang, and Yanfeng Wang at SJTU, Shanghai AI Lab, A*STAR, and NTU.
International Conference on Learning Representations (ICLR), 2024.
This repository is the official Pytorch implementation of SHE.
If you find our work inspiring or use our codebase in your research, please consider giving a star ⭐ and a citation.
@inproceedings{
hong2024on,
title={On Harmonizing Implicit Subpopulations},
author={Feng Hong and Jiangchao Yao and Yueming Lyu and Zhihan Zhou and Ivor Tsang and Ya Zhang and Yanfeng Wang},
booktitle={ICLR},
year={2024}
}
The project is tested under the following environment settings:
- OS: Ubuntu 18.04.5
- GPU: NVIDIA GeForce RTX 3090s
- Python: 3.7.10
- PyTorch: 1.13.1
- Torchvision: 0.8.2
- Cudatoolkit: 11.0.221
- Numpy (1.21.2)
./utils
: logger, optimizers, loss functions, and misc./models
: backbone models./data
: datasets and dataloaders./cfg
: config files./exp
: path to store experiment logs and checkpoints./train_funs
: train functions./test_funs
: test functionsmain.py
: main function
Run SHE on COCO
# COCO
PORT=$[$RANDOM + 10000]
CUDA_VISIBLE_DEVICES=0 python main.py --cfg cfg/SHE.yaml --phase train --seed 0 --port $PORT
Implement Your Own Model
- Add your model to
./models
and import the model in./models/__init__.py
.
Implement Your Own Method
- Add your method to
./train_funs
and import the method in./train_funs/__init__.py
.
Implement Other Datasets
- Add raw data to
./[_data_name]
. - Create subpopulation-imabalnced version of the dataset in
./data
. - Create dataloader in
./data/dataloader.py
.
If you have any problem with this code, please feel free to contact [email protected].