Problem with test_wholeimage_swapsingle #103

Open
opened 2021-08-29 00:13:42 +02:00 by manigalati · 0 comments
manigalati commented 2021-08-29 00:13:42 +02:00 (Migrated from github.com)

Hello :)

I am running into the following problem when trying to swap faces with test_wholeimage_swapsingle.py:

Traceback (most recent call last):
File "test_wholeimage_swapsingle.py", line 48, in
img_a_align_crop, _ = app.get(img_a_whole,crop_size)
File "/content/ARPEGGIO_1ST/SimSwap/insightface_func/face_detect_crop_single.py", line 58, in get
metric='default')
File "/usr/local/lib/python3.7/dist-packages/insightface/model_zoo/scrfd.py", line 217, in detect
scores_list, bboxes_list, kpss_list = self.forward(det_img, threshold)
File "/usr/local/lib/python3.7/dist-packages/insightface/model_zoo/scrfd.py", line 187, in forward
bboxes = distance2bbox(anchor_centers, bbox_preds)
File "/usr/local/lib/python3.7/dist-packages/insightface/model_zoo/scrfd.py", line 38, in distance2bbox
x1 = points[:, 0] - distance[:, 0]
ValueError: operands could not be broadcast together with shapes (2738,) (2888,)

I am wondering how to solve it, I am trying to change image sizes + the threshold and the dimension for face detection but without any success.

Thanks in advance,
Francesco

Hello :) I am running into the following problem when trying to swap faces with test_wholeimage_swapsingle.py: Traceback (most recent call last): File "test_wholeimage_swapsingle.py", line 48, in <module> img_a_align_crop, _ = app.get(img_a_whole,crop_size) File "/content/ARPEGGIO_1ST/SimSwap/insightface_func/face_detect_crop_single.py", line 58, in get metric='default') File "/usr/local/lib/python3.7/dist-packages/insightface/model_zoo/scrfd.py", line 217, in detect scores_list, bboxes_list, kpss_list = self.forward(det_img, threshold) File "/usr/local/lib/python3.7/dist-packages/insightface/model_zoo/scrfd.py", line 187, in forward bboxes = distance2bbox(anchor_centers, bbox_preds) File "/usr/local/lib/python3.7/dist-packages/insightface/model_zoo/scrfd.py", line 38, in distance2bbox x1 = points[:, 0] - distance[:, 0] ValueError: operands could not be broadcast together with shapes (2738,) (2888,) I am wondering how to solve it, I am trying to change image sizes + the threshold and the dimension for face detection but without any success. Thanks in advance, Francesco
Sign in to join this conversation.