DSFD-Pytorch-Inference icon indicating copy to clipboard operation
DSFD-Pytorch-Inference copied to clipboard

RuntimeWarning: overflow encountered in scalar multiply

Open cszygmtxst opened this issue 1 year ago • 1 comments

img shape (1800, 2880, 3) n_anchors += x[0] * x[1] * len(min_sizes[0]) Traceback (most recent call last): File "test.py", line 29, in face_detect boxes = detector.detect(img) File "/lib/python3.8/site-packages/face_detection/base.py", line 56, in detect boxes = self.batched_detect(image, shrink) File "/lib/python3.8/site-packages/torch/utils/_contextlib.py", line 115, in decorate_context return func(*args, **kwargs) File "/lib/python3.8/site-packages/face_detection/base.py", line 146, in batched_detect boxes = self._batched_detect(image) File "/lib/python3.8/site-packages/face_detection/base.py", line 126, in _batched_detect boxes = self._detect(image) File "/lib/python3.8/site-packages/torch/utils/_contextlib.py", line 115, in decorate_context return func(*args, **kwargs) File "/lib/python3.8/site-packages/face_detection/retinaface/detect.py", line 120, in _detect priors = priorbox.forward() File "/lib/python3.8/site-packages/face_detection/retinaface/prior_box.py", line 43, in forward anchors = generate_prior_box( File "/lib/python3.8/site-packages/face_detection/retinaface/prior_box.py", line 26, in generate_prior_box anchors[idx_anchor:idx_anchor+4] = [cx, cy, s_kx, s_ky] ValueError: could not broadcast input array from shape (4,) into shape (0,)

cszygmtxst avatar Apr 11 '23 13:04 cszygmtxst

Could you give a bit more information to reproduce this? E.g. your python/pytorch/numpy versions and operating system. Also, please provide the exact script you ran to reproduce this.

hukkelas avatar Apr 21 '23 10:04 hukkelas