Giter VIP home page Giter VIP logo

pycalib's Introduction

Non-Parametric Calibration for Classification

Build Status

latent_process

This repository provides the implementation of our paper "Non-Parametric Calibration for Classification" (Jonathan Wenger, Hedvig Kjellström, Rudolph Triebel). All results presented in our work were produced with this code.

Many popular classification models in computer vision and robotics are often not calibrated, meaning their predicted uncertainties do not match the probability of classifying correctly. This repository provides a new multi-class and model-agnostic approach to calibration, based on Gaussian processes, which have a number of desirable properties making them suitable as a calibration tool, such as the ability to incorporate prior knowledge.

diagram_calibration

The code was developed in Python 3.6 under macOS Mojave (10.14). You can install this Python 3 package using pip (or pip3):

pip install setuptools numpy scipy scikit-learn cython
pip install git+https://github.com/JonathanWenger/pycalib.git

Note that some dependencies need to be installed separately since our package depends on scikit-garden. Alternatively you can clone this repository with

pip install setuptools numpy scipy scikit-learn cython
git clone https://github.com/JonathanWenger/pycalib
cd pycalib
python setup.py install

For tips on getting started and how to use this package please refer to the documentation.

PCam

Due to the size of the data, only a script replicating the experiments is provided. The data can be downloaded from the PCam repository.

KITTI

The repository includes 64-dimensional features extracted from KITTI sequences compressed in a zip file datasets/kitti/kitti_data.zip.

MNIST

A script will automatically download the MNIST dataset if an experiment is run on it.

CIFAR-100

When the CIFAR-100 experiment is run, there is an option to automatically download the dataset.

ImageNet 2012

Due to the size of the data, only a script replicating the experiments is provided. The ImageNet validation data can be obtained from the ImageNet website.

The repository includes scripts that replicate the experiments found in the paper in the benchmark and figures folders.

If you use this repository in your research, please cite the following paper:

"Non-Parametric Calibration for Classification" (PDF), Jonathan Wenger, Hedvig Kjellström and Rudolph Triebel

@Article{wenger2019nonparametric,
  author        = {Jonathan Wenger and Hedvig Kjellström and Rudolph Triebel},
  title         = {Non-Parametric Calibration for Classification},
  journal       = {arXiv preprint arXiv:1906.04933},
  year          = {2019},
  archiveprefix = {arXiv},
  eprint        = {1906.04933},
  keywords      = {calibration, non-parametric, gaussian processes, classification},
  url           = {https://github.com/JonathanWenger/pycalib}
}

This work is released under the MIT License.

Please submit an issue to report bugs or request changes. Contact Jonathan Wenger ✉️ for any questions or comments.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.