bugfix append

This commit is contained in:
Johannes Stelzer 2023-02-21 19:53:26 +01:00
parent 6f78b990e1
commit 1bfca6189d
1 changed files with 6 additions and 1 deletions

View File

@ -162,7 +162,6 @@ class BlendingFrontend():
list_latents = [torch.from_numpy(l).to(self.lb.device) for l in list_latents_cpu] list_latents = [torch.from_numpy(l).to(self.lb.device) for l in list_latents_cpu]
return list_latents return list_latents
def compute_img1(self, *args): def compute_img1(self, *args):
list_ui_elem = args list_ui_elem = args
self.setup_lb(list_ui_elem) self.setup_lb(list_ui_elem)
@ -281,7 +280,13 @@ class BlendingFrontend():
shutil.copyfile(fp_movie_last, fp_movie_next) shutil.copyfile(fp_movie_last, fp_movie_next)
self.lb.tree_latents[0] = self.load_latents(os.path.join(self.dp_imgs, f"img1_{self.user_id}.npy"))
self.lb.tree_latents[-1] = self.load_latents(os.path.join(self.dp_imgs, f"img2_{self.user_id}.npy"))
self.lb.swap_forward() self.lb.swap_forward()
shutil.copyfile(os.path.join(self.dp_imgs, f"img2_{self.user_id}.npy"), os.path.join(self.dp_imgs, f"img1_{self.user_id}.npy"))
fp_multi = self.multi_concat() fp_multi = self.multi_concat()
list_out = [fp_multi] list_out = [fp_multi]