Update app.py
Browse files
app.py
CHANGED
|
@@ -10,5 +10,10 @@ def image_classifier(img):
|
|
| 10 |
pred,pred_idx,probs = model_inf.predict(img)
|
| 11 |
return dict(zip(categories,map(float,probs)))
|
| 12 |
examples_arch=['ArtDeco.jpg','Byzantine.jpg','Gothic.jpg','Neoclassical.jpg']
|
| 13 |
-
intrf=
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 14 |
intrf.launch(inline=False)
|
|
|
|
| 10 |
pred,pred_idx,probs = model_inf.predict(img)
|
| 11 |
return dict(zip(categories,map(float,probs)))
|
| 12 |
examples_arch=['ArtDeco.jpg','Byzantine.jpg','Gothic.jpg','Neoclassical.jpg']
|
| 13 |
+
intrf=intrf = gr.Interface(
|
| 14 |
+
fn=image_classifier,
|
| 15 |
+
inputs=gr.Image(width=192, height=192), # Updated syntax
|
| 16 |
+
outputs=gr.Label(num_top_classes=4), # Updated syntax
|
| 17 |
+
examples=examples_arch
|
| 18 |
+
)
|
| 19 |
intrf.launch(inline=False)
|