Sa-m commited on
Commit
4233cde
1 Parent(s): 0341cbc

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -8,14 +8,14 @@ def detect(inp):
8
  os.system('python ./yolov7/detect.py --weights ./yolov7/runs/train/yolov7/weights/best.pt --conf 0.25 --img-size 640 --source f{inp} "--project","./yolov7/runs/detect ')
9
  otp=inp.split('/')[2]
10
  return f"./yolov7/runs/detect/exp2/*"
11
- #f"{inp.split('/')[2]}"
12
  #f"./yolov7/runs/detect/exp/{otp}"
13
 
14
  inp = gr.inputs.Image(type="filepath", label="Input")
15
  output = gr.outputs.Image(type="filepath", label="Output")
16
  #.outputs.Textbox()
17
 
18
- io=gr.Interface(fn=detect, inputs=inp, outputs=output, title='Pot Hole Detection With Custom YOLOv7 ')
19
  #,examples=["Examples/img-300_jpg.rf.6b7b035dff1cda092ce3dc22be8d0135.jpg"]
20
  io.launch(debug=True,share=False)
21
 
 
8
  os.system('python ./yolov7/detect.py --weights ./yolov7/runs/train/yolov7/weights/best.pt --conf 0.25 --img-size 640 --source f{inp} "--project","./yolov7/runs/detect ')
9
  otp=inp.split('/')[2]
10
  return f"./yolov7/runs/detect/exp2/*"
11
+
12
  #f"./yolov7/runs/detect/exp/{otp}"
13
 
14
  inp = gr.inputs.Image(type="filepath", label="Input")
15
  output = gr.outputs.Image(type="filepath", label="Output")
16
  #.outputs.Textbox()
17
 
18
+ io=gr.Interface(fn=detect, inputs=inp, outputs=output, title='Pot Hole Detection With Custom YOLOv7 ',examples=[["Examples/img-300_jpg.rf.6b7b035dff1cda092ce3dc22be8d0135.jpg"]])
19
  #,examples=["Examples/img-300_jpg.rf.6b7b035dff1cda092ce3dc22be8d0135.jpg"]
20
  io.launch(debug=True,share=False)
21