This repo is the official implementation of our CVPR 2022 paper "The Two Dimensions of Worst-case Training and the Integrated Effect for Out-of-domain Generalization".
- Downloader datasets (except NICO and CelebA datasets)
python3 -m domainbed.scripts.download \
--data_dir=./domainbed/data
- Download CelebA dataset from here
- Download clean NICO dataset (provided by ours) from here
- The directory structures are discribed at OoD-Bench
- Pytorch
cd /ood_bench/DomainBed
bash sweep/"dataset_name"/run.sh launch ../datasets 0
- To change the training setting, modify the scripts under /ood_bench/DomainBed/sweep.
- If you have any questions about the scripts, more details are discribed at OoD-Bench and DomainBed.
- Note: Since ResNet is not used in Colored_MNIST dataset, when you train on Colored_MNIST, uncomment line 992-1020 at algorithms.py.
python -m domainbed.scripts.collect_results\
--input_dir="sweep_output_path"