-
Notifications
You must be signed in to change notification settings - Fork 5
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
some question about the white box attack #10
Comments
Hi @yuese1234, could you please provide your versions of torch and transformers? Alternatively, you can use transformers 4.36.2 and torch 2.1.0. |
I use the transformers 4.37.2 and torch 2.1.2。I found that in the VIT of CLIP, the gradient disappeared, but I rewrote a piece of code and loaded the VIT separately, and the gradient existed. |
Ok, we will update the version requirements in the README later. Please let us know if you have any other questions. |
I just try transformers 4.36.2 and torch 2.1.0. the gradient is still None. As the follows: |
Sorry to bother you again.
When I run your white-box attack code for LLaVA, the gradient is None. The specific problem is:
adv_noise.data = (adv_noise.data - alpha * adv_noise.grad.detach().sign()).clamp(0, 1)
AttributeError: 'NoneType' object has no attribute 'detach'. Can you give me some help?
The text was updated successfully, but these errors were encountered: