This is the training and test code for NICO challenge track1 and track2.
Download the NICO++ dataset HERE, unzip them to $data_dir
and fill it to config/base_config.py
(line 6: dataset_root = $data_dir
). The data should have the following structure:
$data_dir
├── track_1
│ ├── dg_label_id_mapping.json
│ └── public_dg_0416
│ ├── public_test_flat
│ └── train
├── track_2
│ ├── ood_label_id_mapping.json
│ └── public_ood_0412_nodomainlabel
│ ├── public_test_flat
│ └── train
Create the required environment
conda env create -f environment.yaml
conda activate nico
- pretrain for track1/2 with low input resolution for several times with different random seeds
make train_scratch track=1
- finetune for track1/2 with high input resolution
make train_finetune track=1
- collect the best models according to validation accuracy and ensemble as a merged model
make ensemble track=1
Specify $test_data_dir
, the private flat test dir, and $merged_model
, the result will be dumped in outputs/{track}/prediction.csv
make test test_data_dir=$test_data_dir track=1 merged_model=outputs/track1/ensemble/merged_model