Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -47,7 +47,7 @@ def predict(im1, im2):
|
|
47 |
bottom_x2 = int(face_landmarks.landmark[454].x * img2_w)
|
48 |
bottom_y2 = int(face_landmarks.landmark[152].y * img2_h)
|
49 |
|
50 |
-
face2 = im2[
|
51 |
cv2.rectangle(im2, (top_x2, top_y2), (bottom_x2, bottom_y2), (0, 255, 0), 2)
|
52 |
|
53 |
# Convert the tensor back to a PIL Image
|
|
|
47 |
bottom_x2 = int(face_landmarks.landmark[454].x * img2_w)
|
48 |
bottom_y2 = int(face_landmarks.landmark[152].y * img2_h)
|
49 |
|
50 |
+
face2 = im2[top_y2:bottom_y2, top_x2:bottom_x2]
|
51 |
cv2.rectangle(im2, (top_x2, top_y2), (bottom_x2, bottom_y2), (0, 255, 0), 2)
|
52 |
|
53 |
# Convert the tensor back to a PIL Image
|