batch extract faces on single image special case

This commit is contained in:
galthran-wq 2025-02-18 10:40:57 +00:00
parent 3e34675aab
commit 2eb5cac37b

View File

@ -207,6 +207,16 @@ def test_batch_extract_faces_with_nparray(detector_backend):
)
def test_batch_extract_faces_single_image():
img_path = "dataset/couple.jpg"
imgs_objs_batch = DeepFace.extract_faces(
img_path=[img_path],
align=True,
)
assert len(imgs_objs_batch) == 2
assert [isinstance(obj, dict) for obj in imgs_objs_batch]
def test_backends_for_enforced_detection_with_non_facial_inputs():
black_img = np.zeros([224, 224, 3])
for detector in detectors: