fix: raise detection confidence threshold to 0.7, move model cache to project dir

This commit is contained in:
fiatcode 2026-02-27 21:50:37 +07:00
parent adf949b805
commit 9fc5bfc2c4
3 changed files with 29 additions and 3 deletions

View file

@ -26,8 +26,8 @@ class FaceData:
class FaceDetector:
"""Face detector using RetinaFace + ArcFace via UniFace."""
def __init__(self):
self.detector = RetinaFace()
def __init__(self, confidence_threshold: float = 0.7):
self.detector = RetinaFace(confidence_threshold=confidence_threshold)
self.recognizer = ArcFace()
def detect_faces(self, frame_path: Path, frame_index: int) -> List[FaceData]: