3v324v23 commited on
Commit
c5aeacd
·
1 Parent(s): 5e3ff34

share online

Browse files
Files changed (1) hide show
  1. app.py +6 -3
app.py CHANGED
@@ -2,11 +2,14 @@ import numpy as np
2
  import torch
3
  import gradio as gr
4
  from infer import detections
 
5
  import os
6
  os.system("mkdir data")
7
  os.system("mkdir data/models")
8
- os.system("wget https://www.cs.cmu.edu/~walt/models/walt_people.pth -O data/models/walt_people.pth")
9
- os.system("wget https://www.cs.cmu.edu/~walt/models/walt_vehicle.pth -O data/models/walt_vehicle.pth")
 
 
10
  '''
11
  '''
12
  def walt_demo(input_img, confidence_threshold):
@@ -74,6 +77,6 @@ demo = gr.Interface(walt_demo,
74
  description=description)
75
 
76
  #demo.launch(server_name="0.0.0.0", server_port=7000)
77
- demo.launch()
78
 
79
 
 
2
  import torch
3
  import gradio as gr
4
  from infer import detections
5
+
6
  import os
7
  os.system("mkdir data")
8
  os.system("mkdir data/models")
9
+ if not os.path.exists("data/models/walt_people.pth"):
10
+ os.system("wget https://www.cs.cmu.edu/~walt/models/walt_people.pth -O data/models/walt_people.pth")
11
+ if not os.path.exists("data/models/walt_vehicle.pth"):
12
+ os.system("wget https://www.cs.cmu.edu/~walt/models/walt_vehicle.pth -O data/models/walt_vehicle.pth")
13
  '''
14
  '''
15
  def walt_demo(input_img, confidence_threshold):
 
77
  description=description)
78
 
79
  #demo.launch(server_name="0.0.0.0", server_port=7000)
80
+ demo.launch(share=True)
81
 
82