From 556ed274c492161f6cf487bfceb1a0eef3e2e100 Mon Sep 17 00:00:00 2001 From: Avik Pal Date: Sat, 15 Dec 2018 21:22:58 +0530 Subject: [PATCH] Fix logging of incorrect image names --- torchgan/logging/visualize.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/torchgan/logging/visualize.py b/torchgan/logging/visualize.py index e5fc654..4da803f 100644 --- a/torchgan/logging/visualize.py +++ b/torchgan/logging/visualize.py @@ -212,4 +212,6 @@ def __call__(self, trainer, **kwargs): image = generator(*self.test_noise[pos]) image = torchvision.utils.make_grid(image) super(ImageVisualize, self).__call__(trainer, image, model, **kwargs) + self.step -= 1 pos = pos + 1 + self.step += 1 if pos > 0 else 0