File size: 302 Bytes
e4c7bb0
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
import gradio as gr

def generate_image(prompt):
    # Logic to generate images with Stable Diffusion here
    return "Generated image based on prompt: " + prompt

iface = gr.Interface(
    fn=generate_image,
    inputs="text",
    outputs="image",
    title="Stable Diffusion WebUI"
)

iface.launch()