metercai / SimpleSDXL

Enhanced version of Fooocus for SDXL, more suitable for Chinese and Cloud
GNU General Public License v3.0
678 stars 32 forks source link

[Bug]: In Comfy Mode, Flux Generates One or Two Sets of Images then Fails #72

Closed DavidDragonsage closed 2 months ago

DavidDragonsage commented 2 months ago

Checklist

What happened?

In Comfy mode, running either Flux1 Dev or Flux1 Schnell, I can do one or two sets of image generation, then I get this error:

File "C:\SimpleAI\SimpleSDXL2_win2_0820\SimpleSDXL\modules\async_worker.py", line 822, in process_prompt expansion = pipeline.final_expansion(t['task_prompt'], t['task_seed']) TypeError: 'NoneType' object is not callable

The only way to do further generations is to exit SimpleSDXL and run it again.

Steps to reproduce the problem

Using a Flux model, do one or two sets of generations, then try another to do another set. In my case, SimpleSDXL will no longer be able to do any image generations.

What should have happened?

SimpleSDXL should be able to do unlimited sets of image generations.

What browsers do you use to access Fooocus?

Mozilla Firefox

Where are you running Fooocus?

Locally

What operating system are you using?

Windows 10

Console logs

Fooocus version: 2.5.5
Comfy version: 233c67a
SimpleSDXL version: v20240820.fe1ef95
Checking ...
[SimpleAI] GPU: NVIDIA GeForce RTX 3060, RAM: 49069MB, SWAP: 73728MB, VRAM: 12288MB, DiskFree: 80975MB, CUDA: 12.6
[SimpleAI] local_did/本地身份ID: mgoXjR6TTBDJ92GjSLtZ5R2nuKE
Load config data from C:\SimpleAI\SimpleSDXL2_win2_0820\SimpleSDXL\config.txt.
Loaded preset: C:\SimpleAI\SimpleSDXL2_win2_0820\SimpleSDXL\presets\default.json
The path_models_root: C:\SimpleAI\SimpleModels
The path_output: E:\stable-diffusion-webui\outputs
Total VRAM 12288 MB, total RAM 49069 MB
...

[Comfyd] GPU memory: max_reserved=8.969GB, max_allocated=8.828GB, reserved=2.781GB, free=8.149GB, free_torch=2.617GB, free_total=10.767GB, gpu_total=12.000GB, torch_total=2.781GB
...

Traceback (most recent call last):
  File "C:\SimpleAI\SimpleSDXL2_win2_0820\SimpleSDXL\modules\async_worker.py", line 1626, in worker
    handler(task)
  File "C:\SimpleAI\SimpleSDXL2_win2_0820\python_embeded\lib\site-packages\torch\utils\_contextlib.py", line 115, in decorate_context
    return func(*args, **kwargs)
  File "C:\SimpleAI\SimpleSDXL2_win2_0820\python_embeded\lib\site-packages\torch\utils\_contextlib.py", line 115, in decorate_context
    return func(*args, **kwargs)
  File "C:\SimpleAI\SimpleSDXL2_win2_0820\SimpleSDXL\modules\async_worker.py", line 1263, in handler
    tasks, use_expansion, loras, current_progress = process_prompt(async_task, async_task.prompt, async_task.negative_prompt,
  File "C:\SimpleAI\SimpleSDXL2_win2_0820\SimpleSDXL\modules\async_worker.py", line 822, in process_prompt
    expansion = pipeline.final_expansion(t['task_prompt'], t['task_seed'])
TypeError: 'NoneType' object is not callable
Total time: 0.09 seconds
[Gallery] Refresh_output_catalog: loaded 401 images_catalogs.
[Gallery] Parse_html_log: loaded 38 image_infos of 24-09-11.
[Gallery] Refresh_images_catalog: loaded 38 image_items of 24-09-11.
[Gallery] Parse_html_log: loaded 38 image_infos of 24-09-11.

Additional information

Processor: Intel(R) Core(TM) i5-9400F CPU @ 2.90GHz 2.90 GHz Installed RAM: 48.0GB Video: NVIDIA GeForce 3060 12 GB Minimum SWAP: 73728MB

metercai commented 2 months ago

Fixed in the 'dev' version, waiting for the official version to be released

DavidDragonsage commented 2 months ago

Great news! I think I'll load up the dev version for now. 🙂

DavidDragonsage commented 2 months ago

The dev version does fix this bug so I am staying with it.

I cannot seem to get the interface to switch to English using the checkbox under the Enhanced tab, but I know my way around Fooocus pretty well without needing to know the language cues!

metercai commented 2 months ago

You can force the English interface to start in the startup script: --language en

DavidDragonsage commented 2 months ago

Thank you, that is good to know!

DavidDragonsage commented 2 months ago

I can confirm that production version v20240916.2952150 does in fact fix this bug. Thank you!