diff --git a/facelib/MTCExtractor.py b/facelib/MTCExtractor.py index 4381af0..c524ab9 100644 --- a/facelib/MTCExtractor.py +++ b/facelib/MTCExtractor.py @@ -291,7 +291,7 @@ def nms(boxes, threshold, method): w = np.maximum(0.0, xx2-xx1+1) h = np.maximum(0.0, yy2-yy1+1) inter = w * h - if method is 'Min': + if method == 'Min': o = inter / np.minimum(area[i], area[idx]) else: o = inter / (area[i] + area[idx] - inter)