-
Notifications
You must be signed in to change notification settings - Fork 6.5k
Closed
Labels
bugSomething isn't workingSomething isn't working
Description
Describe the bug
Documentation says 1-4 inference steps, but using 4 steps throws error
achieving high-quality generation with 1-4 inference steps
if intermediate_timesteps is not None and num_inference_steps != 2:
raise ValueError("Intermediate timesteps for SCM is not supported when num_inference_steps != 2.")Reproduction
from diffusers import SanaSprintPipeline
import torch
pipeline = SanaSprintPipeline.from_pretrained(
"Efficient-Large-Model/Sana_Sprint_1.6B_1024px_diffusers",
torch_dtype=torch.bfloat16
)
pipeline.to("cuda:0")
prompt = "a tiny astronaut hatching from an egg on the moon"
image = pipeline(prompt=prompt, num_inference_steps=4).images[0]
image.save("test_out.png")Logs
(venv) C:\aiOWN\diffuser_webui>python Sana_Sprint.py
Loading checkpoint shards: 100%|ββββββββββββββββββββββββββββββββββββ| 2/2 [00:00<00:00, 3.07it/s]
Loading pipeline components...: 100%|βββββββββββββββββββββββββββββββ| 5/5 [00:05<00:00, 1.08s/it]
Traceback (most recent call last):
File "C:\aiOWN\diffuser_webui\Sana_Sprint.py", line 14, in <module>
image = pipeline(prompt=prompt, num_inference_steps=4).images[0]
File "C:\aiOWN\diffuser_webui\venv\lib\site-packages\torch\utils\_contextlib.py", line 116, in decorate_context
return func(*args, **kwargs)
File "C:\aiOWN\diffuser_webui\venv\lib\site-packages\diffusers\pipelines\sana\pipeline_sana_sprint.py", line 725, in __call__
self.check_inputs(
File "C:\aiOWN\diffuser_webui\venv\lib\site-packages\diffusers\pipelines\sana\pipeline_sana_sprint.py", line 414, in check_inputs
raise ValueError("Intermediate timesteps for SCM is not supported when num_inference_steps != 2.")
ValueError: Intermediate timesteps for SCM is not supported when num_inference_steps != 2.System Info
Build from source
Who can help?
No response
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working