hank1996 commited on
Commit
8370e1e
·
1 Parent(s): 27bbd71

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -83,7 +83,7 @@ def detect(img,model):
83
  #imgsz = check_img_size(imgsz, s=stride) # check img_size
84
  print(weights)
85
  stride =32
86
- model = torch.jit.load(weights)
87
  print(model)
88
  imgsz = check_img_size(imgsz, s=stride)
89
  #model = model.to(device)
 
83
  #imgsz = check_img_size(imgsz, s=stride) # check img_size
84
  print(weights)
85
  stride =32
86
+ model = torch.jit.load(weights,map_location=device)
87
  print(model)
88
  imgsz = check_img_size(imgsz, s=stride)
89
  #model = model.to(device)