Skip to content

Create a notebook that showcases the EqualizedOddsImprovement metric #777

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 10 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
820 changes: 820 additions & 0 deletions resources/equalized_odds_improvement_tutorial.ipynb

Large diffs are not rendered by default.

Binary file removed resources/visualize.png
Binary file not shown.
10 changes: 5 additions & 5 deletions sdmetrics/single_table/equalized_odds.py
Original file line number Diff line number Diff line change
Expand Up @@ -272,6 +272,11 @@ def _validate_parameters(
required_columns = [prediction_column_name, sensitive_column_name]
_validate_required_columns(dataframes_dict, required_columns)

# Use base class validation for real_training_data and synthetic_data
real_training_data, synthetic_data, metadata = cls._validate_inputs(
real_training_data, synthetic_data, metadata
)

# Validate data and metadata consistency for prediction column
_validate_data_and_metadata(
real_training_data,
Expand All @@ -286,11 +291,6 @@ def _validate_parameters(
column_value_pairs = [(sensitive_column_name, sensitive_column_value)]
_validate_column_values_exist(dataframes_dict, column_value_pairs)

# Use base class validation for real_training_data and synthetic_data
real_training_data, synthetic_data, metadata = cls._validate_inputs(
real_training_data, synthetic_data, metadata
)

# Validate the validation data separately (not part of standard _validate_inputs)
real_validation_data = real_validation_data.copy()

Expand Down
Loading