Spaces:
Runtime error
Runtime error
Commit
·
1813092
1
Parent(s):
bb7f4b4
Update app.py
Browse files
app.py
CHANGED
@@ -1,8 +1,11 @@
|
|
1 |
import gradio as gr
|
2 |
-
|
3 |
|
4 |
-
|
5 |
-
|
|
|
|
|
|
|
6 |
|
7 |
iface = gr.Interface(fn=greet, inputs="text", outputs="image")
|
8 |
|
|
|
1 |
import gradio as gr
|
2 |
+
from diffusers import DiffusionPipeline
|
3 |
|
4 |
+
pipeline = DiffusionPipeline.from_pretrained("lucasfelezdev/TextToImage")
|
5 |
+
|
6 |
+
def greet(text):
|
7 |
+
image = pipeline("text").images[0]
|
8 |
+
return image
|
9 |
|
10 |
iface = gr.Interface(fn=greet, inputs="text", outputs="image")
|
11 |
|