Spaces:
Sleeping
Sleeping
brandonchiazzamodali commited on
Commit ·
4100329
1
Parent(s): 574625a
update from
Browse files- app.py +19 -5
- export.pkl +1 -1
- model.ipynb +0 -0
- models/tmpcm3iwc3l/_tmp.pth +0 -3
app.py
CHANGED
|
@@ -13,7 +13,7 @@ __all__ = ['learn_inf', 'categories', 'image', 'label', 'examples', 'enable_queu
|
|
| 13 |
#!pip install pipreqs
|
| 14 |
#!pip install nbconvert
|
| 15 |
|
| 16 |
-
|
| 17 |
import fastbook
|
| 18 |
import gradio as gr
|
| 19 |
import nbdev
|
|
@@ -22,9 +22,9 @@ import os
|
|
| 22 |
import pipreqs
|
| 23 |
import nbconvert
|
| 24 |
fastbook.setup_book()
|
| 25 |
-
"""
|
| 26 |
-
from pathlib import Path
|
| 27 |
|
|
|
|
|
|
|
| 28 |
plt = os.name
|
| 29 |
print(plt)
|
| 30 |
|
|
@@ -44,11 +44,25 @@ from fastai.vision.all import *
|
|
| 44 |
from time import sleep
|
| 45 |
from fastcore.net import urljson, HTTPError
|
| 46 |
|
|
|
|
|
|
|
| 47 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 48 |
|
| 49 |
-
# %% model.ipynb 50
|
| 50 |
-
learn_inf = load_learner('./export.pkl')
|
| 51 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 52 |
|
| 53 |
# %% model.ipynb 54
|
| 54 |
categories = ('car','truck','toy car')
|
|
|
|
| 13 |
#!pip install pipreqs
|
| 14 |
#!pip install nbconvert
|
| 15 |
|
| 16 |
+
"""import pathlib"""
|
| 17 |
import fastbook
|
| 18 |
import gradio as gr
|
| 19 |
import nbdev
|
|
|
|
| 22 |
import pipreqs
|
| 23 |
import nbconvert
|
| 24 |
fastbook.setup_book()
|
|
|
|
|
|
|
| 25 |
|
| 26 |
+
"""from pathlib import Path"""
|
| 27 |
+
"""
|
| 28 |
plt = os.name
|
| 29 |
print(plt)
|
| 30 |
|
|
|
|
| 44 |
from time import sleep
|
| 45 |
from fastcore.net import urljson, HTTPError
|
| 46 |
|
| 47 |
+
from contextlib import contextmanager
|
| 48 |
+
"""import pathlib
|
| 49 |
|
| 50 |
+
@contextmanager
|
| 51 |
+
def set_posix_windows():
|
| 52 |
+
posix_backup = pathlib.PosixPath
|
| 53 |
+
try:
|
| 54 |
+
pathlib.PosixPath = pathlib.WindowsPath
|
| 55 |
+
yield
|
| 56 |
+
finally:
|
| 57 |
+
pathlib.PosixPath = posix_backup
|
| 58 |
+
"""
|
| 59 |
|
|
|
|
|
|
|
| 60 |
|
| 61 |
+
# %% model.ipynb 50
|
| 62 |
+
"""with open(os.path.join('./export.pkl'), 'rb') as f:
|
| 63 |
+
f.read()"""
|
| 64 |
+
learn_inf = load_learner(os.path.join('./export.pkl'), 'rb')
|
| 65 |
+
#__model = pickle.load(open(os.path.join('./export.pkl'), 'rb'))
|
| 66 |
|
| 67 |
# %% model.ipynb 54
|
| 68 |
categories = ('car','truck','toy car')
|
export.pkl
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 46973327
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:8786c3954eee04d919dafa21689132a2df7a017e1b53f4d6a0348fa0e32f062c
|
| 3 |
size 46973327
|
model.ipynb
CHANGED
|
The diff for this file is too large to render.
See raw diff
|
|
|
models/tmpcm3iwc3l/_tmp.pth
DELETED
|
@@ -1,3 +0,0 @@
|
|
| 1 |
-
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:e1345d0a7f71b959190ddf88e7944cf9edef0a3f7e652320de98958a46db5bff
|
| 3 |
-
size 46907239
|
|
|
|
|
|
|
|
|
|
|
|