Spaces:
Runtime error
Runtime error
Kvikontent
commited on
Update app.py
Browse files
app.py
CHANGED
@@ -49,9 +49,10 @@ def query(payload):
|
|
49 |
def generate_image_from_prompt(prompt_text):
|
50 |
gr.Info("Image generation started")
|
51 |
image_bytes = query({"inputs": prompt_text})
|
52 |
-
img = BytesIO(image_bytes)
|
53 |
-
pil_img = Image.open(img)
|
54 |
-
|
|
|
55 |
|
56 |
title = "3D Icons SDXL Demo 🎨"
|
57 |
description = "This app uses Hugging Face AI model to generate an image based on the provided text prompt 🖼."
|
|
|
49 |
def generate_image_from_prompt(prompt_text):
|
50 |
gr.Info("Image generation started")
|
51 |
image_bytes = query({"inputs": prompt_text})
|
52 |
+
img = BytesIO(image_bytes)
|
53 |
+
pil_img = Image.open(img)
|
54 |
+
gr.Info("Image Generated Successfully!")
|
55 |
+
return pil_img
|
56 |
|
57 |
title = "3D Icons SDXL Demo 🎨"
|
58 |
description = "This app uses Hugging Face AI model to generate an image based on the provided text prompt 🖼."
|