Skip to content
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

args.norm_size in compute_bias.py #8

Open
Mogul5306 opened this issue Mar 16, 2023 · 1 comment
Open

args.norm_size in compute_bias.py #8

Mogul5306 opened this issue Mar 16, 2023 · 1 comment

Comments

@Mogul5306
Copy link

What is this parameter (args.norm_size ) used for? In line #73, after adding up the three contribution values, why is this norm_size added.

@avaxiao
Copy link
Collaborator

avaxiao commented Jul 22, 2023

Hello, the reason for normalizing the gradients is to determine their relative magnitudes. If we normalize them with softmax for each individual example, the ratios among the three features become similar. Therefore, it is necessary to define a norm_size for this purpose. However, it's worth exploring other normalization methods, as some of them might not require setting a norm_size parameter.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants