Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -2,6 +2,7 @@ import gradio as gr
|
|
2 |
import cv2
|
3 |
import json
|
4 |
import numpy as np
|
|
|
5 |
|
6 |
from pyAAMED import pyAAMED
|
7 |
|
@@ -52,6 +53,11 @@ examples = [
|
|
52 |
["./AAMED/python/002_0038.jpg"]
|
53 |
]
|
54 |
|
|
|
|
|
|
|
|
|
|
|
55 |
gr.Interface(
|
56 |
fn=detect_ellipses,
|
57 |
inputs=gr.Image(label="Upload image with ellipses", type="filepath"),
|
|
|
2 |
import cv2
|
3 |
import json
|
4 |
import numpy as np
|
5 |
+
import glob2 as glob
|
6 |
|
7 |
from pyAAMED import pyAAMED
|
8 |
|
|
|
53 |
["./AAMED/python/002_0038.jpg"]
|
54 |
]
|
55 |
|
56 |
+
test_files = glob.glob('examples/*.jpg') + glob.glob('examples/*.png')
|
57 |
+
|
58 |
+
for f in test_files:
|
59 |
+
examples = examples + [f]
|
60 |
+
|
61 |
gr.Interface(
|
62 |
fn=detect_ellipses,
|
63 |
inputs=gr.Image(label="Upload image with ellipses", type="filepath"),
|