diff options
| author | Jules Laplace <julescarbon@gmail.com> | 2018-05-15 04:18:52 +0200 |
|---|---|---|
| committer | Jules Laplace <julescarbon@gmail.com> | 2018-05-15 04:18:52 +0200 |
| commit | 416ba77ed0a97f7604662e313000783a2b3354f5 (patch) | |
| tree | 105e04d771b863516a1b102e2ae7724950e9adca | |
| parent | 2fd5f6bee2a53f2df3e98c5b61f1ba9da85777d5 (diff) | |
testy
| -rw-r--r-- | data/recursive_dataset.py | 1 | ||||
| -rw-r--r-- | test-mogrify.py | 7 |
2 files changed, 5 insertions, 3 deletions
diff --git a/data/recursive_dataset.py b/data/recursive_dataset.py index ecbc7df..f56b871 100644 --- a/data/recursive_dataset.py +++ b/data/recursive_dataset.py @@ -22,7 +22,6 @@ class RecursiveDataset(BaseDataset): def __getitem__(self, index): A_path = os.path.join(self.opt.render_dir, "frame_{:05d}.png".format(index)) while not os.path.exists(A_path): - print(A_path) time.sleep(0.01) A_img = Image.open(A_path).convert('RGB') A = self.transform(A_img) diff --git a/test-mogrify.py b/test-mogrify.py index 8ad85a4..8e5c393 100644 --- a/test-mogrify.py +++ b/test-mogrify.py @@ -66,6 +66,8 @@ if __name__ == '__main__': if A_offset: print(">> starting offset: {}".format(A_offset)) A_dir = opt.start_img.replace(numz[0], "{:05d}") + else: + print("Sequence not found") def process_image(im): img = im[:, :, ::-1].copy() @@ -117,7 +119,8 @@ if __name__ == '__main__': tmp_path = render_dir + "frame_{:05d}_tmp.png".format(i+1) edges_path = render_dir + "frame_{:05d}.png".format(i+1) render_path = render_dir + "ren_{:05d}.png".format(i+1) - sequence_path = A_dir.format(A_offset+i+1) + if A_dir is not None: + sequence_path = A_dir.format(A_offset+i+1) # A_offset # save rendered image @@ -129,7 +132,7 @@ if __name__ == '__main__': if data_opt.recursive and last_im is not None: tmp_im = im.copy() - if data_opt.sequence: + if data_opt.sequence and A_dir is not None: A_img = Image.open(sequence_path).convert('RGB') A_im = np.asarray(A_img) frac_a = data_opt.recursive_frac |
