s9roll7 / animatediff-cli-prompt-travel

animatediff prompt travel
Apache License 2.0
1.17k stars 105 forks source link

[error] new git pull bug fix KeyError: 'controlnet_tile' #197

Closed dancemanUK closed 7 months ago

dancemanUK commented 7 months ago

return register_model(fn_wrapper) 02:14:17 INFO diffuser_ver='0.23.0' cli.py:100 INFO Using generation config: Gacha-231210.json cli.py:313 INFO is_sdxl=False util.py:562 02:14:18 INFO is_v2=True util.py:540 INFO Using base model: runwayml\stable-diffusion-v1-5 cli.py:340 INFO Will save outputs to ./output\2023-12-10T02-14-18-gacha-nadenadesitai_v10 cli.py:348 INFO Checking motion module... generate.py:610 INFO Loading tokenizer... generate.py:634 INFO Loading text encoder... generate.py:636 02:14:19 INFO Loading VAE... generate.py:638 INFO Loading UNet... generate.py:640 02:14:25 INFO Loaded 453.20928M-parameter motion module unet.py:578 INFO Using scheduler "k_dpmpp_sde" (DPMSolverSinglestepScheduler) generate.py:660 INFO Loading weights from G:\EasyPromptAnime\animatediff-cli-prompt-travel\data\models\sd\nadenadesitai_v10.safetensors generate.py:665 02:14:28 INFO Merging weights into UNet... generate.py:682 02:14:29 INFO Creating AnimationPipeline... generate.py:732 INFO No TI embeddings found ti.py:104 INFO Sending pipeline to device "cuda" pipeline.py:33 INFO Selected data types: unet_dtype=torch.float16, tenc_dtype=torch.float16, vae_dtype=torch.bfloat16 device.py:90 INFO Using channels_last memory format for UNet and VAE device.py:111 02:14:30 INFO Saving prompt config to output directory cli.py:413 INFO Initialization complete! cli.py:421 INFO Generating 1 animations cli.py:422 INFO Running generation 1 of 1 cli.py:432 INFO Generation seed: 2724082396373556268 cli.py:438 INFO len( region_condi_list )=1 generate.py:1512 INFO len( region_list )=1 generate.py:1513 INFO apply_lcm_lora=False animation.py:2407 INFO controlnet_for_region=False animation.py:2435 INFO multi_uncond_mode=False animation.py:2436 INFO unet_batch_size=1 animation.py:2437 INFO prompt_encoder.get_condi_size()=2 animation.py:2500 ╭─────────────────────────────── Traceback (most recent call last) ────────────────────────────────╮ │ G:\EasyPromptAnime\animatediff-cli-prompt-travel\src\animatediff\cli.py:441 in generate │ │ │ │ 438 │ │ │ logger.info(f"Generation seed: {seed}") │ │ 439 │ │ │ │ │ 440 │ │ │ │ │ ❱ 441 │ │ │ output = run_inference( │ │ 442 │ │ │ │ pipeline=g_pipeline, │ │ 443 │ │ │ │ n_prompt=n_prompt, │ │ 444 │ │ │ │ seed=seed, │ │ │ │ G:\EasyPromptAnime\animatediff-cli-prompt-travel\src\animatediff\generate.py:1515 in │ │ run_inference │ │ │ │ 1512 │ logger.info(f"{len( region_condi_list )=}") │ │ 1513 │ logger.info(f"{len( region_list )=}") │ │ 1514 │ │ │ ❱ 1515 │ pipeline_output = pipeline( │ │ 1516 │ │ negative_prompt=n_prompt, │ │ 1517 │ │ num_inference_steps=steps, │ │ 1518 │ │ guidance_scale=guidance_scale, │ │ │ │ G:\EasyPromptAnime\animatediff-cli-prompt-travel\venv\lib\site-packages\torch\utils_contextlib. │ │ py:115 in decorate_context │ │ │ │ 112 │ @functools.wraps(func) │ │ 113 │ def decorate_context(*args, *kwargs): │ │ 114 │ │ with ctx_factory(): │ │ ❱ 115 │ │ │ return func(args, **kwargs) │ │ 116 │ │ │ 117 │ return decorate_context │ │ 118 │ │ │ │ G:\EasyPromptAnime\animatediff-cli-prompt-travel\src\animatediff\pipelines\animation.py:2782 in │ │ call │ │ │ │ 2779 │ │ no_shrink_type = ["controlnet_tile"] │ │ 2780 │ │ │ │ 2781 │ │ for nt in no_shrink_type: │ │ ❱ 2782 │ │ │ controlnet_type_map[nt] = controlnet_type_map.pop(nt) │ │ 2783 │ │ │ │ 2784 │ │ def need_region_blend(cur_step, total_steps): │ │ 2785 │ │ │ if cur_step + 1 == total_steps: │ ╰──────────────────────────────────────────────────────────────────────────────────────────────────╯ KeyError: 'controlnet_tile'

@@ -2778,6 +2778,9 @@ def resize_tensor(ten, size, do_unsharp_mask=False): shrink_controlnet = True no_shrink_type = ["controlnet_tile"]

    for nt in no_shrink_type:
        controlnet_type_map[nt] = controlnet_type_map.pop(nt)

    def need_region_blend(cur_step, total_steps):
        if cur_step + 1 == total_steps:
            return True

@@ -2910,6 +2913,14 @@ def merge_result(fr, type_str):

dancemanUK commented 7 months ago

Gacha-231210.json this's test prompt.json

s9roll7 commented 7 months ago

thnx for report b6fbe11