Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
|
@@ -77,14 +77,14 @@ description = """
|
|
| 77 |
Upload an image, and this app will generate a short story based on the image.
|
| 78 |
"""
|
| 79 |
|
| 80 |
-
|
| 81 |
async def sepia(input_img):
|
| 82 |
-
|
| 83 |
-
async for e in chain.astream(
|
| 84 |
chunks.append(e)
|
| 85 |
yield "".join(chunks)
|
| 86 |
|
| 87 |
-
demo = gr.Interface(sepia, gr.Image(type='pil'),
|
| 88 |
description=description,live=True
|
| 89 |
)
|
| 90 |
if __name__ == "__main__":
|
|
|
|
| 77 |
Upload an image, and this app will generate a short story based on the image.
|
| 78 |
"""
|
| 79 |
|
| 80 |
+
|
| 81 |
async def sepia(input_img):
|
| 82 |
+
chunks=[]
|
| 83 |
+
async for e in chain.astream(input_img):
|
| 84 |
chunks.append(e)
|
| 85 |
yield "".join(chunks)
|
| 86 |
|
| 87 |
+
demo = gr.Interface(sepia, gr.Image(type='pil'),"textarea",title=title,
|
| 88 |
description=description,live=True
|
| 89 |
)
|
| 90 |
if __name__ == "__main__":
|