Skip to content

Commit

Permalink
to set front only mode.
Browse files Browse the repository at this point in the history
  • Loading branch information
solderzzc committed Apr 19, 2019
1 parent 72097c0 commit b835c9f
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion env/common.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ export CELERY_RESULT_BACKEND=redis://localhost/0
export ONE_KNOWN_PERSON_BYPASS_QUEUE_MODE=0
export DEEP_ANALYSIS_MODE=1
export SAMPLING_TO_SAVE_ENERGY_MODE=0
export RESTRICT_RECOGNITON_MODE=0
export RESTRICT_RECOGNITON_MODE=1
export MINIMAL_FACE_RESOLUTION=100
export BIGGEST_FACE_ONLY_MODE=0
export UPLOAD_IMAGE_SERVICE_ENABLED=0
Expand Down
4 changes: 2 additions & 2 deletions src/face_detection/detector.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,8 +60,8 @@ def faceStyle(landmark, bb, face_width):
middle_point = (bb[2] + bb[0])/2
y_middle_point = (bb[3] + bb[1]) / 2
eye_distance = abs(eye_1[0]-eye_2[0])
if eye_distance < 10:
print('(Eye distance less than 10 pixels) Add style')
if eye_distance < 2:
print('(Eye distance less than 2 pixels) Add style')
style.append('side_face')
elif eye_1[0] > middle_point:
print('(Left Eye on the Right) Add style')
Expand Down

0 comments on commit b835c9f

Please sign in to comment.