-
Notifications
You must be signed in to change notification settings - Fork 12
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
How to implement a new model in the adversarial-example model #4
Comments
Hi Sebastian, Note that the main attack we described in our paper was "white-box", in the sense that it required access to the gradients.
Best, |
Hi Uri, Given that your paper was a "white-box" we are working with a "black-box" attack based on your adversarial method, below you may find our comments:
I am not sure if our proposal is the same as your suggestion. In particular, what should be a good approach to get the adversarial perturbation in the substitute model and then to feed the code2vec? Thank you again. |
Hi @sebastianwgm , This project was implemented by @noamyft more than 3 years ago, and it is based on the code of code2vec that I wrote more than 5 years ago :-) So I don't remember the exact Tensorflow settings, especially those of sessions and graphs, which are practices that generally disappeared since then. So I don't want to give concrete implementation advice that I'm not sure about. Sorry if this doesn't help... Best, |
Dear authors
We are currently working on a black-box adversarial attack on the model code2vec based on this code. We trained a code2vec substitute model based on a different attention method (where we used as input the predicted output from code2vec).
We are trying to implement our pretrained substitute model in the adversarial-example code. However, we have the following questions:
Why are you calculating the gradient in the test graph? (method build_test_graph_with_loss)
We want to use our substitute model to get the gradient w.r.t inputs and then test your pretrained model (code2vec) with our updated adversarial code. We are not sure where to make changes on model.py to include our model.
Thank you
The text was updated successfully, but these errors were encountered: