lllyasviel / lllyasviel/FramePack

Possible bug when ending generation

Open
#619 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
17.3k
Forks
1.7k
PR merge metrics
No merged PRs in 30d

Description

Edit: Framepack can still run normally even after such error occured, thus i ignored it and continue experimenting.

Traceback (most recent call last):
File "E:\framepack_cu126_torch26\webui\demo_gradio.py", line 241, in worker
generated_latents = sample_hunyuan(
File "E:\framepack_cu126_torch26\system\python\lib\site-packages\torch\utils\_contextlib.py", line 116, in decorate_context
return func(*args, **kwargs)
File "E:\framepack_cu126_torch26\webui\diffusers_helper\pipelines\k_diffusion_hunyuan.py", line 116, in sample_hunyuan
results = sample_unipc(k_model, latents, sigmas, extra_args=sampler_kwargs, disable=False, callback=callback)
File "E:\framepack_cu126_torch26\webui\diffusers_helper\k_diffusion\uni_pc_fm.py", line 141, in sample_unipc
return FlowMatchUniPC(model, extra_args=extra_args, variant=variant).sample(noise, sigmas=sigmas, callback=callback, disable_pbar=disable)
File "E:\framepack_cu126_torch26\webui\diffusers_helper\k_diffusion\uni_pc_fm.py", line 134, in sample
callback({'x': x, 'i': i, 'denoised': model_prev_list[-1]})
File "E:\framepack_cu126_torch26\webui\demo_gradio.py", line 232, in callback

So i've been experimenting with prompt, and when the result of 1s, 2s, or beyond is unsatisfactory, usually i just stop the generation using End Generation button. After several start-end cycle, i've experienced 2x black screen. I can shutdown windows gracefuly from power button (i set that power button triggers a shutdown from power management). How many cycles needed to produce this behavior is unknown.

Temporary solution:
end the terminal every several generation ending, and full system restart

I'm using:
Ryzen 5 5600G
GeForce RTX 3060 12GB Vram
16 GB Vram
650W PSU

latest update framepack running on windows 11, i have xformers, flash attention, and sage attention installed.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the worker and callback in webui/demo_gradio.py, then trace the sampling path through webui/diffusers_helper/pipelines/k_diffusion_hunyuan.py and webui/diffusers_helper/k_diffusion/uni_pc_fm.py. Reproduce repeated uses of End Generation and inspect the traceback and system behavior. Done means the cause of the black screens is identified and repeated start-end cycles no longer produce the failure, with the relevant behavior verified.

Written by the indexing model from the issue text.

Assessment

Tech stack
python, pytorch
Domain
machine-learning
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.