Open mbeytekin opened 1 year ago
I made some changes in simswap.py and got better results: soft_facemask, = self.smooth_mask(face_mask) img_white=soft_face_mask*255.
swapped_img = swapped_img * soft_face_mask
However, in some cases, overlaps can occur.
Hey @mbeytekin , you can blend faces separately. At the end of the simswap.py file do not sum img_mask and target_image, instead blend each crop independently.
I think a better solution would be computing intersection between crops and compensating it during the blend step. I'll take a look later.
Fixed the issue with the latest update
before
After
I guess to fix this I have to merge all the found faces separately. Can you help with this?
By the way, the app already finds softmasks of faces. After all, isn't it better to use them when merging faces into the picture?