SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2401.12532 · ICLR · 2024

DAFA: Distance-Aware Fair Adversarial Training

Sungroh Yoon, Saehyung Lee, Hyungyu Lee, Hyemi Jang, Junsung Park, Ho Bae

arXiv · PDF · Open in the Atlas

Code that ran

11 of 17 samples (functions and classes) lifted from this paper's linked repositories executed on a synthesized input in Syntology's jail (0 of them constructed an object rather than computing a result; 0 honoured the contract we drafted, 0 violated it and 0 have no contract verdict; 11 failures of our instrument; 6 no recorded run), measured 2026-11-23; bodies inline only under a permissive licence as GitHub detects it. Not a reproduction of the paper's results.

"Ran" means the function executed on a synthesized input and returned a value. It is not a reproduction of the paper's results. This record, dated, as JSON: /api/ran/2401.12532.json · badge: /api/ran/2401.12532.svg

Each repository's role is a label: a classifier's output recorded on the link, or, where no role is recorded, what the Papers with Code archive marked. The line under it names its basis. Neither says who wrote the code.

RepositoryRoleRan
rucy74/DAFA canonical (classifier label)
classifier basis: census
5 ran · 3 no recorded run
hannxu123/fair_robust unrelated (classifier label)
classifier basis: classifier_2025
4 ran · 3 no recorded run
copy not recorded community
not in the paper's declared repositories
2 ran · 0 no recorded run
FunctionStatusWhere it lives
PreActResNet18 Ran
ran; our contract draft was wrong, not the code
rucy74/DAFA/models/preact_resnet.py
pointer only (licence: NONE); the stored copy get_code serves, from jiancongxiao/moreau-envelope-sgd, is pointer only (licence: NONE) · get_code("1153837ba4a94242")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, rucy74/DAFA when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

ResNet18 Ran
ran; our contract draft was wrong, not the code
rucy74/DAFA/models/resnet.py
pointer only (licence: NONE) · get_code("0f23e7e681845fe0")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, rucy74/DAFA when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

cost_sensitive Ran
ran; our contract draft was wrong, not the code
hannxu123/fair_robust/utils_frl.py
pointer only (licence: NONE) · get_code("fa59447ea22b5b18")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, hannxu123/fair_robust when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

eval Ran
ran; our contract draft was wrong, not the code
rucy74/DAFA/evaluation.py
pointer only (licence: NONE) · get_code("18c82523ac3f528b")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, rucy74/DAFA when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

get_transform Ran
ran; our contract draft was wrong, not the code
rucy74/DAFA/datasets.py
pointer only (licence: NONE) · get_code("240892d4d66578d4")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, rucy74/DAFA when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

in_class Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
this paper's copy was not recorded; identical code first harvested from hannxu123/fair_robust
pointer only; the stored copy get_code serves, from hannxu123/fair_robust, is pointer only (licence: NONE) · get_code("0504a54e17169d2e")
How it ran

The body of this sample is withheld: this paper's copy of the code was not recorded (its link names no repository or source path), so no licence was read for it. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

match_weight Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
hannxu123/fair_robust/utils_frl.py
pointer only (licence: NONE) · get_code("9fc4a65d0199cf9c")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, hannxu123/fair_robust when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

normalize_lambda Ran
ran; our contract draft was wrong, not the code
hannxu123/fair_robust/utils_frl.py
pointer only (licence: NONE) · get_code("4bbdb8c0c8ea6043")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, hannxu123/fair_robust when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

pgd Ran
ran; our contract draft was wrong, not the code
rucy74/DAFA/evaluation.py
pointer only (licence: NONE) · get_code("b1ca971f9ac6b177")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, rucy74/DAFA when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

pgd_attack Ran
ran; our contract draft was wrong, not the code
this paper's copy was not recorded; identical code first harvested from hannxu123/fair_robust
pointer only; the stored copy get_code serves, from hannxu123/fair_robust, is pointer only (licence: NONE) · get_code("ee1e48fc088d1214")
How it ran

The body of this sample is withheld: this paper's copy of the code was not recorded (its link names no repository or source path), so no licence was read for it. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

trades_adv Ran
ran; our contract draft was wrong, not the code
hannxu123/fair_robust/utils_frl.py
pointer only (licence: NONE) · get_code("eca04e0dead8a043")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, hannxu123/fair_robust when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

calculate_class_weights Not yet run
unverified (harvested, no recorded run)
rucy74/DAFA/utils.py
pointer only (licence: NONE) · get_code("3dd1861dafcd1315")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, rucy74/DAFA when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. No invocation recorded.

evaluate Not yet run
unverified (harvested, no recorded run)
hannxu123/fair_robust/utils_frl.py
pointer only (licence: NONE) · get_code("4cf5ffbe5a5795e2")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, hannxu123/fair_robust when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. No invocation recorded.

