This article was originally published by AI Frontier.
Deepfakes is open source


Planning Editor | Tina


By MMA GREY ELLIS


Compile | Debra, Vincent


Edit | Emily

“The Internet has a tendency to produce some bad byproducts, such as the fake news that put Facebook in the spotlight and, more recently, fake porn videos. Machine learning AI technology has been used to swap stars’ faces with those of porn video performers to almost unconvincing effect, Actors like Daisy Ridley, Gal Gadot, Scarlett Johansson, and Taylor Swift were among the early victims of the technology. Now, someone has made an app, and it’s open source on GitHub. This significantly lowers the bar for the technology and will undoubtedly allow these fake videos to spread more widely. However, when images of ordinary people’s faces are used in fake pornographic videos, the law does not come to the victim’s aid. Why?”


GitHub deepfakes

If you remember, wonder Woman Gal Gadot’s face was plastered on the face of a romantic action movie star, which caused quite a stir on the Internet. Deepfake was originally developed as a tool to identify and exchange images of people’s faces in photos and videos (inspired by deepfakes, the uber-popular indescribable community on Reddit). But there are such restless people who insist on using a technology that should be put to good use in some field of interest. ╮(╯▽╰)╭ Taking pictures, watching pictures, it’s really hard for them.

While there were some apps that could make videos like this before, now programmers can study the code at home, do it themselves, and have a more “perfect” experience. So how do you do that? Here’s a hands-on guide:

An overview of

The project has multiple entries and you need to do the following:

  • Collect photos (or use the photos provided in the training data below)
  • Extracting facial images from the original photo
  • Train the model on the photo (or use the model provided in the training data below)
  • Transform the source code using the model

extract

Run python Faceswap.py extract in your folder. This step will place the image from the SRC file into the extract folder.

training

Run the Python Faceswap.py training in your installation file. This step trains the model to save the two groups of photos into the model folder.

conversion

Run the Python Faceswap.py transformation in your file. This step will apply the photos from the original folder to the modified folder.

General notes:

All of the scripts mentioned come with the -h / – help option, as well as a library to receive. You’re smart enough to figure out how it works, aren’t you? Note: The video has not yet been converted. You can use MJPG to convert video to photos, process images, and convert images back to video.

Training data

Here is the whole package, including training images and trained models (~ 300MB) :

Anonfile.com/p7w3m0d5be/…


How do I create and run this program

create

Fork the library, set up your own environment, and then start with Dockerfile. Or you can manually set dependencies in Dockerfiles. To view

../blob/master/INSTALL.md 和../blob/master/USAGE.md

Learn how to configure VirtualEnv and basic information about running it.

For best performance, you also need a modern GPU with CUDA support.

Note:

  • Reusing existing models is much faster than training from scratch.
  • If you don’t have enough training data, start with images of similar-looking people and then switch data.

Docker

If you prefer to use Docker, you can start the program using the following methods:

Create: docker build-t deepfakes

Run:

Docker run –rm –name deepfakes -v [src_folder] : / SRV it deepfakes bash. bash

You can use the command line instead. Note that Dockerfile does not satisfy all requirements, so it may cause some Python 3 commands to fail. Also note that it has no GUI output, so it is possible that train.py will fail to display the image. You can comment this out or save it as a file.


How to Contribute

People interested in generating models

Welcome to “Faceswap-Model” to discuss/suggest/submit alternatives to the current algorithm.

developers

  • Read this README in full
  • The fork library
  • Download the data from the link below
  • Have some fun
  • Look up the topic with the ‘dev’ tag
  • For developers more interested in computer vision and openCV, please go to the topic labeled “openCV”. And feel free to add your own alternatives/improvements

Non-development power users

  • Read this README in full
  • The fork library
  • Download the data from the link below
  • Give it a try
  • View the topic with the ‘advUser’ tag
  • Step over to ‘Facewap-Playground’ and see if you can help others

The end user

  • Come here to get the code, play it yourself
  • You can also go to facewap-Playground and help others or get help from others.
  • Be patient. This is also a relatively new technology for developers.
  • Note that all issues related to running code must be exposed in the “Faceswap-Playground” project!

opponents

  • Sorry, I don’t have time for you


About github.com/deepfakes

What kind of database is this?

This is an open database for active users.

Why this library?

The Joshua-Wu library doesn’t seem to be very active. Problems like the lack of http:// in front of web addresses have not been solved yet.

Why is it called “deepfakes” and not /u/deepfakes?

  • As the number of projects increases, this problem will arise sooner or later.
  • Because all the glory will go to/U/Deepfakes
  • Because it brings the contributors and users together


About Machine Learning

How does a computer recognize/shape a face? How does machine learning work? What is a neural network?

The answer to this question is complicated. The following video can help you better understand machine learning:


Law can’t Help Fake video victims?

One might ask, is it possible to use someone else’s image to make this kind of video and image without being sued? In fact, however, the law may not be able to stop it. Why is that?

According to Mary Anne Franks, a professor at the University of Miami School of Law, her previous work promoting sexual profiling may not help victims of AI porn videos. Mr Franks is responsible for most of America’s existing laws criminalising non-consensual pornography.

It’s not that Franks and lawmakers failed to consider the unconscionable aspects of manipulating other people’s images, but that the premise of all current legislation is that nonconsensual pornography violates the privacy of the victim. But the exchange of facial images using AI does not constitute an invasion of privacy because, unlike, say, nude photos, the video material itself is fake. You can’t Sue someone for exposing something that’s not in your life.

Moreover, the creators of these videos are cunning, and they use some processing techniques to evade the law.

Does that make it seem like the law can’t help the victims, and there’s no solution? The answer is no. For example, celebrities can illegally use the right to obtain commercial interests of the way to file a lawsuit. But for ordinary people, it’s better to pass the defamation law. When Franks realized that laws punishing pornography did not include provisions about false images, she suggested that lawmakers amend defamation laws to address the problem, but so far they have not made much headway.

In the long term, the most feasible way to solve this problem is to start with the technology breakthrough: applications. America’s Federal Trade Commission Act prohibits “improper or deceptive conduct in, or affecting, the conduct of commerce”. “If we can do something about it, app developers have to take some responsibility. This application is converting someone’s data to someone else’s data. “(Google violated the same rule in 2013.)

Companies can also contribute. Google, for example, has said it will separate unwanted porn search results from victims’ names.

Similarly, online platforms could step up their efforts to crack down, at least by labeling fake videos as fake. In addition, “using AI to detect these edited porn videos is trivial,” says Jen Golbeck, a computer scientist at the University of Maryland.

Thus, verifying the authenticity (or lack thereof) of video will only become more important as the technology becomes more widely available.


response

The post has also sparked a lively discussion on Reddit, with many focusing on the ethical and legal issues raised by the technology, while others believe in the potential value behind it and hope it won’t be affected by negative publicity. Here is a selection of comments from netizens, which can roughly reflect two opposing views:

Netizen 1: The erotic door is just a superficial problem. This groundbreaking technology is on the verge of a breakthrough, and it’s going to happen much faster than we think. Think about the possibilities and the results. Thank you.

In the future, one person will be able to act in a play, the stars will not act, they will have Joe Schmoe do it, and they will put the stars face on it.

Netizen 2: What do you think will be the breakthrough?

Reply 1: Just as fake news can spread fake recordings, imagine fake videos of Hillary joking about taking bribes from investment banks, or Putin admitting he stole her emails. That’s hard to prove.

Reply 2: Yes, the face-swapping algorithm is really interesting and I think people will develop more technology to track this kind of information in the future, just like the original image conversion technology.

Netizen 3: In the next few years, all video and audio material in court will be discredited. In people’s minds, at least, there will always be doubts about what really happened.

The net friend 4; I think this is a good example of how AI will affect our lives in the future. Perhaps the role of AI in the future will not be a terminator-like robot, but rather a technological breakthrough that will have a profound impact on human morality and social structure.

Netizen 5: I see many of you are concerned about the moral and legal implications. Am I the only one who thinks it’s cool? The technology is awesome, the seamless modification technology is perfect, and that’s all that matters, right?

Original link:

  1. Github.com/deepfakes/f…
  2. www.reddit.com/r/artificia…
  3. www.wired.com/story/face-…

For more content, you can follow AI Front, ID: AI-front, reply “AI”, “TF”, “big Data” to get AI Front series PDF mini-book and skill Map.