Update app.py
Browse files
app.py
CHANGED
|
@@ -256,7 +256,7 @@ def detect_objects_video(model_name, video_input, threshold):
|
|
| 256 |
labels = [model.config.id2label[x] for x in labels]
|
| 257 |
|
| 258 |
for score, (xmin, ymin, xmax, ymax), label in zip(scores, boxes, labels):
|
| 259 |
-
if "plate" in label.lower()
|
| 260 |
crop = pil_img.crop((int(xmin), int(ymin), int(xmax), int(ymax)))
|
| 261 |
plate_type = classify_plate_color(crop)
|
| 262 |
|
|
|
|
| 256 |
labels = [model.config.id2label[x] for x in labels]
|
| 257 |
|
| 258 |
for score, (xmin, ymin, xmax, ymax), label in zip(scores, boxes, labels):
|
| 259 |
+
if "plate" in label.lower():
|
| 260 |
crop = pil_img.crop((int(xmin), int(ymin), int(xmax), int(ymax)))
|
| 261 |
plate_type = classify_plate_color(crop)
|
| 262 |
|