remotewith commited on
Commit
24dbaa5
·
1 Parent(s): 0b95222

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -3
app.py CHANGED
@@ -55,9 +55,8 @@ def predict(img):
55
  start_time = timer()
56
 
57
  # Transform the target image and add a batch dimension
58
- image = cv2.imread(img)
59
- img1 = PIL.Image.open(img)
60
- img1 = effnetb2_transforms(img1).unsqueeze(0)
61
  pix = normalize_2d(np.array(img))
62
 
63
  pix1=model.predict(str(image), confidence=40, overlap=30).numpy()
 
55
  start_time = timer()
56
 
57
  # Transform the target image and add a batch dimension
58
+
59
+ img1 = effnetb2_transforms(img).unsqueeze(0)
 
60
  pix = normalize_2d(np.array(img))
61
 
62
  pix1=model.predict(str(image), confidence=40, overlap=30).numpy()