Views
No views yet
runchat.1from diffusers import StableDiffusionXLPipeline
2import torch
3
4# Load base model
5pipe = StableDiffusionXLPipeline.from_pretrained(
6 "stabilityai/stable-diffusion-xl-base-1.0",
7 torch_dtype=torch.float16
8)
9
10# Load LoRA weights
11pipe.load_lora_weights("runchat/lora-24cf691f-1d30-4f05-a39c-70053b2a66cd-runchat")
12pipe = pipe.to("cuda")
13
14# Generate image
15prompt = "a photo of runchat style"
16image = pipe(prompt, num_inference_steps=25, guidance_scale=7.5).images[0]
17image.save("output.png")runchat