frl_train Not yet run
unverified (harvested, no recorded run)
hannxu123/fair_robust/utils_frl.py
pointer only (licence: NONE) · get_code("ae909bf23603872c")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, hannxu123/fair_robust when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. No invocation recorded.

madry_loss Not yet run
unverified (harvested, no recorded run)
rucy74/DAFA/losses.py
pointer only (licence: NONE) · get_code("f25e91962b599eaf")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, rucy74/DAFA when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. No invocation recorded.

trades_loss Not yet run
unverified (harvested, no recorded run)
rucy74/DAFA/losses.py
pointer only (licence: NONE) · get_code("72b23386d15d731a")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, rucy74/DAFA when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. No invocation recorded.

train_model Not yet run
unverified (harvested, no recorded run)
hannxu123/fair_robust/utils_frl.py
pointer only (licence: NONE) · get_code("d986a04b9eef9dcc")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, hannxu123/fair_robust when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. No invocation recorded.

Also present in other papers' code

Of 17 samples lifted from this paper's linked repositories, 17 carry a function identity and 0 do not. Of the 17 distinct functions with an identity, 4 are also present in other papers whose code we hold (4 with at least one paper dated earlier, 0 the same month, 2 later) and 13 are only here among the 52,977 papers whose code Syntology holds (as of 2026-09-26).

Only here means: among the 52,977 papers whose code Syntology holds (51,887 with lifted samples, 1,090 through their assemblies only), as of 2026-09-26, no other paper's lifted samples or current assembly bricks contain an identical function body after normalisation.

FunctionAlso present inEarliest-datedOthers named
ResNet18 27 other papers
14 dated earlier, 13 later
1605.07146 (2016-05)
Wide Residual Networks
1901.09847 (2019-01)
Error Feedback Fixes SignSGD and other Gradient Compression Schemes
1910.09652 (2019-10)
Kernelized Wasserstein Natural Gradient
and 24 more not named here
PreActResNet18 22 other papers
15 dated earlier, 7 later
1710.09412 (2017-10)
mixup: BEYOND EMPIRICAL RISK MINIMIZATION
2003.04887 (2020-03)
ReZero is All You Need: Fast Convergence at Large Depth
2103.14222 (2021-03)
Adversarial Attacks are Reversible with Natural Supervision
and 19 more not named here
in_class
brick of this paper's assembly: helper
1 other paper
1 dated earlier
2010.06121 (2020-10)
To be Robust or to be Fair: Towards Fairness in Adversarial Training
pgd_attack
brick of this paper's assembly: helper
1 other paper
1 dated earlier
2010.06121 (2020-10)
To be Robust or to be Fair: Towards Fairness in Adversarial Training

Presence, not direction: an identical function body in two papers' repositories does not say who wrote it, which came from which, or that either paper's method rests on it. Matching is exact after normalisation, so a renamed or edited function is not matched. Dates are when papers appeared, not when code was written. Only .py files the harvester lifted are covered; notebooks are not read. A new-style arXiv id YYMM.NNNN dates a paper to the month 20YY-MM; otherwise Paper.year dates it to the year; otherwise it is undated. Dates are when the paper appeared, not when the code was written. Read 2026-11-23.

Repositories linked to this paper

Some links come from the archived Papers with Code dataset (CC BY-SA 4.0): attribution and licence.

Abstract

The disparity in accuracy between classes in standard training is amplified during adversarial training, a phenomenon termed the robust fairness problem. Existing methodologies aimed to enhance robust fairness by sacrificing the model's performance on easier classes in order to improve its performance on harder ones. However, we observe that under adversarial attacks, the majority of the model's predictions for samples from the worst class are biased towards classes similar to the worst class, rather than towards the easy classes. Through theoretical and empirical analysis, we demonstrate that robust fairness deteriorates as the distance between classes decreases. Motivated by these insights, we introduce the Distance-Aware Fair Adversarial training (DAFA) methodology, which addresses robust fairness by taking into account the similarities between classes. Specifically, our method assigns distinct loss weights and adversarial margins to each class and adjusts them to encourage a trade-off in robustness among similar classes. Experimental results across various datasets demonstrate that our method not only maintains average robust accuracy but also significantly improves the worst robust accuracy, indicating a marked improvement in robust fairness compared to existing methods.

For agents

The same record, over MCP at https://syntology.ai/mcp:

get_harvested_code_for_paper("2401.12532")
get_code_for_paper("2401.12532")
have("2401.12532")

The run record, dated, one paper per request, free:

curl https://syntology.ai/api/ran/2401.12532.json

A badge for a README (the split and the date, never a ratio):

[![Syntology run record](https://syntology.ai/api/ran/2401.12532.svg)](https://syntology.ai/paper/2401.12532)

Connect an agent — have() is free.