stable_diffusion / apple_silicon.py
Nedyalko Demirev
nvidia version created
20f0a97
raw
history blame
285 Bytes
from diffusers import StableDiffusionPipeline
DEVICE = 'mps'
pipe = StableDiffusionPipeline.from_pretrained(
"CompVis/stable-diffusion-v1-4",
use_auth_token=True
).to(DEVICE)
prompt = "Synthwave moonlight"
image = pipe(prompt).images[0]
image.save("pictures/Synthwave.png")