Spaces:
Runtime error
Runtime error
File size: 403 Bytes
4d585b4 757b45e 86165e8 757b45e 86165e8 757b45e 86165e8 757b45e 86165e8 757b45e 4d585b4 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 |
import streamlit as st
from diffusers import DDPMScheduler, UNet2DModel
from PIL import Image
import torch
import numpy as np
import torch
from diffusers import StableDiffusionPipeline
pipe = StableDiffusionPipeline.from_pretrained("runwayml/stable-diffusion-v1-5", torch_dtype=torch.float16)
pipe = pipe.to("cuda")
prompt = st.text_input('Insert here your prompt')
image = pipe(prompt).images[0]
|