Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -3,6 +3,8 @@ import torch
|
|
3 |
from diffusers import AutoPipelineForText2Image
|
4 |
from io import BytesIO
|
5 |
import asyncio
|
|
|
|
|
6 |
|
7 |
# Load the model once outside of the function
|
8 |
model = AutoPipelineForText2Image.from_pretrained("stabilityai/sdxl-turbo")
|
@@ -62,4 +64,4 @@ gradio_interface = gr.Interface(
|
|
62 |
)
|
63 |
|
64 |
if __name__ == "__main__":
|
65 |
-
gradio_interface.launch() # No need for share=True for local testing
|
|
|
3 |
from diffusers import AutoPipelineForText2Image
|
4 |
from io import BytesIO
|
5 |
import asyncio
|
6 |
+
from generate_propmts import generate_prompt
|
7 |
+
from concurrent.futures import ThreadPoolExecutor, as_completed
|
8 |
|
9 |
# Load the model once outside of the function
|
10 |
model = AutoPipelineForText2Image.from_pretrained("stabilityai/sdxl-turbo")
|
|
|
64 |
)
|
65 |
|
66 |
if __name__ == "__main__":
|
67 |
+
gradio_interface.launch() # No need for share=True for local testing
|