faceswap-GAN icon indicating copy to clipboard operation
faceswap-GAN copied to clipboard

Scriptified version of v2.1.

Open slundell opened this issue 6 years ago • 4 comments

Includes schedule copied from v2. Persitant progress and automatically restarts from last checkpoint. Uses prefetch_generator to increase GPU utilization. Previews are saved as png files. Losses are plotted using matplotlib. After 40000 iterations videos are automatically converted. This script requires a specific folder structure:

from-person/extracted-faces (folder with extracted faces of "face-donor")

to-person/extracted-faces (folder with extracted faces of "body-donor") to-person/to-swap/ (video files to be converted)

These folders will automatically be created: to-person/models (weights files, progress file, loss plot) to-person/models/preview/ (images of conversions) to-person/swapped/ (converted videos with new face)

Invoke like this:

python3 make-fake.py --source-dir ../data/cage --target-dir ../data/trump

There is a lot of cleanup to be done in this script, but it should be functional as-is.

slundell avatar Mar 26 '18 13:03 slundell

Hi, could you please scriptify the newest build with LSGAN and maybe the 128 notebook? thanks!! tjess

tjess78 avatar May 05 '18 14:05 tjess78

Really appreciate slundell spending time making this PR, and sorry for postponing it for so long despite I'm the person asking for help.

I got some feedback making me feel that I should remain this project less accessible for people without much coding experience. Obviously deepfakes is still a controversial topic, and I would like to keep this project from being closely associated with it. (Edit: I was trying to refer to the concept of deepfakes, but I chose the wrong wording that seems offensive to the deepfakes community.)

As for now, I prefer to make this project deep-learning-oriented (as well as messy and loosely structured) instead of being a hands-on face-swapping tool.

shaoanlu avatar Jun 12 '18 08:06 shaoanlu

@shaoanlu Get off your high horse. You even show your work using some women's videos.

Jack29913 avatar Jun 12 '18 14:06 Jack29913

People always will use the tools for good and bad, it's doesn't matter what kind of tool it is. So please keep improving your code, at the end you are a developer aiming for the best!

ghost avatar Jun 12 '18 14:06 ghost