rupeshs / fastsdcpu

Fast stable diffusion on CPU
MIT License
1.5k stars 121 forks source link

Force LCM scheduler for LCM safetensors models #235

Closed wbruna closed 3 months ago

wbruna commented 3 months ago

The safetensors file does not specify a scheduler, so the diffusers library picks one according to the base model (DDIM for SD 1.5).

As in lcm-lora, we check for 'lcm' in the file name, since most safetensors files follow that convention.

The DDIM scheduler adds a grainy texture on images generated with LCM checkpoints, but depending on the checkpoint it may not be immediately noticeable. Testing with dreamshaper_8LCM.safetensors:

image

And with the LCM scheduler:

image

rupeshs commented 3 months ago

@wbruna Thanks you