Spaces:
Sleeping
Sleeping
Yaron Koresh
commited on
Update app.py
Browse files
app.py
CHANGED
|
@@ -206,7 +206,18 @@ def run(p1,p2,*result):
|
|
| 206 |
|
| 207 |
return out2
|
| 208 |
|
| 209 |
-
def
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 210 |
with gr.Blocks(theme=gr.themes.Soft(),css=css,js=js) as demo:
|
| 211 |
with gr.Column(elem_id="col-container"):
|
| 212 |
gr.Markdown(f"""
|
|
@@ -236,15 +247,4 @@ def ui():
|
|
| 236 |
demo.queue().launch()
|
| 237 |
|
| 238 |
if __name__ == "__main__":
|
| 239 |
-
|
| 240 |
-
global result
|
| 241 |
-
global pp1
|
| 242 |
-
global pp2
|
| 243 |
-
|
| 244 |
-
result=[]
|
| 245 |
-
pp1=pipe_t2i()
|
| 246 |
-
pp2=pipe_i2i()
|
| 247 |
-
|
| 248 |
-
mp.set_start_method("spawn", force=True)
|
| 249 |
-
#port_inc()
|
| 250 |
-
ui()
|
|
|
|
| 206 |
|
| 207 |
return out2
|
| 208 |
|
| 209 |
+
def main():
|
| 210 |
+
|
| 211 |
+
global result
|
| 212 |
+
global pp1
|
| 213 |
+
global pp2
|
| 214 |
+
|
| 215 |
+
result=[]
|
| 216 |
+
pp1=pipe_t2i()
|
| 217 |
+
pp2=pipe_i2i()
|
| 218 |
+
|
| 219 |
+
mp.set_start_method("spawn", force=True)
|
| 220 |
+
|
| 221 |
with gr.Blocks(theme=gr.themes.Soft(),css=css,js=js) as demo:
|
| 222 |
with gr.Column(elem_id="col-container"):
|
| 223 |
gr.Markdown(f"""
|
|
|
|
| 247 |
demo.queue().launch()
|
| 248 |
|
| 249 |
if __name__ == "__main__":
|
| 250 |
+
main()
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|