Fix for Issue #13

Swapped + operator for np.concatenate to ensure that the resulting array is 2 by X.
This ensures that we are able to draw the point in the array.
This commit is contained in:
David 2018-08-19 17:41:57 -04:00
parent 61e05f7fdf
commit b877367260

View file

@ -192,7 +192,7 @@ def draw_landmarks (image, image_landmarks, color):
cv2.polylines(image, tuple(np.array([v]) for v in (right_eye, left_eye, mouth)),
True, color, lineType=cv2.LINE_AA)
# the rest of the cicles
for x, y in right_eyebrow+left_eyebrow+mouth+right_eye+left_eye+nose:
for x, y in np.concatenate((right_eyebrow, left_eyebrow, mouth, right_eye, left_eye, nose), axis=0):
cv2.circle(image, (x, y), 1, color, 1, lineType=cv2.LINE_AA)
# jaw big circles
for x, y in jaw: