Spaces:
Runtime error
Runtime error
drizzlezyk
commited on
Commit
•
bc93314
1
Parent(s):
c8ac4c6
add warm up
Browse files
app.py
CHANGED
@@ -69,6 +69,9 @@ css = """
|
|
69 |
}
|
70 |
"""
|
71 |
|
|
|
|
|
|
|
72 |
with gr.Blocks(css=css) as demo:
|
73 |
gr.HTML(read_content("./header.html"))
|
74 |
|
@@ -118,5 +121,5 @@ with gr.Blocks(css=css) as demo:
|
|
118 |
inputs=[style_input, desc_input],
|
119 |
outputs=[img_output1, img_output2, img_output3, img_output4])
|
120 |
|
121 |
-
demo.queue(concurrency_count=
|
122 |
-
demo.launch()
|
|
|
69 |
}
|
70 |
"""
|
71 |
|
72 |
+
# warm up
|
73 |
+
generate_figure("梵高", "一只猫", 0)
|
74 |
+
|
75 |
with gr.Blocks(css=css) as demo:
|
76 |
gr.HTML(read_content("./header.html"))
|
77 |
|
|
|
121 |
inputs=[style_input, desc_input],
|
122 |
outputs=[img_output1, img_output2, img_output3, img_output4])
|
123 |
|
124 |
+
demo.queue(concurrency_count=5)
|
125 |
+
demo.launch(enable_queue=True)
|