MaxWEnt
Maximum Weight Entropy
This repository offers a packaged implementation of MaxWEnt, based on the original method described in Deep Out-of-Distribution Uncertainty Quantification via Weight Entropy Maximization (JMLR)
MaxWEnt is a method designed for epistemic uncertainty quantification in deep learning. It applies the Maximum Entropy principle to stochastic neural networks. The goal of MaxWEnt is to determine the weight distribution with the highest entropy that remains consistent with the training observations. By doing so, the method enhances the epistemic uncertainty, which generally leads to improved detection of out-of-distribution samples.
|
Regression Example |
Classification Example |
Installation and Usage
This package is available on Pypi and can be installed with the following command line:
pip install maxwent
You will need either Tensorflow or Pytorch to be installed. If both packages are installed, the Tensorflow framework of maxwent will be used by default.
To change the framework, please use the set_framework function:
- Pytorch framework
import maxwent
maxwent.set_framework("torch")
- Tensorflow framework
import maxwent
maxwent.set_framework("tf")
Reference
If you use this repository in your research, please cite our work using the following reference:
@article{JMLR:v26:23-1359,
author = {Antoine de Mathelin and Fran{\c{c}}ois Deheeger and Mathilde Mougeot and Nicolas Vayatis},
title = {Deep Out-of-Distribution Uncertainty Quantification via Weight Entropy Maximization},
journal = {Journal of Machine Learning Research},
year = {2025},
volume = {26},
number = {4},
pages = {1--68},
url = {http://jmlr.org/papers/v26/23-1359.html}
}
Metadata
Release files for maxwent 0.3.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| maxwent-0.3.0.tar.gz | 18.0 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| maxwent-0.3.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 37.1 kB
Release files / maxwent-0.3.0.tar.gz
| Download URL | maxwent-0.3.0.tar.gz |
|---|---|
| Size | 18.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
96ae0223c69cc661c2706ea105706437af3a4c6996094f2edeb6e17d9571a232
|
|
BLAKE2b-256 checksum How to use checksums |
2d438fb319f73ccfbf5bdd5e9d33b9f8b8162e528c8ca09c41df5702f2655918
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.11.11
|
Release files / maxwent-0.3.0-py3-none-any.whl
| Download URL | maxwent-0.3.0-py3-none-any.whl |
|---|---|
| Size | 19.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
91988530d1ec0cef31a16ea721cdde20dc57b7f568f0265a5b3346da486b1165
|
|
BLAKE2b-256 checksum How to use checksums |
999072df1b653e2b63bae43ad0d9bae91d24dd704d17012d21aa22814c55aa41
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.11.11
|