LoRA based on Stability AI SDXL-Turbo, for more information on the main model: https://huggingface.co/stabilityai/sdxl-turbo xyz_grid-0015-2494203713-20231201144837.png

Diffusers

pip install diffusers transformers accelerate --upgrade
  • Text-to-image:
import torch
from diffusers import LCMScheduler, AutoPipelineForText2Image

model_id = "stabilityai/stable-diffusion-xl-base-1.0"
adapter_id = "shiroppo/sd_xl_turbo_lora"

pipe = AutoPipelineForText2Image.from_pretrained(model_id, torch_dtype=torch.float16, variant="fp16")
pipe.scheduler = LCMScheduler.from_config(pipe.scheduler.config)
pipe.to("cuda")

pipe.load_lora_weights(adapter_id)
pipe.fuse_lora()

prompt = "the_prompt"

image = pipe(prompt=prompt, num_inference_steps=4, guidance_scale=0).images[0]
Downloads last month

-

Downloads are not tracked for this model. How to track
Inference Providers NEW
This model is not currently available via any of the supported Inference Providers.
The model cannot be deployed to the HF Inference API: The model has no library tag.

Collection including shiroppo/sd_xl_turbo_lora