aif360.sklearn.metrics
.generalized_entropy_error
- aif360.sklearn.metrics.generalized_entropy_error(y_true, y_pred, alpha=2, pos_label=1)[source]
Compute the generalized entropy.
Generalized entropy index is proposed as a unified individual and group fairness measure in [1].
Uses \(b_i = \hat{y}_i - y_i + 1\). See
generalized_entropy_index()
for details.- Parameters:
y_true (array-like) – Ground truth (correct) target values.
y_pred (array-like) – Estimated targets as returned by a classifier.
alpha (scalar, optional) – Parameter that regulates the weight given to distances between values at different parts of the distribution. A value of 0 is equivalent to the mean log deviation, 1 is the Theil index, and 2 is half the squared coefficient of variation.
pos_label (scalar, optional) – The label of the positive class.
See also
References