donahowe / AutoStudio

AutoStudio: Crafting Consistent Subjects in Multi-turn Interactive Image Generation
https://arxiv.org/abs/2406.01388
261 stars 16 forks source link

Pipeline failed #12

Open Brothelmdzz opened 1 week ago

Brothelmdzz commented 1 week ago

╭─────────────────────────────── Traceback (most recent call last) ────────────────────────────────╮ │ /root/code/AutoStudio/run.py:199 in │ │ │ │ 196 │ │ │ ind_offset = repeat_ind * LARGE_CONSTANT2 + args.seed_offset │ │ 197 │ │ │ vis_location = [dialogue, turn] │ │ 198 │ │ │ │ │ ❱ 199 │ │ │ output = autostudio.generate( │ │ 200 │ │ │ │ │ │ │ │ │ │ │ GROUNDING_DINO_MODEL, │ │ 201 │ │ │ │ │ │ │ │ │ │ │ EFFICIENT_SAM_MODEL, │ │ 202 │ │ │ │ │ │ │ │ │ │ │ character_database, │ │ │ │ /root/code/AutoStudio/model/autostudio.py:367 in generate │ │ │ │ 364 │ │ │ │ │ │ continue │ │ 365 │ │ │ │ │ 366 │ │ │ # prepare latent_guidance │ │ ❱ 367 │ │ │ latent_guidance_mask, latent_guidance_image = prepare_mid_image(guide_masks, │ │ 368 │ │ │ latent_guidance_mask = latent_guidance_mask.resize((int(width/8), int(height │ │ 369 │ │ │ latent_guidance_mask = np.array(latent_guidance_mask) │ │ 370 │ │ │ latent_guidance_mask = torch.from_numpy(latent_guidance_mask).to(self.device │ │ │ │ /root/code/AutoStudio/model/utils.py:21 in prepare_mid_image │ │ │ │ 18 print(f"Using box scale: {box_scale}") │ │ 19 │ │ 20 def prepare_mid_image(mask_tensor_list_512, single_obj_img_list, bboxes, height, width, │ │ ❱ 21 │ mask_tensor_512 = mask_tensor_list_512[0] │ │ 22 │ #m,n = mask_tensor_512.size() │ │ 23 │ m,n = width, height │ │ 24 │ new_mask_tensor = np.zeros((n, m)).astype(np.uint8) │ ╰──────────────────────────────────────────────────────────────────────────────────────────────────╯ IndexError: list index out of range

The above error has been taking place every time and wouldn't get fixed by alternating inputs.

donahowe commented 1 week ago

Hello, I have fixed the bug. Please clone the repository again and configure the environment. Thank you for your attention.