Skip to content
This repository has been archived by the owner on Nov 9, 2023. It is now read-only.

Converting does not swap the (detected) faces. #32

Closed
petergerten opened this issue Oct 7, 2018 · 1 comment
Closed

Converting does not swap the (detected) faces. #32

petergerten opened this issue Oct 7, 2018 · 1 comment

Comments

@petergerten
Copy link

petergerten commented Oct 7, 2018

Expected behavior

Converting frames with a pretrained model should results in output frames with faces swapped (or at least modified depending on the quality of the trained network) for all frames where a face was detected.

Actual behavior

I have a pretrained H128 model. I have some new images from a video and extract them first. Around half of the frames have a face detected, which is ok. When trying to convert the frames, the output frames do not have the face swapped. The face region in the output frame looks completely untouched.

Steps to reproduce

  1. Pretrained H128 model available.
  2. I downloaded a youtube video:
    youtube-dl https://www.youtube.com/watch?v=g8nkbusv5sY
  3. Extract frames:
    ffmpeg -i input.mkv frame_%06d.jpg
  4. Align
    python main.py extract --input-dir /mnt/in --output-dir /mnt/in/aligned --detector mt
  5. Convert:
    python main.py convert --model-dir models --model H128 --input-dir /mnt/in --output-dir /mnt/out --mode seamless --aligned-dir /mnt/in/aligned

Other relevant information

System: Ubuntu 16.04, requirements installed as described in Linux.md

@petergerten
Copy link
Author

Ok, the issue was that the model actually did not exist in the specified directory.
The reason why I did not notice it is that the converter says 'Loading model...' without any error message.
@iperov maybe you can add a check if the model actually exists?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant