SimSwap
SimSwap copied to clipboard
TypeError: 'NoneType' object is not iterable
i keep getting the above error. Of the 26 faces i've used, only one successfully returns a swap. All else gives this error. Any help is appreciated. i'm VERY new to this. Full error code:
set det-size: (640, 640)
Traceback (most recent call last):
File "test_wholeimage_swapsingle.py", line 62, in
Hello, you can find your solution here: https://github.com/neuralchen/SimSwap/issues/39#issuecomment-873758730
You should reduce the face detection threshold in test_wholeimage_swapsingle.py
for the following code:
app = Face_detect_crop(name='antelope', root='./insightface_func/models')
app.prepare(ctx_id= 0, det_thresh=0.6, det_size=(640,640))
Hello, you can find your solution here: #39 (comment)
You should reduce the face detection threshold in
test_wholeimage_swapsingle.py
for the following code:app = Face_detect_crop(name='antelope', root='./insightface_func/models') app.prepare(ctx_id= 0, det_thresh=0.6, det_size=(640,640))
This is correct !! A detection threshold of 0.2 works well for me, even for side faces. Insight Face library (that the authors use for face detection) looks crappy though, as some very clear faces are detected with quite low probability - Or their models suffer from adversarial problems !!