An open implementation of FairPrune, a method for pruning parameters as to increase the fairness between two groups
Run the install.bat script. For Linux, examine the script and run the equivalent commands. This creates a venv folder, which you should use to run the files.
You'll get 2 additional commands
- train-prune --help (Train a model, possibly using --fairness LAMBDA_VALUE)
- mlflow ui (Run in the data folder)
Examine the main section in fairprune.py, and modify hyperparameters, model loading etc. to your needs.
The data directory already contains some runs. Upon loading these, you'll get an error stating it cannot find the path C/USERNAME. You therefore need to change the artifact_uri
Run the eval_model.py
Examine and run the shap_explainer.py (takes a while)