Spaces:
Build error
Build error
Update app.py
Browse files
app.py
CHANGED
@@ -35,10 +35,11 @@ torch.hub.download_url_to_file('https://github.com/AaronCWacker/Yggdrasil/blob/m
|
|
35 |
torch.hub.download_url_to_file('https://github.com/AaronCWacker/Yggdrasil/blob/main/images/44-Game-Pieces.jpg', '44-Game-Pieces.jpg')
|
36 |
torch.hub.download_url_to_file('https://github.com/AaronCWacker/Yggdrasil/blob/main/images/45-Choose-Your-Own-Adventure.jpg', '45-Choose-Your-Own-Adventure.jpg')
|
37 |
torch.hub.download_url_to_file('https://github.com/AaronCWacker/Yggdrasil/blob/main/images/46-Choose-Your-Own-Adventure.jpg', '46-Choose-Your-Own-Adventure.jpg')
|
38 |
-
torch.hub.download_url_to_file('https://github.com/JaidedAI/EasyOCR/raw/master/examples/english.png', 'english.png')
|
39 |
-
torch.hub.download_url_to_file('https://github.com/JaidedAI/EasyOCR/raw/master/examples/chinese.jpg', 'chinese.jpg')
|
40 |
-
torch.hub.download_url_to_file('https://github.com/JaidedAI/EasyOCR/raw/master/examples/japanese.jpg', 'japanese.jpg')
|
41 |
#torch.hub.download_url_to_file('https://i.imgur.com/mwQFd7G.jpeg', 'Hindi.jpeg')
|
|
|
42 |
examples = [['20-Books.jpg',['en']],
|
43 |
['21-Books.jpg',['en']],
|
44 |
['22-Magazines.jpg',['en']],
|
@@ -66,13 +67,13 @@ examples = [['20-Books.jpg',['en']],
|
|
66 |
['43-Games-Pieces.jpg',['en']],
|
67 |
['44-Game-Pieces.jpg',['en']],
|
68 |
['45-Choose-Your-Own-Adventure.jpg',['en']],
|
69 |
-
['46-Choose-Your-Own-Adventure.jpg',['en']]
|
70 |
-
['english.png',['en']],
|
71 |
-
['chinese.jpg',['ch_sim', 'en']],
|
72 |
-
['japanese.jpg',['ja', 'en']],
|
73 |
-
#['Hindi.jpeg',['hi', 'en']]
|
74 |
-
]
|
75 |
|
|
|
|
|
|
|
|
|
|
|
76 |
|
77 |
def draw_boxes(image, bounds, color='yellow', width=2):
|
78 |
draw = ImageDraw.Draw(image)
|
|
|
35 |
torch.hub.download_url_to_file('https://github.com/AaronCWacker/Yggdrasil/blob/main/images/44-Game-Pieces.jpg', '44-Game-Pieces.jpg')
|
36 |
torch.hub.download_url_to_file('https://github.com/AaronCWacker/Yggdrasil/blob/main/images/45-Choose-Your-Own-Adventure.jpg', '45-Choose-Your-Own-Adventure.jpg')
|
37 |
torch.hub.download_url_to_file('https://github.com/AaronCWacker/Yggdrasil/blob/main/images/46-Choose-Your-Own-Adventure.jpg', '46-Choose-Your-Own-Adventure.jpg')
|
38 |
+
#torch.hub.download_url_to_file('https://github.com/JaidedAI/EasyOCR/raw/master/examples/english.png', 'english.png')
|
39 |
+
#torch.hub.download_url_to_file('https://github.com/JaidedAI/EasyOCR/raw/master/examples/chinese.jpg', 'chinese.jpg')
|
40 |
+
#torch.hub.download_url_to_file('https://github.com/JaidedAI/EasyOCR/raw/master/examples/japanese.jpg', 'japanese.jpg')
|
41 |
#torch.hub.download_url_to_file('https://i.imgur.com/mwQFd7G.jpeg', 'Hindi.jpeg')
|
42 |
+
|
43 |
examples = [['20-Books.jpg',['en']],
|
44 |
['21-Books.jpg',['en']],
|
45 |
['22-Magazines.jpg',['en']],
|
|
|
67 |
['43-Games-Pieces.jpg',['en']],
|
68 |
['44-Game-Pieces.jpg',['en']],
|
69 |
['45-Choose-Your-Own-Adventure.jpg',['en']],
|
70 |
+
['46-Choose-Your-Own-Adventure.jpg',['en']]]
|
|
|
|
|
|
|
|
|
|
|
71 |
|
72 |
+
# Comment
|
73 |
+
#['english.png',['en']],
|
74 |
+
#['chinese.jpg',['ch_sim', 'en']],
|
75 |
+
#['japanese.jpg',['ja', 'en']],
|
76 |
+
#['Hindi.jpeg',['hi', 'en']]
|
77 |
|
78 |
def draw_boxes(image, bounds, color='yellow', width=2):
|
79 |
draw = ImageDraw.Draw(image)
|