PyTorch re-implementation of Learning Probabilistic Ordinal Embeddings for Uncertainty-Aware Regression (CVPR 2021)[project page]
Simply create a conda environment by:
conda create -f environment.yaml
The codes is on test on pytorch==1.0.0, but higher version of pytorch should be ok.
Configure the data-related paths in scripts/*.sh
, specifically the --train-images-root
, --test-images-root
, --train-data-file
, and --test-data-file
flags.
# Train POEs / baselines
# model_type should be in ['reg', 'cls', 'rank']
bash ./scripts/train_poe.sh [id_of_gpu='0'] [model_type='cls']
bash ./scripts/train_baseline.sh [id_of_gpu='0'] [model_type='cls']
# Test POEs / baselines
# model_type should be in ['reg', 'cls', 'rank']
bash ./scripts/test_poe.sh [id_of_gpu='0'] [model_type='cls']
bash ./scripts/test_baseline.sh [id_of_gpu='0'] [model_type='cls']
python ./misc/metric_summary.py