Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -54,7 +54,7 @@ def identify_face(user_image):
|
|
54 |
face_locations = face_recognition.face_locations(img)
|
55 |
for face_location in face_locations:
|
56 |
top, right, bottom, left = face_location
|
57 |
-
mask = np.zeros(
|
58 |
print(mask.shape)
|
59 |
cv2.rectangle(mask, (left, top), (right, bottom), 255, -1)
|
60 |
inverted_image = cv2.bitwise_not(mask)
|
|
|
54 |
face_locations = face_recognition.face_locations(img)
|
55 |
for face_location in face_locations:
|
56 |
top, right, bottom, left = face_location
|
57 |
+
mask = np.zeros(img.shape[:2], dtype="uint8")
|
58 |
print(mask.shape)
|
59 |
cv2.rectangle(mask, (left, top), (right, bottom), 255, -1)
|
60 |
inverted_image = cv2.bitwise_not(mask)
|