Spaces:
Build error
Build error
Update app.py
Browse files
app.py
CHANGED
@@ -10,7 +10,7 @@ classnames = ['cardboard', 'metal','paper','plastic','trash','green-glass','whit
|
|
10 |
def predict(img):
|
11 |
img=img.reshape(-1,298, 384,3)
|
12 |
prediction = model.predict(img[0])
|
13 |
-
return {classnames[i]: float(prediction[i]) for i in range(
|
14 |
|
15 |
image = gr.inputs.Image(shape=(298, 384))
|
16 |
label = gr.outputs.Label(num_top_classes=3)
|
|
|
10 |
def predict(img):
|
11 |
img=img.reshape(-1,298, 384,3)
|
12 |
prediction = model.predict(img[0])
|
13 |
+
return {classnames[i]: float(prediction[i]) for i in range(len(classnames)}
|
14 |
|
15 |
image = gr.inputs.Image(shape=(298, 384))
|
16 |
label = gr.outputs.Label(num_top_classes=3)
|