Spaces:
Sleeping
Sleeping
smileycutie0
commited on
Update app.py
Browse files
app.py
CHANGED
|
@@ -1,7 +1,17 @@
|
|
| 1 |
import gradio as gr
|
|
|
|
| 2 |
|
| 3 |
-
|
| 4 |
-
|
| 5 |
-
|
| 6 |
-
|
| 7 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
import gradio as gr
|
| 2 |
+
from huggingface_hub import InferenceClient
|
| 3 |
|
| 4 |
+
client = InferenceClient("cutiee82/artsytistic-diffusion")
|
| 5 |
+
|
| 6 |
+
def infer(prompt):
|
| 7 |
+
return client.text_to_image(prompt)
|
| 8 |
+
|
| 9 |
+
app = gr.Interface(
|
| 10 |
+
infer,
|
| 11 |
+
inputs=gr.Textbox(label="Prompt"),
|
| 12 |
+
outputs=gr.Image(label="Result"),
|
| 13 |
+
title="Artsytistic Diffusion"
|
| 14 |
+
)
|
| 15 |
+
|
| 16 |
+
if __name__ == "__main__":
|
| 17 |
+
app.queue().launch(debug=True)
|