Skip to content

Commit

Permalink
fixing bug crashing eval on widerface (opencv#267)
Browse files Browse the repository at this point in the history
Co-authored-by: Tony Wang <[email protected]>
  • Loading branch information
TonyCongqianWang and Tony Wang authored Jul 18, 2024
1 parent f88e9b2 commit 912904c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion models/face_detection_yunet/yunet.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,4 +52,4 @@ def setInputSize(self, input_size):
def infer(self, image):
# Forward
faces = self._model.detect(image)
return np.array([]) if faces[1] is None else faces[1]
return np.empty(shape=(0, 5)) if faces[1] is None else faces[1]

0 comments on commit 912904c

Please sign in to comment.