Sign In Start Free Trial
Account

Add to playlist

Create a Playlist

Modal Close icon
You need to login to use this feature.
  • Book Overview & Buying Exploring Deepfakes
  • Table Of Contents Toc
  • Feedback & Rating feedback
Exploring Deepfakes

Exploring Deepfakes

By : Bryan Lyon, Matt Tora
4.5 (6)
close
close
Exploring Deepfakes

Exploring Deepfakes

4.5 (6)
By: Bryan Lyon, Matt Tora

Overview of this book

Applying Deepfakes will allow you to tackle a wide range of scenarios creatively. Learning from experienced authors will help you to intuitively understand what is going on inside the model. You’ll learn what deepfakes are and what makes them different from other machine learning techniques, and understand the entire process from beginning to end, from finding faces to preparing them, training the model, and performing the final swap. We’ll discuss various uses for face replacement before we begin building our own pipeline. Spending some extra time thinking about how you collect your input data can make a huge difference to the quality of the final video. We look at the importance of this data and guide you with simple concepts to understand what your data needs to really be successful. No discussion of deepfakes can avoid discussing the controversial, unethical uses for which the technology initially became known. We’ll go over some potential issues, and talk about the value that deepfakes can bring to a variety of educational and artistic use cases, from video game avatars to filmmaking. By the end of the book, you’ll understand what deepfakes are, how they work at a fundamental level, and how to apply those techniques to your own needs.
Table of Contents (15 chapters)
close
close
1
Part 1: Understanding Deepfakes
6
Part 2: Getting Hands-On with the Deepfake Process
10
Part 3: Where to Now?

To get the most out of this book

This book is designed to build knowledge as you read through the chapters. If you’re starting with no background knowledge of deepfakes, then we suggest you start at the beginning. If you want to skip straight to the code, then you’ll want to look at Part 2 (though we hope you’ll give Part 1 a peruse once you’re ready). If you only care about what you can do with the techniques moving forward, then check out Part 3 (but I promise that the earlier parts have some juicy nuggets of information).

We use Python for all code examples in this book. If you know Python, you should be able to understand all the code samples with the help of the text. If you don’t know Python, then don’t worry! There is a lot of non-code explanation, and even the code includes hands-on explanations of what is going on in it.

All the libraries used in this book are explained when they’re used, but this book should not be considered a guide or in-depth explanation of any of the libraries. Many of these libraries have books of their own dedicated to them, and their use in this book is solely functional.

Software covered in the book

Operating system requirements

Python

Faceswap

Windows, macOS, or Linux

PyTorch

OpenCV

Pillow (PIL Fork)

We use Anaconda (https://www.anaconda.com/) for package management and sandboxing throughout this book. If you want to follow along, we highly recommend you install it from the site listed here. If you would rather use Python virtual environments, you may, but if you do, the instructions in this book will not always work without modification, especially installing the necessary packages. If you choose to use that route, you will have to find the correct version of libraries to install yourself.

If you are using the digital version of this book, we advise you access the code from the book’s GitHub repository (a link is available in the next section). Doing so will help you avoid any potential errors related to the copying and pasting of code.

Included in each hands-on chapter is a list of exercises. Please don’t take these as directions on what you must do, but consider them as helpers to more completely understand what it is that the code is doing and how you can use the techniques for yourself. They do not have “answers” as they are not really questions; they’re just prompts for you to find new and exciting ways to apply your knowledge.

If you do complete any of the exercises (or come up with something impressive of your own), we’d appreciate it if you would “fork” the book’s repo into your own GitHub account and show the world your accomplishment! We’d love to see what you can do with deepfakes.

Unlock full access

Continue reading for free

A Packt free trial gives you instant online access to our library of over 7000 practical eBooks and videos, constantly updated with the latest in tech

Create a Note

Modal Close icon
You need to login to use this feature.
notes
bookmark search playlist download font-size

Change the font size

margin-width

Change margin width

day-mode

Change background colour

Close icon Search
Country selected

Close icon Your notes and bookmarks

Delete Bookmark

Modal Close icon
Are you sure you want to delete it?
Cancel
Yes, Delete

Delete Note

Modal Close icon
Are you sure you want to delete it?
Cancel
Yes, Delete

Edit Note

Modal Close icon
Write a note (max 255 characters)
Cancel
Update Note

Confirmation

Modal Close icon
claim successful

Buy this book with your credits?

Modal Close icon
Are you sure you want to buy this book with one of your credits?
Close
YES, BUY