retuning regions as numpy int 32 was causing error in api

This commit is contained in:
Sefik Ilkin Serengil 2024-02-04 10:36:00 +00:00
parent 45e991f9f3
commit 08131731c5

View File

@ -167,10 +167,10 @@ def extract_faces(
{
"face": img_pixels[:, :, ::-1] if human_readable is True else img_pixels,
"facial_area": {
"x": current_region.x,
"y": current_region.y,
"w": current_region.w,
"h": current_region.h,
"x": int(current_region.x),
"y": int(current_region.y),
"w": int(current_region.w),
"h": int(current_region.h),
},
"confidence": confidence,
}