Training Confidence-Calibrated Classifier for Detecting Out-of-Distribution Samples / ICLR 2018

Overview

Training Confidence-Calibrated Classifier for Detecting Out-of-Distribution Samples

This project is for the paper "Training Confidence-Calibrated Classifier for Detecting Out-of-Distribution Samples". Some codes are from odin-pytorch.

Preliminaries

It is tested under Ubuntu Linux 16.04.1 and Python 2.7 environment, and requries Pytorch package to be installed:

  • Pytorch: Only GPU version is available.

Downloading Out-of-Distribtion Datasets

We use download links of two out-of-distributin datasets from odin-pytorch:

Training scripts

Test scripts

  • test.sh --dataset --out_dataset --pre_trained_net
    --dataset = name of in-distribution (svhn or cifar10)
    --out_dataset = name of out-of-distribution (svhn, cifar10, lsun or imagenet)
    --pre_trained_net = path to pre_trained_net
You might also like...
Code for EMNLP'21 paper "Types of Out-of-Distribution Texts and How to Detect Them"

ood-text-emnlp Code for EMNLP'21 paper "Types of Out-of-Distribution Texts and How to Detect Them" Files fine_tune.py is used to finetune the GPT-2 mo

Codebase for Amodal Segmentation through Out-of-Task andOut-of-Distribution Generalization with a Bayesian Model

Codebase for Amodal Segmentation through Out-of-Task andOut-of-Distribution Generalization with a Bayesian Model

RODD: A Self-Supervised Approach for Robust Out-of-Distribution Detection
RODD: A Self-Supervised Approach for Robust Out-of-Distribution Detection

RODD Official Implementation of 2022 CVPRW Paper RODD: A Self-Supervised Approach for Robust Out-of-Distribution Detection Introduction: Recent studie

Learning Calibrated-Guidance for Object Detection in Aerial Images
Learning Calibrated-Guidance for Object Detection in Aerial Images

Learning Calibrated-Guidance for Object Detection in Aerial Images arxiv We propose a simple yet effective Calibrated-Guidance (CG) scheme to enhance

Neural Ensemble Search for Performant and Calibrated Predictions
Neural Ensemble Search for Performant and Calibrated Predictions

Neural Ensemble Search Introduction This repo contains the code accompanying the paper: Neural Ensemble Search for Performant and Calibrated Predictio

Towards Calibrated Model for Long-Tailed Visual Recognition from Prior Perspective

Towards Calibrated Model for Long-Tailed Visual Recognition from Prior Perspective Zhengzhuo Xu, Zenghao Chai, Chun Yuan This is the PyTorch implement

Training Cifar-10 Classifier Using VGG16

opevcvdl-hw3 This project uses pytorch and Qt to achieve the requirements. Version Python 3.6 opencv-contrib-python 3.4.2.17 Matplotlib 3.1.1 pyqt5 5.

Code for paper
Code for paper "Which Training Methods for GANs do actually Converge? (ICML 2018)"

GAN stability This repository contains the experiments in the supplementary material for the paper Which Training Methods for GANs do actually Converg

Spherical Confidence Learning for Face Recognition, accepted to CVPR2021.
Spherical Confidence Learning for Face Recognition, accepted to CVPR2021.

Sphere Confidence Face (SCF) This repository contains the PyTorch implementation of Sphere Confidence Face (SCF) proposed in the CVPR2021 paper: Shen

Comments
  • PyTorch v1.x compatibility

    PyTorch v1.x compatibility

    On one hand this removes the now deprecated function load_lua which wasn't used in the source anyway. On the other it accesses the loss via loss.data.item() instead of loss.data[0] to conform to PyTorch v1.x semantics.

    Would you be willing to merge this PR? @pokaxpoka

    opened by flxai 0
  • Why the KL Divergence Loss needs to be multiplied by number of classes?

    Why the KL Divergence Loss needs to be multiplied by number of classes?

    https://github.com/alinlab/Confident_classifier/blob/462db01967f8a96374f2ab6a534b7c81fd872d2f/src/run_joint_confidence.py#L156 I'm bit confused about why you needa multiply the KL divergence loss by the number of classes. I can't find it from the definition of your paper, could you briefly explain it?

    opened by tim5go 0
  • Cannot reproduce figures from paper

    Cannot reproduce figures from paper

    I tried to use the source code from this repository and variations, but could not reproduce the figures seen in the paper. Could you please help me with directions to reproduce Figure 3.b and Figure 3.d as shown below?

    image

    What is the command to be used with the given source code to generate the samples seen above?

    opened by flxai 1
Owner
null
Learning Confidence for Out-of-Distribution Detection in Neural Networks

Learning Confidence Estimates for Neural Networks This repository contains the code for the paper Learning Confidence for Out-of-Distribution Detectio

null 235 Jan 5, 2023
Static Features Classifier - A static features classifier for Point-Could clusters using an Attention-RNN model

Static Features Classifier This is a static features classifier for Point-Could

ABDALKARIM MOHTASIB 1 Jan 25, 2022
PyTorch implementation of Wide Residual Networks with 1-bit weights by McDonnell (ICLR 2018)

1-bit Wide ResNet PyTorch implementation of training 1-bit Wide ResNets from this paper: Training wide residual networks for deployment using a single

Sergey Zagoruyko 122 Dec 7, 2022
Official Pytorch implementation of ICLR 2018 paper Deep Learning for Physical Processes: Integrating Prior Scientific Knowledge.

Deep Learning for Physical Processes: Integrating Prior Scientific Knowledge: Official Pytorch implementation of ICLR 2018 paper Deep Learning for Phy

emmanuel 47 Nov 6, 2022
Official implementation for Likelihood Regret: An Out-of-Distribution Detection Score For Variational Auto-encoder at NeurIPS 2020

Likelihood-Regret Official implementation of Likelihood Regret: An Out-of-Distribution Detection Score For Variational Auto-encoder at NeurIPS 2020. T

Xavier 33 Oct 12, 2022
Principled Detection of Out-of-Distribution Examples in Neural Networks

ODIN: Out-of-Distribution Detector for Neural Networks This is a PyTorch implementation for detecting out-of-distribution examples in neural networks.

null 189 Nov 29, 2022
The Official Implementation of the ICCV-2021 Paper: Semantically Coherent Out-of-Distribution Detection.

SCOOD-UDG (ICCV 2021) This repository is the official implementation of the paper: Semantically Coherent Out-of-Distribution Detection Jingkang Yang,

Jake YANG 62 Nov 21, 2022
Official PyTorch implementation of the Fishr regularization for out-of-distribution generalization

Fishr: Invariant Gradient Variances for Out-of-distribution Generalization Official PyTorch implementation of the Fishr regularization for out-of-dist

null 62 Dec 22, 2022
Code for EMNLP 2021 paper Contrastive Out-of-Distribution Detection for Pretrained Transformers.

Contra-OOD Code for EMNLP 2021 paper Contrastive Out-of-Distribution Detection for Pretrained Transformers. Requirements PyTorch Transformers datasets

Wenxuan Zhou 27 Oct 28, 2022
Official repository for CVPR21 paper "Deep Stable Learning for Out-Of-Distribution Generalization".

StableNet StableNet is a deep stable learning method for out-of-distribution generalization. This is the official repo for CVPR21 paper "Deep Stable L

null 120 Dec 28, 2022