Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -25,7 +25,7 @@ def predict(image):
|
|
25 |
logits_positive[logits < 0] = 0
|
26 |
logits_positive = logits_positive/np.sum(logits_positive)
|
27 |
confidences = {}
|
28 |
-
for i in range(len(labels):
|
29 |
if logits[i]>0:
|
30 |
confidences[labels[i]] = float(logits_positive[i])
|
31 |
return confidences
|
|
|
25 |
logits_positive[logits < 0] = 0
|
26 |
logits_positive = logits_positive/np.sum(logits_positive)
|
27 |
confidences = {}
|
28 |
+
for i in range(len(labels)):
|
29 |
if logits[i]>0:
|
30 |
confidences[labels[i]] = float(logits_positive[i])
|
31 |
return confidences
|