Open lxd941213 opened 8 months ago
face detector sometime fails to detect face
face detector sometime fails to detect face
I see that your IP-Adapter-portrait is also a cropped face, so there should be a high probability that the ID embedding will not be detected?
face detector sometime fails to detect face
I see that your IP-Adapter-portrait is also a cropped face, so there should be a high probability that the ID embedding will not be detected?
I firstly get id embedding befrore crop face ( you can also pad the cropped face image to increase the probability)
face detector sometime fails to detect face
I see that your IP-Adapter-portrait is also a cropped face, so there should be a high probability that the ID embedding will not be detected?
I firstly get id embedding befrore crop face ( you can also pad the cropped face image to increase the probability)
Thank you very much for your quick reply!
import cv2
import numpy as np import insightface from insightface.app import FaceAnalysis from insightface.data import get_image as ins_get_image from insightface.utils import face_align
app = FaceAnalysis(providers=['CUDAExecutionProvider', 'CPUExecutionProvider']) app.prepare(ctx_id=0, det_size=(640, 640)) img = cv2.imread("person.png")
faces = app.get(img) norm_face = face_align.norm_crop(img, landmark=faces[0].kps, image_size=224)
When I use the above code to crop the face, and then use the insightface module, the faceid cannot be extracted. Have you ever encountered this problem? Hope to get your reply, thank you!