Fix
Browse files
app.py
CHANGED
@@ -90,7 +90,7 @@ def predict(image: PIL.Image.Image, score_threshold: float,
|
|
90 |
preds = preds.cpu().numpy().astype(float)
|
91 |
|
92 |
res = dict()
|
93 |
-
for prob, label in zip(preds, labels):
|
94 |
if prob < score_threshold:
|
95 |
continue
|
96 |
res[label] = prob
|
|
|
90 |
preds = preds.cpu().numpy().astype(float)
|
91 |
|
92 |
res = dict()
|
93 |
+
for prob, label in zip(preds.tolist(), labels):
|
94 |
if prob < score_threshold:
|
95 |
continue
|
96 |
res[label] = prob
|