AkashDataScience commited on
Commit
7b45f67
·
1 Parent(s): 307f432
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -48,7 +48,7 @@ def inference(input_img, conf_thres, iou_thres):
48
  with dt[0]:
49
  im = letterbox(input_img, imgsz, stride=32, auto=True)[0] # padded resize
50
  im = im.transpose((2, 0, 1))[::-1]
51
- im = torch.from_numpy(input_img).to(model.device)
52
  im = im.half() if model.fp16 else im.float() # uint8 to fp16/32
53
  im /= 255 # 0 - 255 to 0.0 - 1.0
54
  if len(im.shape) == 3:
 
48
  with dt[0]:
49
  im = letterbox(input_img, imgsz, stride=32, auto=True)[0] # padded resize
50
  im = im.transpose((2, 0, 1))[::-1]
51
+ im = torch.from_numpy(im).to(model.device)
52
  im = im.half() if model.fp16 else im.float() # uint8 to fp16/32
53
  im /= 255 # 0 - 255 to 0.0 - 1.0
54
  if len(im.shape) == 3: