From d63731fb644183f9ecaff15112a6b11206a619a9 Mon Sep 17 00:00:00 2001 From: Nataniel Ruiz Date: Tue, 24 Dec 2019 14:50:44 -0400 Subject: [PATCH] next --- stargan/attacks.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/stargan/attacks.py b/stargan/attacks.py index 49a29ee..cbf3f79 100644 --- a/stargan/attacks.py +++ b/stargan/attacks.py @@ -35,7 +35,7 @@ class LinfPGDAttack(object): y = torch.FloatTensor(y).to(self.device) self.model.zero_grad() - loss = -self.loss_fn(output, y) + loss = self.loss_fn(output, y) loss.backward() grad = X.grad