Skip to content

Rineol/fairness-measures

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

55 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

fairness-measures

The main goal of this project was to visualize the behaviour of the group fairness measures in different imbalanced settings. Two important factors were taken into account: Minority Ratio and Group Ratio.

  • Minority Ratio = minority_class / (minority_class + majority_class)
  • Group Ratio = minority_group / (minority_group + majority group)

For example: positive & negative classes - we can calculate the minority ratio, females & males - we can calculate the group ratio.

Moreover, many interesting measures were proposed in the literature. In this implementation only several of them were included:

  • Equal Opportunity Difference
  • Statistical Parity
  • Accuracy Equality Difference
  • Predictive Equality Difference
  • Positive Predictive Parity Difference
  • Negative Predictive Parity Difference

Some additional measures were also calculated but not used in the visualization part of the project.

This project consists of two main files:

  • sets_creation.py: generates error matrixes with all possible scenarios and saves them to txt/bin (we need this to visualize measures aggregated by different imbalance values)
  • fairness_plots.ipynb: reads the files, creates pandas dataframe and visualizes the data.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published