Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -105,7 +105,7 @@ def detect(img,model):
|
|
105 |
])
|
106 |
model = get_net(cfg)
|
107 |
checkpoint = torch.load(weights, map_location= device)
|
108 |
-
print(checkpoint)
|
109 |
model.load_state_dict(checkpoint['state_dict'])
|
110 |
model = model.to(device)
|
111 |
|
@@ -147,7 +147,7 @@ def detect(img,model):
|
|
147 |
nms_time.update(t4-t3,img.size(0))
|
148 |
det=det_pred[0]
|
149 |
|
150 |
-
save_path = str(
|
151 |
|
152 |
_, _, height, width = img.shape
|
153 |
h,w,_=img_det.shape
|
|
|
105 |
])
|
106 |
model = get_net(cfg)
|
107 |
checkpoint = torch.load(weights, map_location= device)
|
108 |
+
#print(checkpoint)
|
109 |
model.load_state_dict(checkpoint['state_dict'])
|
110 |
model = model.to(device)
|
111 |
|
|
|
147 |
nms_time.update(t4-t3,img.size(0))
|
148 |
det=det_pred[0]
|
149 |
|
150 |
+
save_path = str(save_dir +'/'+ Path(path).name)
|
151 |
|
152 |
_, _, height, width = img.shape
|
153 |
h,w,_=img_det.shape
|