{"about":{"site":"https://codewithpapers.app","non_affiliation":"Code with Papers and Syntology are not affiliated with, endorsed by, or sponsored by Papers with Code, Meta, or the pwc-archive mirror.","licence":"CC BY-SA 4.0","licence_url":"https://creativecommons.org/licenses/by-sa/4.0/legalcode","attribution":"https://codewithpapers.app/attribution","modified":"archive material modified by Syntology; see the attribution page"},"url":"/paper/achieving-equalized-odds-by-resampling","title":"Achieving Equalized Odds by Resampling Sensitive Attributes","arxiv_id":"2006.04292","date":"2020-06-08","proceeding":"NeurIPS 2020 12","authors":["Yaniv Romano","Stephen Bates","Emmanuel J. Candès"],"abstract":"We present a flexible framework for learning predictive models that approximately satisfy the equalized odds notion of fairness. This is achieved by introducing a general discrepancy functional that rigorously quantifies violations of this criterion. This differentiable functional is used as a penalty driving the model parameters towards equalized odds. To rigorously evaluate fitted models, we develop a formal hypothesis test to detect whether a prediction rule violates this property, the first such test in the literature. Both the model fitting and hypothesis testing leverage a resampled version of the sensitive attribute obeying equalized odds, by construction. We demonstrate the applicability and validity of the proposed framework both in regression and multi-class classification problems, reporting improved performance over state-of-the-art methods. Lastly, we show how to incorporate techniques for equitable uncertainty quantification---unbiased for each group under study---to communicate the results of the data analysis in exact terms.","url_abs":"https://arxiv.org/abs/2006.04292v1","url_pdf":"https://arxiv.org/pdf/2006.04292v1.pdf","source":{"archive":"pwc-archive (Hugging Face), CC BY-SA 4.0","snapshot":"2025-07-28","licence_url":"https://creativecommons.org/licenses/by-sa/4.0/legalcode","row_kind":"abstracts"},"code_links":[{"paper_slug":"achieving-equalized-odds-by-resampling","repo_url":"https://github.com/yromano/fair_dummies","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":0,"framework":"pytorch","reach":{"status":"ok","spdx":"MIT"}}],"tasks":[{"task_slug":"attribute","task_name":"Attribute"},{"task_slug":"fairness","task_name":"Fairness"},{"task_slug":"multi-class-classification","task_name":"Multi-class Classification"},{"task_slug":"hypothesis-testing","task_name":"Two-sample testing"},{"task_slug":"uncertainty-quantification","task_name":"Uncertainty Quantification"}],"methods":[],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"syntology_url":"https://syntology.ai/paper/2006.04292","atlas_url":"https://app.syntology.ai/?focus=2006.04292","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2006.04292"}},"developers":"https://syntology.ai/developers","read_at":"2026-09-25T09:33:49+00:00","read_at_is":"when the build read Syntology's graph, not when any sample ran","claim":"Per-sample execution status on synthesized fixtures; not a correctness claim about the paper. Samples come from repositories linked to the paper, official or community; repo_kind says which.","repos":[{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/yromano/fair_dummies","reach":{"status":"ok","spdx":"MIT"}}],"summary":{"unverified":15},"by_repo_kind":{"official":{"samples":15,"ran":0,"repositories":1}},"repo_kind_vocabulary":{"official":"The archive marks this repository official for the paper","named_in_paper":"The archive records that the paper mentions this repository; it is not marked official","listed":"In the archive's code links for this paper, not marked official and not recorded as mentioned in the paper","found_in_text":"Syntology found this repository in the paper's own text; whether it is the authors' implementation is not asserted","community":"Not in the archive's code links for this paper; a community repository Syntology harvested"},"n_pointer_only_for_licence":0,"samples":[{"code_sha256_prefix":"155d81bdb4a2fc74","entry":"calc_accuracy","repo":"yromano/fair_dummies","repo_kind":"official","path":"fair_dummies/utility_functions.py","file_url":"https://github.com/yromano/fair_dummies/blob/HEAD/fair_dummies/utility_functions.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"155d81bdb4a2fc74"}},{"code_sha256_prefix":"38ec48431e45abd1","entry":"compute_acc","repo":"yromano/fair_dummies","repo_kind":"official","path":"fair_dummies/utility_functions.py","file_url":"https://github.com/yromano/fair_dummies/blob/HEAD/fair_dummies/utility_functions.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"38ec48431e45abd1"}},{"code_sha256_prefix":"593e5ed0481b0f0a","entry":"covariance_diff_biased","repo":"yromano/fair_dummies","repo_kind":"official","path":"fair_dummies/fair_dummies_learning.py","file_url":"https://github.com/yromano/fair_dummies/blob/HEAD/fair_dummies/fair_dummies_learning.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"593e5ed0481b0f0a"}},{"code_sha256_prefix":"4df32aef40d16f61","entry":"density_estimation","repo":"yromano/fair_dummies","repo_kind":"official","path":"fair_dummies/utility_functions.py","file_url":"https://github.com/yromano/fair_dummies/blob/HEAD/fair_dummies/utility_functions.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"4df32aef40d16f61"}},{"code_sha256_prefix":"61c33a916c6ce639","entry":"gen_synthetic_data","repo":"yromano/fair_dummies","repo_kind":"official","path":"get_dataset.py","file_url":"https://github.com/yromano/fair_dummies/blob/HEAD/get_dataset.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"61c33a916c6ce639"}},{"code_sha256_prefix":"4fd60a8ea590875e","entry":"get_coverage","repo":"yromano/fair_dummies","repo_kind":"official","path":"fair_dummies/cf_classification.py","file_url":"https://github.com/yromano/fair_dummies/blob/HEAD/fair_dummies/cf_classification.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"4fd60a8ea590875e"}},{"code_sha256_prefix":"2ffe424106b5b1c8","entry":"get_length","repo":"yromano/fair_dummies","repo_kind":"official","path":"fair_dummies/cf_classification.py","file_url":"https://github.com/yromano/fair_dummies/blob/HEAD/fair_dummies/cf_classification.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"2ffe424106b5b1c8"}},{"code_sha256_prefix":"50b70e5728cd9316","entry":"get_stat","repo":"yromano/fair_dummies","repo_kind":"official","path":"fair_dummies/cf_classification.py","file_url":"https://github.com/yromano/fair_dummies/blob/HEAD/fair_dummies/cf_classification.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"50b70e5728cd9316"}},{"code_sha256_prefix":"29bbbca9a634482a","entry":"pretrain_adversary","repo":"yromano/fair_dummies","repo_kind":"official","path":"fair_dummies/fair_dummies_learning.py","file_url":"https://github.com/yromano/fair_dummies/blob/HEAD/fair_dummies/fair_dummies_learning.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"29bbbca9a634482a"}},{"code_sha256_prefix":"f80ebdfe287d35b2","entry":"pretrain_adversary","repo":"yromano/fair_dummies","repo_kind":"official","path":"others/adv_debiasing.py","file_url":"https://github.com/yromano/fair_dummies/blob/HEAD/others/adv_debiasing.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"f80ebdfe287d35b2"}},{"code_sha256_prefix":"dd0d940686cc5d71","entry":"pretrain_adversary_fast_loader","repo":"yromano/fair_dummies","repo_kind":"official","path":"fair_dummies/fair_dummies_learning.py","file_url":"https://github.com/yromano/fair_dummies/blob/HEAD/fair_dummies/fair_dummies_learning.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"dd0d940686cc5d71"}},{"code_sha256_prefix":"e31d738cefaa827e","entry":"read_crimes_data","repo":"yromano/fair_dummies","repo_kind":"official","path":"get_dataset.py","file_url":"https://github.com/yromano/fair_dummies/blob/HEAD/get_dataset.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"e31d738cefaa827e"}},{"code_sha256_prefix":"3db0f0aa6ae485cb","entry":"read_meps_data","repo":"yromano/fair_dummies","repo_kind":"official","path":"get_dataset.py","file_url":"https://github.com/yromano/fair_dummies/blob/HEAD/get_dataset.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"3db0f0aa6ae485cb"}},{"code_sha256_prefix":"f6d9e0317d4ec628","entry":"train","repo":"yromano/fair_dummies","repo_kind":"official","path":"others/adv_debiasing.py","file_url":"https://github.com/yromano/fair_dummies/blob/HEAD/others/adv_debiasing.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"f6d9e0317d4ec628"}},{"code_sha256_prefix":"46780301e5c26af6","entry":"train_regressor","repo":"yromano/fair_dummies","repo_kind":"official","path":"others/adv_debiasing.py","file_url":"https://github.com/yromano/fair_dummies/blob/HEAD/others/adv_debiasing.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"46780301e5c26af6"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}