Skip to main content

IBUG: Instance-Based Uncertainty Estimation for Gradient-Boosted Regression Trees

PyPi version Python version Github License Build

IBUG is a simple wrapper that extends any gradient-boosted regression trees (GBRT) model into a probabilistic estimator, and is compatible with all major GBRT frameworks including LightGBM, XGBoost, CatBoost, and SKLearn.

thumbnail

Install

pip install ibug

Quickstart

from ibug import IBUGWrapper
from xgboost import XGBRegressor
from sklearn.datasets import load_diabetes
from sklearn.model_selection import train_test_split

# load diabetes dataset
data = load_diabetes()
X, y = data['data'], data['target']

# create train/val/test split
X_train, X_test, y_train, y_test = train_test_split(X, y, test_size=0.1, random_state=1)
X_train, X_val, y_train, y_val = train_test_split(X_train, y_train, test_size=0.1, random_state=1)

# train GBRT model
model = XGBRegressor().fit(X_train, y_train)

# extend GBRT model into a probabilistic estimator
prob_model = IBUGWrapper().fit(model, X_train, y_train, X_val=X_val, y_val=y_val)

# predict mean and variance for unseen instances
location, scale = prob_model.pred_dist(X_test)

# return k highest-affinity neighbors for more flexible posterior modeling
location, scale, train_idxs, train_vals = prob_model.pred_dist(X_test, return_kneighbors=True)

License

Apache License 2.0.

Reference

Brophy and Lowd. Instance-Based Uncertainty Estimation for Gradient-Boosted Regression Trees. NeurIPS 2022.

@inproceedings{brophy2022ibug,
  title={Instance-Based Uncertainty Estimation for Gradient-Boosted Regression Trees},
  author={Brophy, Jonathan and Lowd, Daniel},
  booktitle={International Conference on Neural Information Processing Systems},
  year={2022}
}

Metadata

Release files for ibug 0.0.11

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for ibug 0.0.11
File Size Uploaded
ibug-0.0.11.tar.gz 369.0 kB Details

Built distributions (wheels)

Table of built distributions (wheels) for ibug 0.0.11
File
ibug-0.0.11-cp310-cp310-win_amd64.whl CPython 3.10 CPython 3.10 Windows x86-64 Details
ibug-0.0.11-cp310-cp310-win32.whl CPython 3.10 CPython 3.10 Windows x86-32 Details
ibug-0.0.11-cp310-cp310-musllinux_1_1_x86_64.whl CPython 3.10 CPython 3.10 Linux musl 1.1+ x86-64 Details
ibug-0.0.11-cp310-cp310-musllinux_1_1_i686.whl CPython 3.10 CPython 3.10 Linux musl 1.1+ x86-32 Details
ibug-0.0.11-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.10 CPython 3.10 Linux glibc 2.17+ x86-64 Details
ibug-0.0.11-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl CPython 3.10 CPython 3.10 Linux glibc 2.17+ x86-32, Linux glibc 2.5+ x86-32 Details
ibug-0.0.11-cp310-cp310-macosx_10_9_x86_64.whl CPython 3.10 CPython 3.10 macOS 10.9+ x86-64 Details
ibug-0.0.11-cp39-cp39-win_amd64.whl CPython 3.9 CPython 3.9 Windows x86-64 Details
ibug-0.0.11-cp39-cp39-win32.whl CPython 3.9 CPython 3.9 Windows x86-32 Details
ibug-0.0.11-cp39-cp39-musllinux_1_1_x86_64.whl CPython 3.9 CPython 3.9 Linux musl 1.1+ x86-64 Details
ibug-0.0.11-cp39-cp39-musllinux_1_1_i686.whl CPython 3.9 CPython 3.9 Linux musl 1.1+ x86-32 Details
ibug-0.0.11-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.9 CPython 3.9 Linux glibc 2.17+ x86-64 Details
ibug-0.0.11-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl CPython 3.9 CPython 3.9 Linux glibc 2.17+ x86-32, Linux glibc 2.5+ x86-32 Details
ibug-0.0.11-cp39-cp39-macosx_10_9_x86_64.whl CPython 3.9 CPython 3.9 macOS 10.9+ x86-64 Details

Total release size: 15.9 MB

Release files / ibug-0.0.11.tar.gz

