zachwormgoor@gmail.com
commited on
Commit
•
1987bed
1
Parent(s):
fd97f18
troubleshooting
Browse files
app.py
CHANGED
@@ -1,3 +1,9 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
from fast.ai.vision.all import *
|
2 |
import gradio as gr
|
3 |
|
@@ -33,6 +39,10 @@ def classify(img):
|
|
33 |
image = gr.inputs.Image(shape=(192, 192))
|
34 |
label = gr.outputs.Label()
|
35 |
examples = ['stock.jpg', 'amateur.jpg', 'unsure.jpg']
|
|
|
|
|
|
|
|
|
36 |
|
37 |
intf = gr.Interface(fn=classify_image, inputs=image, outputs=label, examples=examples)
|
38 |
intf.launch(inline=False)
|
|
|
1 |
+
|
2 |
+
|
3 |
+
|
4 |
+
|
5 |
+
__all__ = ['learn', 'categories', 'classify', 'image', 'label', 'examples', 'intf']
|
6 |
+
|
7 |
from fast.ai.vision.all import *
|
8 |
import gradio as gr
|
9 |
|
|
|
39 |
image = gr.inputs.Image(shape=(192, 192))
|
40 |
label = gr.outputs.Label()
|
41 |
examples = ['stock.jpg', 'amateur.jpg', 'unsure.jpg']
|
42 |
+
# stock: https://image.shutterstock.com/image-photo/industrial-interior-storage-tank-rusty-260nw-132762554.jpg
|
43 |
+
# amateur: https://cimg3.ibsrv.net/cimg/www.honda-tech.com/1024x768_85/479/AAApril-2-Control-Arms-01-58479.jpg
|
44 |
+
# unsure: https://en.wikipedia.org/wiki/Joshua_Bean
|
45 |
+
|
46 |
|
47 |
intf = gr.Interface(fn=classify_image, inputs=image, outputs=label, examples=examples)
|
48 |
intf.launch(inline=False)
|