mirror of
https://github.com/serengil/deepface.git
synced 2025-06-08 12:35:22 +00:00
Fixed bug with ssd facebox region
This commit is contained in:
parent
e22072142e
commit
1f8bea146e
3
.gitignore
vendored
3
.gitignore
vendored
@ -14,4 +14,5 @@ deepface/commons/__pycache__/*
|
||||
deepface/basemodels/__pycache__/*
|
||||
deepface/extendedmodels/__pycache__/*
|
||||
deepface/subsidiarymodels/__pycache__/*
|
||||
tests/dataset/*.pkl
|
||||
tests/dataset/*.pkl
|
||||
Age_Gender_Retail_Analysis.ipynb
|
@ -260,7 +260,7 @@ def detect_face(img, detector_backend = 'opencv', grayscale = False, enforce_det
|
||||
|
||||
detected_face = base_img[int(top*aspect_ratio_y):int(bottom*aspect_ratio_y), int(left*aspect_ratio_x):int(right*aspect_ratio_x)]
|
||||
|
||||
return detected_face, [int(left*aspect_ratio_x), int(top*aspect_ratio_y), int(right*aspect_ratio_y) - int(left*aspect_ratio_x), int(bottom*aspect_ratio_y) - int(top*aspect_ratio_y)]
|
||||
return detected_face, [int(left*aspect_ratio_x), int(top*aspect_ratio_y), int(right*aspect_ratio_x) - int(left*aspect_ratio_x), int(bottom*aspect_ratio_y) - int(top*aspect_ratio_y)]
|
||||
|
||||
else: #if no face detected
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user