From a0a467459d3d65345e4baf998112de7981df7364 Mon Sep 17 00:00:00 2001 From: "Alex J. Champandard" Date: Sat, 23 Apr 2016 08:49:19 +0200 Subject: [PATCH] Fixes for bugs introduced working on textures only. --- doodle.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/doodle.py b/doodle.py index abc57e9..2dd5648 100755 --- a/doodle.py +++ b/doodle.py @@ -271,7 +271,7 @@ def load_images(self, name, filename): map = scipy.ndimage.imread(mapname) if os.path.exists(mapname) else None if img is not None: print(' - Loading `{}` for {} data.'.format(filename, name)) - if map is not None: print(' - Loading `{}` as its semantic map.'.format(map)) + if map is not None: print(' - Loading `{}` as its semantic map.'.format(mapname)) if img is not None and map is not None and img.shape[:2] != map.shape[:2]: print("\n{}ERROR: The {} image and its semantic map have different resolutions. Either:\n"\ @@ -502,7 +502,7 @@ def run(self): """The main entry point for the application, runs through multiple phases at increasing resolutions. """ - self.frame = 0 + self.frame, Xn = 0, None for i in range(args.phases): self.error = 255.0 scale = 1.0 / 2.0 ** (args.phases - 1 - i) @@ -528,7 +528,7 @@ def run(self): print('{}'.format(ansi.ENDC)) # Setup the seed for the optimization as specified by the user. - shape, Xn = self.content_image.shape[2:], None + shape = self.content_image.shape[2:] if args.seed == 'content': Xn = self.content_image[0] + self.model.pixel_mean if args.seed == 'noise':