Spaces:
Runtime error
Runtime error
Commit
·
6377419
1
Parent(s):
363bdc5
feat: added cloud models and images
Browse files
app.py
CHANGED
@@ -30,8 +30,8 @@ cloud_categories = (
|
|
30 |
)
|
31 |
|
32 |
cloud_examples = [image_path / f"{c}.jpg" for c in cloud_categories]
|
33 |
-
cloud_examples
|
34 |
|
|
|
35 |
|
36 |
def is_cat(x): return x[0].isupper()
|
37 |
|
@@ -47,5 +47,5 @@ image= gr.inputs.Image(shape=(192, 192))
|
|
47 |
label = gr.outputs.Label()
|
48 |
examples = ['dog.jpg', 'cat.jpg', 'dunno.jpg']
|
49 |
|
50 |
-
intf = gr.Interface(fn=classify_image, inputs=image, outputs=label, examples=
|
51 |
intf.launch(inline=False)
|
|
|
30 |
)
|
31 |
|
32 |
cloud_examples = [image_path / f"{c}.jpg" for c in cloud_categories]
|
|
|
33 |
|
34 |
+
cloud_learner = load_learner(model_path/'cloudmodel.pkl')
|
35 |
|
36 |
def is_cat(x): return x[0].isupper()
|
37 |
|
|
|
47 |
label = gr.outputs.Label()
|
48 |
examples = ['dog.jpg', 'cat.jpg', 'dunno.jpg']
|
49 |
|
50 |
+
intf = gr.Interface(fn=classify_image, inputs=image, outputs=label, examples=cloud_examples)
|
51 |
intf.launch(inline=False)
|