Spaces:
Runtime error
Runtime error
more examples
Browse files
app.py
CHANGED
@@ -31,14 +31,18 @@ url = "https://upload.wikimedia.org/wikipedia/commons/thumb/6/63/Monarch_In_May.
|
|
31 |
path_input = "./d_plexippus.jpg"
|
32 |
urllib.request.urlretrieve(url, filename=path_input)
|
33 |
|
34 |
-
url = "https://drive.google.com/uc?id=
|
35 |
-
path_input = "./
|
36 |
urllib.request.urlretrieve(url, filename=path_input)
|
37 |
|
38 |
url = "https://drive.google.com/uc?id=1CiWShQYIm2N0fkVaWJpftlXZFqwjsXhA"
|
39 |
path_input = "./p_cresphontes.jpg"
|
40 |
urllib.request.urlretrieve(url, filename=path_input)
|
41 |
|
|
|
|
|
|
|
|
|
42 |
|
43 |
# normalisation
|
44 |
data_transforms_test = transforms.Compose([
|
@@ -96,7 +100,7 @@ im = gr.inputs.Image(shape=(512, 512), image_mode='RGB',
|
|
96 |
|
97 |
title = "Butterfly Classification Demo"
|
98 |
description = "A pretrained ResNet18 CNN trained on the Leeds Butterfly Dataset. Libraries: PyTorch, Gradio."
|
99 |
-
examples = [['./h_erato.jpg'],['d_plexippus.jpg'],['
|
100 |
article_text = markdown.markdown('''
|
101 |
|
102 |
<h1 style="color:white">PyTorch image classification - A pretrained ResNet18 CNN trained on the <a href="http://www.josiahwang.com/dataset/leedsbutterfly/">Leeds Butterfly Dataset</a></h1>
|
|
|
31 |
path_input = "./d_plexippus.jpg"
|
32 |
urllib.request.urlretrieve(url, filename=path_input)
|
33 |
|
34 |
+
url = "https://drive.google.com/uc?id=1A7WgDrQ_RLO6JOQiYhkH_hj_EKcbpmOl"
|
35 |
+
path_input = "./v_cardui.jpg"
|
36 |
urllib.request.urlretrieve(url, filename=path_input)
|
37 |
|
38 |
url = "https://drive.google.com/uc?id=1CiWShQYIm2N0fkVaWJpftlXZFqwjsXhA"
|
39 |
path_input = "./p_cresphontes.jpg"
|
40 |
urllib.request.urlretrieve(url, filename=path_input)
|
41 |
|
42 |
+
url = "https://drive.google.com/uc?id=1r8rbkUwTSIZL0MQVgU-WjDGwvLXuwYPG"
|
43 |
+
path_input = "./p_rapae.jpg"
|
44 |
+
urllib.request.urlretrieve(url, filename=path_input)
|
45 |
+
|
46 |
|
47 |
# normalisation
|
48 |
data_transforms_test = transforms.Compose([
|
|
|
100 |
|
101 |
title = "Butterfly Classification Demo"
|
102 |
description = "A pretrained ResNet18 CNN trained on the Leeds Butterfly Dataset. Libraries: PyTorch, Gradio."
|
103 |
+
examples = [['./h_erato.jpg'],['d_plexippus.jpg'],['v_cardui.jpg'],['p_cresphontes.jpg'],['p_rapae.jpg']]
|
104 |
article_text = markdown.markdown('''
|
105 |
|
106 |
<h1 style="color:white">PyTorch image classification - A pretrained ResNet18 CNN trained on the <a href="http://www.josiahwang.com/dataset/leedsbutterfly/">Leeds Butterfly Dataset</a></h1>
|