Hanxiao Xiang commited on
Commit
8dbea36
1 Parent(s): 819878b

try to start app.py

Browse files
Files changed (2) hide show
  1. app.py +9 -1
  2. requirements.txt +1 -9
app.py CHANGED
@@ -1,3 +1,11 @@
 
 
 
 
 
 
 
 
1
  import numpy as np
2
  import gradio as gr
3
  import requests
@@ -320,4 +328,4 @@ with gr.Blocks() as demo:
320
  model2_button.click(model2_rem, inputs=model2_input, outputs=[model2_output_img, running_info])
321
  model3_button.click(model3_ext, inputs=[model3_input, model3_slider], outputs=[model3_output_img, running_info])
322
  model4_button.click(model4_clo, inputs=model4_input, outputs=[model4_output_img, model4_output_df, running_info])
323
- demo.launch(share=True)
 
1
+ import subprocess
2
+ subprocess.call("mim install 'mmengine>=0.6.0'", shell=True)
3
+ subprocess.call("mim install 'mmcv>=2.0.0rc4,<2.1.0'", shell=True)
4
+ subprocess.call("min install 'mmdet>=3.0.0,<4.0.0'", shell=True)
5
+ subprocess.call("mim install 'mmyolo'", shell=True)
6
+ subprocess.call("mim install 'mmpose'", shell=True)
7
+ subprocess.call("mim install 'mmpretrain'", shell=True)
8
+
9
  import numpy as np
10
  import gradio as gr
11
  import requests
 
328
  model2_button.click(model2_rem, inputs=model2_input, outputs=[model2_output_img, running_info])
329
  model3_button.click(model3_ext, inputs=[model3_input, model3_slider], outputs=[model3_output_img, running_info])
330
  model4_button.click(model4_clo, inputs=model4_input, outputs=[model4_output_img, model4_output_df, running_info])
331
+ demo.launch()
requirements.txt CHANGED
@@ -1,14 +1,6 @@
1
- mmcv==2.0.0
2
- mmdet==3.0.0
3
- mmengine==0.8.4
4
- mmpose==1.1.0
5
- mmpretrain==1.0.2
6
- mmyolo==0.6.0
7
- numpy==1.23.5
8
  opencv-python==4.7.0.72
9
  openmim==0.3.7
10
- pandas==2.0.0
11
  pillow==9.4.0
12
- pip==23.0.1
13
  pycocotools==2.0.7
14
  scipy==1.10.1
 
 
 
 
 
 
 
 
 
1
  opencv-python==4.7.0.72
2
  openmim==0.3.7
 
3
  pillow==9.4.0
 
4
  pycocotools==2.0.7
5
  scipy==1.10.1
6
+ torch==2.0.1