wuhuikai / FaceSwap

Swap face between two photos.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

IndexError: index 185 is out of bounds for axis 0 with size 185

IpsumDominum opened this issue · comments

Happens when detected face is out of bounds of the image.
Also, error in main_video.py line 55:

if not os.path.isdir(dir_path):
        os.makedirs(dir_path)

Will output error if dir_path is ""

Edit:

if dir_path != "" and not os.path.isdir(dir_path):
        os.makedirs(dir_path)
  1. "detected face is out of bounds of the image" is a known issue, but I do not have time to fix this currently.
  2. use "./" instead.