From 379193940bc6bfdc9b854983543f27affcb960b3 Mon Sep 17 00:00:00 2001 From: lvmin Date: Thu, 10 Aug 2023 08:56:11 -0700 Subject: [PATCH] i --- modules/core.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/modules/core.py b/modules/core.py index 41a8ddef..8d521fb9 100644 --- a/modules/core.py +++ b/modules/core.py @@ -64,8 +64,10 @@ def get_previewer(device, latent_format): x_sample = einops.rearrange(x_sample, 'b c h w -> b h w c') x_sample = x_sample.cpu().numpy()[..., ::-1].copy().clip(0, 255).astype(np.uint8) for i, s in enumerate(x_sample): - cv2.imshow(f'Preview {i}', s) - cv2.setWindowTitle(f'Preview {i}', f'Preview {i}, [{step}/{total_steps}]') + flag = f'OpenCV Diffusion Preview {i}' + cv2.imshow(flag, s) + cv2.setWindowTitle(flag, f'Preview {i}, [{step}/{total_steps}]') + cv2.setWindowProperty(flag, cv2.WND_PROP_TOPMOST, 1) cv2.waitKey(1) taesd.preview = preview_function