TorchUncertainty: A maintained and collaborative PyTorch Library for benchmarking and leveraging predictive uncertainty quantification techniques.
Project description
TorchUncertainty is a package designed to help you leverage uncertainty quantification techniques and make your deep neural networks more reliable. It aims at being collaborative and including as many methods as possible, so reach out to add yours!
:construction: TorchUncertainty is in early development :construction: - expect massive changes, but reach out and contribute if you are interested in the project! Please raise an issue if you have any bugs or difficulties.
This package provides a multi-level API, including:
- ready-to-train baselines on research datasets, such as ImageNet and CIFAR
- deep learning baselines available for training on your datasets
- pretrained weights for these baselines on ImageNet and CIFAR (work in progress 🚧).
- layers available for use in your networks
- scikit-learn style post-processing methods such as Temperature Scaling
See the Reference page or the API reference for a more exhaustive list of the implemented methods, datasets, metrics, etc.
Installation
The package can be installed from PyPI:
pip install torch-uncertainty
Then, install the desired PyTorch version in your environment.
If you aim to contribute (thank you!), have a look at the contribution page.
Getting Started and Documentation
Please find the documentation at torch-uncertainty.github.io.
A quickstart is available at torch-uncertainty.github.io/quickstart.
Implemented methods
Baselines
To date, the following deep learning baselines have been implemented:
- Deep Ensembles
- BatchEnsemble
- Masksembles
- MIMO
- Packed-Ensembles (see blog post)
- Bayesian Neural Networks
Post-processing methods
To date, the following post-processing methods have been implemented:
- Temperature, Vector, & Matrix scaling
Tutorials
We provide the following tutorials in our documentation:
- From a Vanilla Classifier to a Packed-Ensemble
- Training a Bayesian Neural Network in 3 minutes
- Improve Top-label Calibration with Temperature Scaling
Awesome Uncertainty repositories
You may find a lot of papers about modern uncertainty estimation techniques on the Awesome Uncertainty in Deep Learning.
Other References
This package also contains the official implementation of Packed-Ensembles.
If you find the corresponding models interesting, please consider citing our paper:
@inproceedings{laurent2023packed,
title={Packed-Ensembles for Efficient Uncertainty Estimation},
author={Laurent, Olivier and Lafage, Adrien and Tartaglione, Enzo and Daniel, Geoffrey and Martinez, Jean-Marc and Bursuc, Andrei and Franchi, Gianni},
booktitle={ICLR},
year={2023}
}
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file torch_uncertainty-0.1.4.tar.gz
.
File metadata
- Download URL: torch_uncertainty-0.1.4.tar.gz
- Upload date:
- Size: 70.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | e2d3c137c003b417c9d9f7c775fe5d72ec978a8a6fe8133b68bb7b7cd5cb0b1d |
|
MD5 | d0fa195f7ad876bfa3cb4c51cd735e95 |
|
BLAKE2b-256 | 3a55dd4ad1865511fa5449d9c024ff6a88f22e0b423a07d8812985518c010e4c |
File details
Details for the file torch_uncertainty-0.1.4-py3-none-any.whl
.
File metadata
- Download URL: torch_uncertainty-0.1.4-py3-none-any.whl
- Upload date:
- Size: 127.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | dfce1617d4fb262542bd3cbd8cf0e27d64a243a69a1cf55c20897255e220f9eb |
|
MD5 | e94e4947fb364fd16dbea981cc5cf74e |
|
BLAKE2b-256 | f49f19a7dadb409a28df4d93d90aa1fd85708490cb7f113459378af85f0d39ea |