Open thechrismorin opened 2 months ago
I haven't been able to reproduce this. For me with those settings the API uses 9.6 GB and web UI is the same.
Could you try this again with latest versions of A1111 and AD? If you still see the same problem, it would be helpful to see a screenshot of the UI settings used.
Also, did you intend to enable FILM interpolation with Interp X in the JSON? That's going to return about 960 frames.
Is there an existing issue for this?
Have you read FAQ on README?
What happened?
When I send the below payload to WebUI via API, the app will crash with a Cuda out of memory error. I have a 4070, 12GB dedicated and 8GB shared. When I configure the web GUI with the same settings, it processes just fine. If I lower the video_length to something like 12 or 24 frames, i don't his the memory limit. But critically, the web GUI can seem to accomidate the higher frame lengths without issue.
Steps to reproduce the problem
API Request to Automatic1111: payload = { "alwayson_scripts": { "AnimateDiff": { "args": [ { "batch_size" : 16, "closed_loop" : "R-P", "enable" : True, "format" : ["PNG"], "fps" : 12, "interp" : "FILM", "interp_x" : 10, "model" : "animatediffMotion_v14.ckpt", "overlap" : 1, "stride" : 1, "video_length" : 96, } ] } }, "batch_size" : 1, "cfg_scale" : 7, "denoising_strength" : 0.7, "height" : 540, "negative_prompt" : negative_prompt, "prompt" : prompt, "sampler_name" : "DPM++ 2M Karras", "seed" : -1, "steps" : 20, "width" : 960 }
What should have happened?
It should return a payload with 96 png frames included under "images". I can then convert this into a gif on my own.
Commit where the problem happens
webui: 1.8.0-RC extension: Updated 2024-04-23
What browsers do you use to access the UI ?
No response
Command Line Arguments
Console logs
Additional information
GUI Attempt (which works) console logs: Startup time: 58.6s (prepare environment: 35.1s, import torch: 5.4s, import gradio: 1.0s, setup paths: 3.1s, initialize shared: 0.1s, other imports: 0.6s, load scripts: 3.4s, create ui: 4.7s, gradio launch: 4.3s, add APIs: 0.5s). 2024-05-05 12:04:39,681 - AnimateDiff - INFO - AnimateDiff process start. 2024-05-05 12:04:39,683 - AnimateDiff - INFO - Loading motion module animatediffMotion_v14.ckpt from C:\stable-diffusion-webui\extensions\sd-webui-animatediff\model\animatediffMotion_v14.ckpt 2024-05-05 12:04:40,824 - AnimateDiff - INFO - Guessed animatediffMotion_v14.ckpt architecture: MotionModuleType.AnimateDiffV1 2024-05-05 12:04:43,692 - AnimateDiff - INFO - Hacking SD1.5 GroupNorm32 forward function. 2024-05-05 12:04:43,692 - AnimateDiff - INFO - Injecting motion module animatediffMotion_v14.ckpt into SD1.5 UNet input blocks. 2024-05-05 12:04:43,693 - AnimateDiff - INFO - Injecting motion module animatediffMotion_v14.ckpt into SD1.5 UNet output blocks. 2024-05-05 12:04:43,694 - AnimateDiff - INFO - Setting DDIM alpha. 2024-05-05 12:04:43,725 - AnimateDiff - INFO - Injection finished. 2024-05-05 12:04:43,725 - AnimateDiff - INFO - AnimateDiff + ControlNet will generate 96 frames. Warning: field infotext in API payload not found in <modules.processing.StableDiffusionProcessingTxt2Img object at 0x0000022A481B67D0>. 0%| | 0/20 [00:00<?, ?it/s]2024-05-05 12:04:43,840 - AnimateDiff - INFO - inner model forward hooked 100%|██████████████████████████████████████████████████████████████████████████████████| 20/20 [06:23<00:00, 19.20s/it] 2024-05-05 12:11:40,264 - AnimateDiff - INFO - Restoring DDIM alpha.███████████████████| 20/20 [06:04<00:00, 19.18s/it] 2024-05-05 12:11:40,264 - AnimateDiff - INFO - Removing motion module from SD1.5 UNet input blocks. 2024-05-05 12:11:40,266 - AnimateDiff - INFO - Removing motion module from SD1.5 UNet output blocks. 2024-05-05 12:11:40,266 - AnimateDiff - INFO - Restoring SD1.5 GroupNorm32 forward function. 2024-05-05 12:11:40,266 - AnimateDiff - INFO - Removal finished. 2024-05-05 12:11:40,290 - AnimateDiff - INFO - Saving output formats: PNG 2024-05-05 12:11:40,341 - AnimateDiff - ERROR - Deforum not found. Please install: https://github.com/deforum-art/deforum-for-automatic1111-webui.git 2024-05-05 12:11:56,526 - AnimateDiff - INFO - AnimateDiff process end. Total progress: 100%|██████████████████████████████████████████████████████████████████| 20/20 [06:52<00:00, 20.65s/it] Total progress: 100%|██████████████████████████████████████████████████████████████████| 20/20 [06:52<00:00, 19.18s/it]