elimino problema path
Browse files
app.py
CHANGED
@@ -3,11 +3,7 @@ from fastai.vision.all import *
|
|
3 |
import gradio as gr
|
4 |
|
5 |
def is_cat(x): return x[0].isupper()
|
6 |
-
import pathlib
|
7 |
-
temp = pathlib.PosixPath
|
8 |
-
pathlib.PosixPath = pathlib.WindowsPath
|
9 |
learn = load_learner('model.pkl')
|
10 |
-
pathlib.PosixPath = temp
|
11 |
categories = ('Dog', 'Cat')
|
12 |
def classify_image(img):
|
13 |
pred,idx,probs = learn.predict(img)
|
|
|
3 |
import gradio as gr
|
4 |
|
5 |
def is_cat(x): return x[0].isupper()
|
|
|
|
|
|
|
6 |
learn = load_learner('model.pkl')
|
|
|
7 |
categories = ('Dog', 'Cat')
|
8 |
def classify_image(img):
|
9 |
pred,idx,probs = learn.predict(img)
|