Skip to content

Commit

Permalink
some change to the G_
Browse files Browse the repository at this point in the history
  • Loading branch information
ackongsun committed Dec 5, 2018
1 parent 0d183bb commit 7b6d0e2
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion WGAN.py
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,9 @@ def train(self):
D_real = self.D(x_)
D_real_loss = -torch.mean(D_real)

G_ = self.G(z_)
with torch.no_grad():
G_ = self.G(z_)

D_fake = self.D(G_)
D_fake_loss = torch.mean(D_fake)

Expand Down

0 comments on commit 7b6d0e2

Please sign in to comment.