Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -18,7 +18,7 @@ def predict_image(img):
|
|
| 18 |
img = transforms.Resize((256,256))(img)
|
| 19 |
prediction=clf.predict(img)
|
| 20 |
print(prediction)
|
| 21 |
-
|
| 22 |
return {class_names[i]: float(prediction[i]["score"]) for i in range(2)}
|
| 23 |
|
| 24 |
image = gr.Image(label="Image to Analyze", sources=['upload'])
|
|
|
|
| 18 |
img = transforms.Resize((256,256))(img)
|
| 19 |
prediction=clf.predict(img)
|
| 20 |
print(prediction)
|
| 21 |
+
|
| 22 |
return {class_names[i]: float(prediction[i]["score"]) for i in range(2)}
|
| 23 |
|
| 24 |
image = gr.Image(label="Image to Analyze", sources=['upload'])
|