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

What's the difference between UMIFGSM and TMIFGSM #16

Open
XiaodanLi001 opened this issue Jul 16, 2019 · 2 comments
Open

What's the difference between UMIFGSM and TMIFGSM #16

XiaodanLi001 opened this issue Jul 16, 2019 · 2 comments

Comments

@XiaodanLi001
Copy link

No description provided.

@XiaodanLi001
Copy link
Author

I just find line 67 is the only difference between them. But in each iteration, the grad.data will be updated automatically. Why did you "zeros" grad.data by hand?

@ryderling
Copy link
Owner

Thanks. The difference between UMIFGSM and TMIFGSM is equal to the difference between un-target attack and target. More detail can be found in Equation 6-7 and Equation 11-12 of Yinpeng Dong et al. Boosting Adversarial Attacks with Momentum. In our implementation, there are totally different, and you can find these difference in "the loss calculation" and "update x in each iteration". For the zero_(), it is a dummy operation since the var_samples is built newly in each iteration.
Hope answered your questions.

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