Skip to content

Commit

Permalink
add small fix to adversarial
Browse files Browse the repository at this point in the history
  • Loading branch information
tatianak committed Jun 18, 2023
1 parent 06a084d commit e1bdd0f
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions actions/perturbation/adversarial.py
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,9 @@ def adversarial_operation(conversation, parse_text, i, simulation, **kwargs):
# launch attacks and print attack results
d = attack_eval.eval(dataset, visualize=False)

# needed to avoid conflict with captum (feature attributions)
victim.hook.remove()

return_s = ""

x_orig = d["x_orig"]
Expand Down

0 comments on commit e1bdd0f

Please sign in to comment.