manikandan18ramalingam commited on
Commit
e396cd9
·
verified ·
1 Parent(s): 1f2862c

Update traffic_sign_detection.py

Browse files
Files changed (1) hide show
  1. traffic_sign_detection.py +3 -1
traffic_sign_detection.py CHANGED
@@ -5,6 +5,7 @@ import os
5
  import shutil
6
  import cv2
7
  import subprocess
 
8
 
9
  # Method to detect objects with given confidence score
10
 
@@ -33,7 +34,8 @@ def detectTrafficObjects(imageFile, confidence_score):
33
  for box in result.boxes:
34
  print(f"Class: {model.names[int(box.cls)]}, Confidence: {box.conf}, Coordinates: {box.xyxy}")
35
  output_path = f"{current_path}/output"
36
- #shutil.move(results[0].save_path, output_path)
 
37
  # Path to the saved image in the custom directory
38
  image_path = f"{custom_save_dir}/{imageFile}"
39
 
 
5
  import shutil
6
  import cv2
7
  import subprocess
8
+ from pathlib import Path
9
 
10
  # Method to detect objects with given confidence score
11
 
 
34
  for box in result.boxes:
35
  print(f"Class: {model.names[int(box.cls)]}, Confidence: {box.conf}, Coordinates: {box.xyxy}")
36
  output_path = f"{current_path}/output"
37
+ #shutil.move(results[0].save_path, output_path)
38
+
39
  # Path to the saved image in the custom directory
40
  image_path = f"{custom_save_dir}/{imageFile}"
41