Download URL ibug-0.0.11.tar.gz
Size 369.0 kB
Tags Source
SHA-256 checksum
How to use checksums
275c02cfe64dc39c629e9a494397ec50e8d802b11ec246c08891ab8819803a65
BLAKE2b-256 checksum
How to use checksums
5a6d4aa8f60b7349ed85429b4b6426db42d7d2537f583f8fedb8f5b27eab0429
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.0 CPython/3.9.19

Release files / ibug-0.0.11-cp310-cp310-win_amd64.whl

Download URL ibug-0.0.11-cp310-cp310-win_amd64.whl
Size 563.9 kB
Tags CPython 3.10 Windows x86-64
SHA-256 checksum
How to use checksums
fbc5efd95d8b5e78fc2be8da67fb698401aedd72338aa19c27961d762a57483a
BLAKE2b-256 checksum
How to use checksums
33f6a5ec484f15d7ba8070464aeaa657b42e0cb49e48fc1e721e5632823298f0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.0 CPython/3.9.19

Release files / ibug-0.0.11-cp310-cp310-win32.whl

Download URL ibug-0.0.11-cp310-cp310-win32.whl
Size 534.4 kB
Tags CPython 3.10 Windows x86-32
SHA-256 checksum
How to use checksums
9da7602cea74b377fde4f34795e015cae7e8b56bcd2db76ad8e98dfab7c86293
BLAKE2b-256 checksum
How to use checksums
e5fa72b214fa457bc4071ce86a26efbdb302ca3a8d92a53e5162263e467d62f3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.0 CPython/3.9.19

Release files / ibug-0.0.11-cp310-cp310-musllinux_1_1_x86_64.whl

Download URL ibug-0.0.11-cp310-cp310-musllinux_1_1_x86_64.whl
Size 1.5 MB
Tags CPython 3.10 Linux musl 1.1+ x86-64
SHA-256 checksum
How to use checksums
d90b43c2736325ebc4d8f63f14cd3d2684f43fc71267ea185b6559e6283520d0
BLAKE2b-256 checksum
How to use checksums
a9f7346b7154b250739ef4ee62896cbc008831fd076fb47c24304f259867f124
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.0 CPython/3.9.19

Release files / ibug-0.0.11-cp310-cp310-musllinux_1_1_i686.whl

Download URL ibug-0.0.11-cp310-cp310-musllinux_1_1_i686.whl
Size 1.5 MB
Tags CPython 3.10 Linux musl 1.1+ x86-32
SHA-256 checksum
How to use checksums
ab445e4082516cc3a85d3e76eaa5871f96cf7fb11646a54717bb3aa6904988bc
BLAKE2b-256 checksum
How to use checksums
184931db80da1bb7e7f90c851585f664dbcc5e78b01dd9cffa1e51d7cbc78356
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.0 CPython/3.9.19

Release files / ibug-0.0.11-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL ibug-0.0.11-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 1.5 MB
Tags CPython 3.10 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
16c30f120400bf0d74e20ba910ba038658d6dc74e02966da1954dc55fa02a8b5
BLAKE2b-256 checksum
How to use checksums
9c9e3c8f823f2d0fee58a9011ca1d89e2783fa89e0cdd14563cbafa11e000d20
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.0 CPython/3.9.19

Release files / ibug-0.0.11-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl

Download URL ibug-0.0.11-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl
Size 1.5 MB
Tags CPython 3.10 Linux glibc 2.17+ x86-32 Linux glibc 2.5+ x86-32
SHA-256 checksum
How to use checksums
aebda705b225502af185ced51c226c6fb3385356157689bd3a495d1b6566d067
BLAKE2b-256 checksum
How to use checksums
03eae92281211ddd31a5faa4e4646b0e12b2496294fc5256c9230074e2e8a78b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.0 CPython/3.9.19

Release files / ibug-0.0.11-cp310-cp310-macosx_10_9_x86_64.whl

Download URL ibug-0.0.11-cp310-cp310-macosx_10_9_x86_64.whl
Size 596.9 kB
Tags CPython 3.10 macOS 10.9+ x86-64
SHA-256 checksum
How to use checksums
212d44dfe0fe84fa7d1822a5749efc473bdd93e003e5e4625d7a38d4a45bf977
BLAKE2b-256 checksum
How to use checksums
fab596d43cdbc60435219204c6f47053601973270c9efa2c04372262d292ea0d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.0 CPython/3.9.19

Release files / ibug-0.0.11-cp39-cp39-win_amd64.whl

Download URL ibug-0.0.11-cp39-cp39-win_amd64.whl
Size 565.0 kB
Tags CPython 3.9 Windows x86-64
SHA-256 checksum
How to use checksums
3807ec403e244bd4ad0dedbd13e3110f7b36539b10b2131bf1a32beac5a2908b
BLAKE2b-256 checksum
How to use checksums
d47c077d0861c80088ec55c596e333cef2555b09b003bd0a84d9a159fa9b45e0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.0 CPython/3.9.19

Release files / ibug-0.0.11-cp39-cp39-win32.whl

Download URL ibug-0.0.11-cp39-cp39-win32.whl
Size 535.5 kB
Tags CPython 3.9 Windows x86-32
SHA-256 checksum
How to use checksums
1715827e798fdd0fd9006aa573cc3ac9cfb7e29a45477692e6aa05b0564d608c
BLAKE2b-256 checksum
How to use checksums
cb4080daca105f7fd27bf2e43ef3059ab1b8ecc75765546bfe446d5f17087fd6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.0 CPython/3.9.19

Release files / ibug-0.0.11-cp39-cp39-musllinux_1_1_x86_64.whl

Download URL ibug-0.0.11-cp39-cp39-musllinux_1_1_x86_64.whl
Size 1.5 MB
Tags CPython 3.9 Linux musl 1.1+ x86-64
SHA-256 checksum
How to use checksums
c3fb0963c8fbe4f0d68006d3661488742f6a1f2377cb4385a774f050e6e6d8c7
BLAKE2b-256 checksum
How to use checksums
55c0b7fda9e8c5ea356cd7ac0881819a35edcd5c78f5cdaa0eefadf14de59dc0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.0 CPython/3.9.19

Release files / ibug-0.0.11-cp39-cp39-musllinux_1_1_i686.whl

Download URL ibug-0.0.11-cp39-cp39-musllinux_1_1_i686.whl
Size 1.5 MB
Tags CPython 3.9 Linux musl 1.1+ x86-32
SHA-256 checksum
How to use checksums
0c0aaf9d19d2e2756b2b30227bca3257f418fc0640fa66dd86b319a51d17ffdb
BLAKE2b-256 checksum
How to use checksums
77fac0cea6555ac13adecafa1ca61bf517d66b209fcbe8d9e8f204f38f0ecd7d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.0 CPython/3.9.19

Release files / ibug-0.0.11-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL ibug-0.0.11-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 1.5 MB
Tags CPython 3.9 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
d56aa0e52e0c3a4ea985d50a8107c332c7a609c7aa86b751f79b80c72d8e108a
BLAKE2b-256 checksum
How to use checksums
d04e421c0b7e41b94d26056a42a7eec77cefea7bea68a3515b8f00754065f5b0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.0 CPython/3.9.19

Release files / ibug-0.0.11-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl

Download URL ibug-0.0.11-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl
Size 1.5 MB
Tags CPython 3.9 Linux glibc 2.17+ x86-32 Linux glibc 2.5+ x86-32
SHA-256 checksum
How to use checksums
5eb958b5fa7fe73d50223a531e0c47671464f10386c9f8b8cde30978e1226cd2
BLAKE2b-256 checksum
How to use checksums
343879d5862215b7ae5a41644514aea84d00090e84fa1c588759cab15b0f09fe
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.0 CPython/3.9.19

Release files / ibug-0.0.11-cp39-cp39-macosx_10_9_x86_64.whl

Download URL ibug-0.0.11-cp39-cp39-macosx_10_9_x86_64.whl
Size 598.2 kB
Tags CPython 3.9 macOS 10.9+ x86-64
SHA-256 checksum
How to use checksums
b7bafaa2101f4e9d3734344937f87b3c3e85f63594a2153d592307b1a1f33335
BLAKE2b-256 checksum
How to use checksums
4f489552d7b0b073ebb7e7c6a5cfc5c8ba96de35107c6e73815a68353666396e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.0 CPython/3.9.19

Release history Release notifications | RSS feed

This release

0.0.11 This release

15 release files

0.0.9

15 release files

0.0.6

2 release files

0.0.5

15 release files

0.0.4

15 release files

0.0.3

15 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page