You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

53 lines
2.4 KiB

  1. import os
  2. class PARAMS(object):
  3. #change this pycharme-'../' ,cmd = './'
  4. _CMD_PMT_ = './' # '../'
  5. #Object Detection
  6. _YOLOV3_OD_WEIGHT = os.path.join(_CMD_PMT_,'resources/trainedModels/yolov3_object_detection/yolov3.weights')
  7. _YOLOV3_OD_MODEL_CFG = os.path.join(_CMD_PMT_,'resources/trainedModels/yolov3_object_detection/yolov3.cfg')
  8. _YOLOV3_OD_CLASS_NAMES = os.path.join(_CMD_PMT_,'resources/trainedModels/yolov3_object_detection/coco-labels')
  9. _YOLOV3_OD_CONFIDENCE = 0.5
  10. _YOLOV3_OD_THRESHOLD = 0.3
  11. _YOLOV3_OD_INPUT_IMAGE_SIZE = (416,416) #(Width, Height)
  12. #_YOLOV3_OD_NUMBER_PLATE_OBJECT_LIST = ['car','bus','truck','motorbike']
  13. _YOLOV3_OD_NUMBER_PLATE_OBJECT_LIST = ['car']
  14. _OBJECT_DETECTION_PROCESS_CORES = 2
  15. # Number Plate Detection
  16. _YOLOV3_NP_WEIGHT = os.path.join(_CMD_PMT_,'resources/trainedModels/yolov3_number_plate_detection/lapi.weights')
  17. _YOLOV3_NP_MODEL_CFG = os.path.join(_CMD_PMT_,'resources/trainedModels/yolov3_number_plate_detection/darknet-yolov3.cfg')
  18. _YOLOV3_NP_CLASS_NAMES = os.path.join(_CMD_PMT_,'resources/trainedModels/yolov3_number_plate_detection/classes.names')
  19. _YOLOV3_NP_CONFIDENCE = 0.5
  20. _YOLOV3_NP_THRESHOLD = 0.4
  21. _YOLOV3_NP_INPUT_IMAGE_SIZE_DEFAULT = (608, 608) ##(Width, Height)
  22. _YOLOV3_NP_INPUT_IMAGE_SIZE_CONFIG1 = (256, 128) #(Width, Height)
  23. _YOLOV3_NP_INPUT_IMAGE_SIZE_CONFIG2 = (256, 256) #(Width, Height)
  24. #Lane Direction
  25. _TRAFFIC_DIRECTION = 'H-Increasing' #Decreasing' #H-Increasing
  26. # _TRAFFIC_DIRECTION = 'H-Decreasing' #Decreasing' #H-Increasing
  27. _ASSIGN_DIRECTION_HEIGHT_PERCENT = 0.20
  28. _DECIDE_DIRECTION_AFTER_FRAMES_TRACKERING = 5
  29. _DIRECTION_STRING_WRONG = 'Opposite Direction'
  30. _DIRECTION_STRING_RIGHT = 'Right Direction'
  31. _CAMERA_IMAGE_ORIGIN = 'H00' #H11 #H00- origing is top left corner
  32. _START_TRCAKER_MARGIN_PERCENT_HEIGHT = 0.15
  33. _NUM_FRAME_TRACKER_ALIVE_AFTER_MISS = 3
  34. #_TRACKER_OBJECT_LIST = ['car', 'bus', 'truck', 'motorbike']#'person']
  35. _TRACKER_OBJECT_LIST = ['car']#'person']
  36. #no-parking
  37. _NO_PARAKING_LINE_POINT_1_XY = (340,1080)
  38. _NO_PARAKING_LINE_POINT_2_XY = (1225,0)
  39. _NO_PARAKING_SIDE_OF_LINE = 'RIGHT'
  40. _PARKING_STRING = 'WRONG PARKING'
  41. #Algo mode
  42. _ALGO_MODE_PARKING = False
  43. _ALGO_MODE_NUMBER_PLATE = True
  44. _ALGO_MODE_KALMAN_TRCAKING = True
  45. #logo
  46. LOGO_FILE_PATH = os.path.join(_CMD_PMT_,'resources/logo.png')