jasongzy commited on
Commit
5a084c5
Β·
1 Parent(s): 9b4f1c7

🐞 fix: try to use ZeroGPU

Browse files
Files changed (2) hide show
  1. app.py +8 -1
  2. run.sh β†’ install.sh +1 -2
app.py CHANGED
@@ -1,3 +1,10 @@
1
  import os
2
 
3
- os.system("bash run.sh")
 
 
 
 
 
 
 
 
1
  import os
2
 
3
+ os.chdir(os.path.dirname(os.path.abspath(__file__)))
4
+ os.system("bash install.sh")
5
+
6
+ from app.app import *
7
+
8
+ init_models()
9
+ demo = init_blocks()
10
+ demo.launch(server_name="0.0.0.0", server_port=7860, allowed_paths=["."], show_error=True, ssr_mode=False)
run.sh β†’ install.sh RENAMED
@@ -12,5 +12,4 @@ rm ~/.gitconfig && \
12
  cd ../.. && \
13
  mv ../model/data/* ./data/ && \
14
  mv ../model/output/* ./output/ && \
15
- rm -r ../model && \
16
- GRADIO_SSR_MODE=False python app.py
 
12
  cd ../.. && \
13
  mv ../model/data/* ./data/ && \
14
  mv ../model/output/* ./output/ && \
15
+ rm -r ../model