Fairness-aware machine learning: algorithms, comparisons, benchmarking
Project description
This repository is meant to facilitate the benchmarking of fairness aware machine learning algorithms.
The associated paper is:
A comparative study of fairness-enhancing interventions in machine learning by Sorelle A. Friedler, Carlos Scheidegger, Suresh Venkatasubramanian, Sonam Choudhary, Evan P. Hamilton, and Derek Roth. https://arxiv.org/abs/1802.04422
To install this software run:
$ pip3 install fairness
The below instructions are still in the process of being updated to work with the new pip install-able version.
To run the benchmarks:
$ from fairness.benchmark import run
$ run()
This will write out metrics for each dataset to the results/ directory.
To generate graphs and other analysis run:
$ python3 analysis.py
If you do not yet have all the packages installed, you may need to run:
$ pip install -r requirements.txt
Optional: The benchmarks rely on preprocessed versions of the datasets that have been included in the repository. If you would like to regenerate this preprocessing, run the below command before running the benchmark script:
$ python3 preprocess.py
To add new datasets or algorithms, see the instructions in the readme files in those directories.
OS-specific things
On Ubuntu
(We tested on Ubuntu 16.04, your mileage may vary)
You'll need python3-dev
:
$ sudo apt-get install python3-dev
Additional analysis-specific requirements
To regenerate figures (this is messy right now. we're working on it)
Python requirements (use pip):
ggplot
System requirements:
pandoc
(brew install pandoc
on a Mac orapt-get install pandoc
on Linux)- R (Mac download link: https://cran.rstudio.com/bin/macosx/R-3.4.3.pkg)
R package requirements (use install.packages
):
rmarkdown
stringr
ggplot2
dplyr
magrittr
corrplot
robust
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 fairness-0.1.8.tar.gz
.
File metadata
- Download URL: fairness-0.1.8.tar.gz
- Upload date:
- Size: 12.9 MB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.12.1 pkginfo/1.5.0.1 requests/2.21.0 setuptools/39.0.1 requests-toolbelt/0.8.0 tqdm/4.30.0 CPython/3.6.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 7cd98a95dfbf3342ad990822afda97514bed2c6be789889db2ee2ff39f8f534d |
|
MD5 | b939e48e2555e1d36533ebf39b750880 |
|
BLAKE2b-256 | 91017b2d3e84bfd69b73757c3dc16e4a721e36ec662e03e6c9279675d099a86f |
File details
Details for the file fairness-0.1.8-py3-none-any.whl
.
File metadata
- Download URL: fairness-0.1.8-py3-none-any.whl
- Upload date:
- Size: 14.2 MB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.12.1 pkginfo/1.5.0.1 requests/2.21.0 setuptools/39.0.1 requests-toolbelt/0.8.0 tqdm/4.30.0 CPython/3.6.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 7f21cf0943f2a6fef7f7597eb99461bd4b2f7a26fe9810964675496cde6992e1 |
|
MD5 | a6e209c84037b013a9369dc909cdac67 |
|
BLAKE2b-256 | f6d0038541647d46112174ae8f9d7ef256d73cfccc0668923748826a0d4cb63c |