Spaces:
Runtime error
Runtime error
installed additional packages
Browse files- app.py +0 -1
- app.py.197bbcc06daf9e04d14c423527374e94.tmp +0 -22
app.py
CHANGED
@@ -10,7 +10,6 @@ learn = load_learner('model.pkl')
|
|
10 |
|
11 |
#|export
|
12 |
categories = ('Dog', 'Cat')
|
13 |
-
|
14 |
def classify_image(im):
|
15 |
pred, idx, probs = learn.predict(im)
|
16 |
return dict(zip(categories, map(float, probs)))
|
|
|
10 |
|
11 |
#|export
|
12 |
categories = ('Dog', 'Cat')
|
|
|
13 |
def classify_image(im):
|
14 |
pred, idx, probs = learn.predict(im)
|
15 |
return dict(zip(categories, map(float, probs)))
|
app.py.197bbcc06daf9e04d14c423527374e94.tmp
DELETED
@@ -1,22 +0,0 @@
|
|
1 |
-
#|export
|
2 |
-
from fastai.vision.all import *
|
3 |
-
import gradio as gr
|
4 |
-
from fastbook import *
|
5 |
-
|
6 |
-
def is_cat(x): return x[0].isupper()
|
7 |
-
|
8 |
-
#|export
|
9 |
-
learn = load_learner('model.pkl')
|
10 |
-
|
11 |
-
#|export
|
12 |
-
categories = ('Dog', 'Cat')
|
13 |
-
def classify_image(im):
|
14 |
-
pred, idx, probs = learn.predict(im)
|
15 |
-
return dict(zip(categories, map(float, probs)))
|
16 |
-
|
17 |
-
#|export
|
18 |
-
categories = ('Dog', 'Cat')
|
19 |
-
|
20 |
-
def classify_image(im):
|
21 |
-
pred, idx, probs = learn.predict(im)
|
22 |
-
return dict(zip(categories, map(float, probs)))
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|