Spaces:
Build error
Build error
diegulio
commited on
Commit
·
31f55ae
1
Parent(s):
7fb5001
fix device yolo
Browse files- .DS_Store +0 -0
- cedula/app.py +1 -1
- license/app.py +1 -2
.DS_Store
ADDED
Binary file (8.2 kB). View file
|
|
cedula/app.py
CHANGED
@@ -109,7 +109,7 @@ def get_attributes(input_img):
|
|
109 |
|
110 |
#images = check_image(input_img)
|
111 |
images = [Image.fromarray(input_img)]
|
112 |
-
images = crop(weights="best.pt", files= images)
|
113 |
#print(images)
|
114 |
image_cedula = [img[0] for img in images if img[1]==0][0] #0 en 'img[1]==0' es el label de cedula, si se reemplaza por 1
|
115 |
#entrega licencias
|
|
|
109 |
|
110 |
#images = check_image(input_img)
|
111 |
images = [Image.fromarray(input_img)]
|
112 |
+
images = crop(weights="best.pt", files= images, device=device)
|
113 |
#print(images)
|
114 |
image_cedula = [img[0] for img in images if img[1]==0][0] #0 en 'img[1]==0' es el label de cedula, si se reemplaza por 1
|
115 |
#entrega licencias
|
license/app.py
CHANGED
@@ -108,7 +108,7 @@ def get_attributes(input_img):
|
|
108 |
model.to(device)
|
109 |
|
110 |
images = [Image.fromarray(input_img)]
|
111 |
-
images = crop(weights="best.pt", files= images)
|
112 |
image_cedula = [img[0] for img in images if img[1]==1][0] #0 en 'img[1]==0' es el label de cedula, si se reemplaza por 1
|
113 |
#entrega licencias
|
114 |
|
@@ -155,7 +155,6 @@ def create_model():
|
|
155 |
)
|
156 |
return demo
|
157 |
|
158 |
-
["examples/licencia.jpg"]
|
159 |
if __name__ == '__main__':
|
160 |
demo = create_model()
|
161 |
demo.launch()
|
|
|
108 |
model.to(device)
|
109 |
|
110 |
images = [Image.fromarray(input_img)]
|
111 |
+
images = crop(weights="best.pt", files= images, device = device)
|
112 |
image_cedula = [img[0] for img in images if img[1]==1][0] #0 en 'img[1]==0' es el label de cedula, si se reemplaza por 1
|
113 |
#entrega licencias
|
114 |
|
|
|
155 |
)
|
156 |
return demo
|
157 |
|
|
|
158 |
if __name__ == '__main__':
|
159 |
demo = create_model()
|
160 |
demo.launch()
|