Update face_analysis.py

I believe that the `metric` is an important param that people want to control.
This commit is contained in:
ease_zh
2024-11-01 10:01:53 +08:00
committed by GitHub
parent a1eb8523fb
commit 00595a7c58

View File

@@ -55,10 +55,10 @@ class FaceAnalysis:
else:
model.prepare(ctx_id)
def get(self, img, max_num=0):
def get(self, img, max_num=0, metric='default'):
bboxes, kpss = self.det_model.detect(img,
max_num=max_num,
metric='default')
metric=metric)
if bboxes.shape[0] == 0:
return []
ret = []