Toolkit for bias estimation in unbiased learning to rank
Project description
Personal toolkit for bias estimation in unbiased learning to rank
Installation
pip install ultr-bias-toolkit
Offline bias estimation methods
We implement multiple offline position bias estimation methods, including three intervention harvesting approaches:
from ultr_bias_toolkit.bias.naive import NaiveCtrEstimator
from ultr_bias_toolkit.bias.intervention_harvesting import PivotEstimator, AdjacentChainEstimator, AllPairsEstimator
estimators = {
"CTR Rate": NaiveCtrEstimator(),
"Pivot One": PivotEstimator(pivot_rank=1),
"Adjacent Chain": AdjacentChainEstimator(),
"Global All Pairs": AllPairsEstimator(),
}
examination_dfs = []
for name, estimator in estimators.items():
examination_df = estimator(df)
examination_df["estimator"] = name
examination_dfs.append(examination_df)
examination_df = pd.concat(examination_dfs)
examination_df.head()
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
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file ultr_bias_toolkit-0.0.5.tar.gz.
File metadata
- Download URL: ultr_bias_toolkit-0.0.5.tar.gz
- Upload date:
- Size: 3.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.5.1 CPython/3.11.4 Darwin/22.6.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0761ff078f95f466bedf1ca4a5f3aecf639fd60987a5d0dadbc39a7394ccc8d4
|
|
| MD5 |
d9f09a8eddb62d3a15940203accc718d
|
|
| BLAKE2b-256 |
c8b6e7e3f7ef6b321165c60b6ec4a65938540acdde575f98297d1ae86015c596
|
File details
Details for the file ultr_bias_toolkit-0.0.5-py3-none-any.whl.
File metadata
- Download URL: ultr_bias_toolkit-0.0.5-py3-none-any.whl
- Upload date:
- Size: 6.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.5.1 CPython/3.11.4 Darwin/22.6.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4e37b8c6d8bf12571be7ab29148ce85974ce0511044289ec846092299cdd9f19
|
|
| MD5 |
3829025eec475aa275dddcdb7014e76f
|
|
| BLAKE2b-256 |
de894569529c050f693cafb27750e0d060d0ddd6b88e735af816342c94296ff1
|