Faking The News Deep Fake Lab

Faking the News

19 Sep 2018

In last weeks class we did a quick tutorial on deepfakes. Deepfakes is a portmanteau of deep learning and fakes. It is a technique which is used to superimpose images and videos. It was originally developed to make realistic celebrity pornographic videos. To create our deepfakes we use some CLI tools to aid in our process.

Tools used:

Steps to produce training data:

  1. Download video. Youtube-dl is a handy cli tool to download from youtube
  2. Extract frames from video using ffmpeg ffmpeg -i clipname -vf fps=framerate -qscale:v 2 "imagename%04d.jpg"
  3. Crop faces from frames. Use autocrop for expediency autocrop -i pics -o crop -w 400 -H 400 --facePercent 50
  4. Clean up undetected faces and bad matches

Pro tip: make sure you are referencing the correct directory paths

Tutorial on making deepfakes