Spaces:
Runtime error
Runtime error
cybernatedArt
commited on
Commit
·
7ba9fc9
1
Parent(s):
a25ca20
Update app.py
Browse files
app.py
CHANGED
@@ -19,9 +19,9 @@ labels = ['Acne and Rosacea Photos',
|
|
19 |
'Tinea Ringworm Candidiasis and other Fungal Infections',
|
20 |
'Urticaria Hives', 'Vascular Tumors', 'Vasculitis Photos', 'Warts Molluscum and other Viral Infections']
|
21 |
|
22 |
-
def classify_image(
|
23 |
-
|
24 |
-
prediction = model.predict(
|
25 |
confidences = {labels[i]: float(prediction[i]) for i in range(23)}
|
26 |
return confidences
|
27 |
|
|
|
19 |
'Tinea Ringworm Candidiasis and other Fungal Infections',
|
20 |
'Urticaria Hives', 'Vascular Tumors', 'Vasculitis Photos', 'Warts Molluscum and other Viral Infections']
|
21 |
|
22 |
+
def classify_image(photos):
|
23 |
+
photos = photos.reshape((-1, 256, 256, 3))
|
24 |
+
prediction = model.predict(photos).flatten()
|
25 |
confidences = {labels[i]: float(prediction[i]) for i in range(23)}
|
26 |
return confidences
|
27 |
|