<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Mehmet Emin Masca on Medium]]></title>
        <description><![CDATA[Stories by Mehmet Emin Masca on Medium]]></description>
        <link>https://medium.com/@eminmasca?source=rss-daacecdaab2c------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*m4edHrdSRVS1kXNtsWY9gQ.jpeg</url>
            <title>Stories by Mehmet Emin Masca on Medium</title>
            <link>https://medium.com/@eminmasca?source=rss-daacecdaab2c------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Wed, 18 Nov 2026 23:00:51 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@eminmasca/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Advantages and Disadvantages of Deepfake Technology]]></title>
            <link>https://medium.com/geekculture/advantages-and-disadvantages-of-deepfake-technology-ccfa7c12b1ae?source=rss-daacecdaab2c------2</link>
            <guid isPermaLink="false">https://medium.com/p/ccfa7c12b1ae</guid>
            <category><![CDATA[artificial-intelligence]]></category>
            <category><![CDATA[scam]]></category>
            <category><![CDATA[machine-learning]]></category>
            <category><![CDATA[movies]]></category>
            <category><![CDATA[deepfakes]]></category>
            <dc:creator><![CDATA[Mehmet Emin Masca]]></dc:creator>
            <pubDate>Fri, 03 Dec 2021 15:02:03 GMT</pubDate>
            <atom:updated>2021-12-03T15:02:03.318Z</atom:updated>
            <content:encoded><![CDATA[<p>We live in a world where we can create visuals and sounds that is not real. Does this synthetic reality lead us to a better world — or a worse one?</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*xPOkYxtiB8YSQe-r.jpg" /></figure><p>We call this synthetic video processing Deepfake. So, what is this Deepfake thing exactly?</p><p>Business Insider says:</p><blockquote>“The term “deepfake” comes from the underlying technology “deep learning,” which is a form of AI. Deep learning algorithms, which teach themselves how to solve problems when given large sets of data, are used to swap faces in video and digital content to make realistic-looking fake media.”</blockquote><blockquote><a href="https://www.businessinsider.com/what-is-deepfake"><em>https://www.businessinsider.com/what-is-deepfake</em></a></blockquote><p>Yes<em>, </em>we have come this far in technology, and by every day, we become better and better.</p><p>Of course, there are advantages and disadvantages of deepfake technology. In this article, we are going to discuss these.</p><h3><strong>ADVANTAGES OF DEEPFAKES</strong></h3><ul><li><strong>Bringing Back the Loved Ones!</strong></li></ul><p>Deepfakes have a lot of potential usages in the movie industry.</p><p>You can bring back a decedent actor or actress. It can be debated from an ethical perspective, but it is possible and super easy if we do not think about ethics! And also, probably way cheaper than other options.</p><p>Do you remember when they brought Paul Walker back in Fast and Furious 7? They have used CGI and VFX and spent countless hours to bring him back, but the Deepfake method is easier and cheaper!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*H7TVRp9pveO09ywJ.jpg" /><figcaption>Paul Walker VFX — H 2015</figcaption></figure><p>The only problem is that the movie came to the theaters in 2015, but the Deepfake trend started in 2017.</p><ul><li><strong>More Realistic Scenes in Movies</strong></li></ul><p>I don’t know if you have seen Joss Whedon’s Justice League (2017).</p><p>Actor Henry Cavill brought Man of Steel to life In Justice League movie with incredible acting talents, but there was a problem.</p><p>He was also attending the shoots of Mission Impossible: Fallout at the same time. His character in MI:6 had a mustache. But Superman doesn’t have a mustache, as you know! The studio didn’t let him shave his mustache.</p><p>Shootings were at the same time. So, they decided to remove his mustache with CGI. And this way, he could play both roles without any problem. It’s a Win-Win situation, right? No. It was a disaster. The CGI was terrible and weird-looking. It shook the Internet and became a figure of fun.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/332/1*v6S3ppmr8vO-OGLl6l858Q.png" /></figure><p>Then a guy on YouTube managed to get rid of from mustache by using Deepfakes. Here you can see the results.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/605/1*uSZqPXLxgNQGR4P5gXGpuA.png" /><figcaption><a href="https://www.youtube.com/watch?v=2PZ3W1W20bk&amp;t=27s&amp;ab_channel=DeepFakesClub">https://www.youtube.com/watch?v=2PZ3W1W20bk&amp;t=27s&amp;ab_channel=DeepFakesClub</a></figcaption></figure><p>See? It’s super easy, and you don’t have to spend millions.</p><ul><li><strong>Chance of Getting Education from Its Masters</strong></li></ul><p>Just imagine a world where you can get physics classes from Albert Einstein anytime, anywhere! Deepfake makes impossible things possible. Learning topics from its masters is a way motivational tool. You can increase the efficiency, but it still has a very long way to go.</p><h3><strong>DISADVANTAGES OF DEEPFAKES</strong></h3><ul><li><strong>Scamming</strong></li></ul><p>Unfortunately, there are lots of ways of scamming with this powerful technology. We have seen some examples recently.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*wkizCGs_nnFRoW458uq17A.png" /><figcaption><a href="https://slate.com/technology/2021/09/deepfake-video-scams.html">https://slate.com/technology/2021/09/deepfake-video-scams.html</a></figcaption></figure><p>Everything comes with a price. Sometimes this price can be high enough, like $243,000.</p><p>This technology paves the way for scams like these.</p><p>We must question everything in this brand-new digital era. Can you believe what you see? Can you believe what you hear? It’s hard to find an answer these days. This situation leads us developing new algorithms that detects fakery.</p><p>There was a Deepfake Detection Algorithm Competition in Kaggle 2 years ago, and the prize money was $1,000,000. Maybe a brighter future is possible.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/328/1*ykSLHQoBIxjzVM5HXj8-7g.png" /><figcaption><a href="https://www.forbes.com/sites/jessedamiani/2019/09/03/a-voice-deepfake-was-used-to-scam-a-ceo-out-of-243000/?sh=6e186e312241">https://www.forbes.com/sites/jessedamiani/2019/09/03/a-voice-deepfake-was-used-to-scam-a-ceo-out-of-243000/?sh=6e186e312241</a></figcaption></figure><ul><li><strong>Spreading Misleading News via Politicians</strong></li></ul><p>It is hard to spot fake things these days.</p><p>We are so open to believing what we see or hear in media. And if you see a public figure talking about a topic, you usually would not think if the person is “real” or “fake?”. However, when Deepfake exists, you must. Somebody with bad intentions can easily manipulate the news. This can lead to wars, chaos, and even hunger.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/437/1*K1Wgodb1Zcc9IHeqLj7ang.png" /><figcaption><a href="https://chameleonassociates.com/why-you-should-know-about-deepfake/">https://chameleonassociates.com/why-you-should-know-about-deepfake/</a></figcaption></figure><p>The usage area of the Deepfake totally depends on the person. Will you use it for good, or not?</p><ul><li><strong>Privacy Problems</strong></li></ul><p>We all have social media accounts. We all have Facebook, Instagram, and Twitter. All of us generate tons of data every day. We all share our photos from every angle, with different moods. This may lead to some privacy problems. A Deepfaker with bad intentions can easily access your photos, take them without permission and use them.</p><p>You would not want to see yourself in a fake video without your permission. But it is possible. We need a law enforcement. Privacy is the biggest problem of 21st century.</p><ul><li><strong>Generating Fake News</strong></li></ul><p>Have you heard Spider-Man: No Way Home?</p><p>Footage of actor Andrew Garfield on the set has leaked even though he was not confirmed to be in the movie. Fans were expecting him to be in the movie, but there was no official statement from Sony or Marvel’s side.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/605/1*WX2CiHdlP2nrjuplXCqJlw.png" /><figcaption><a href="https://www.youtube.com/watch?v=5PbqGAmUnVU&amp;t=1s">https://www.youtube.com/watch?v=5PbqGAmUnVU&amp;t=1s</a></figcaption></figure><p>The internet blew up after this leaked footage. Everybody was discussing if this video was real or not. Some people thought it was a Deepfake, but there wasn’t any clue about it. It was super accurate.</p><p>A YouTube channel named “Corridor Crew” analyzed the video and decided it was not a Deepfake. (Creator of the original footage says it was a Deepfake, but he probably has been warned by Disney and Sony.)</p><p>There is still much confusion, and we have to wait until the movie comes to the theaters.</p><h3><strong>CONCLUSION</strong></h3><p>People got used to hearing about Deepfakes. Most of the Internet people know what Deepfake is. We do not have to wait for years to reach and use new technologies like old times.</p><p>We are in the era of Artificial Intelligence. They can see, they can analyze, and they can fake it. There are good and bad sides of Deepfakes, but the usage area of technology depends on us. We must use it for the greater good. Also, some legal arrangements must be done.</p><p>Indeed, all these will take some time to reach a certain point. We will see what kind of world this technology leads us to.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=ccfa7c12b1ae" width="1" height="1" alt=""><hr><p><a href="https://medium.com/geekculture/advantages-and-disadvantages-of-deepfake-technology-ccfa7c12b1ae">Advantages and Disadvantages of Deepfake Technology</a> was originally published in <a href="https://medium.com/geekculture">Geek Culture</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Creating Deepfake Miracles With DeepFaceLab Tutorial (SAEHD Model)]]></title>
            <link>https://medium.com/geekculture/creating-deepfake-miracles-with-deepfacelab-tutorial-saehd-model-aa2aa12c08f3?source=rss-daacecdaab2c------2</link>
            <guid isPermaLink="false">https://medium.com/p/aa2aa12c08f3</guid>
            <category><![CDATA[deep-learning]]></category>
            <category><![CDATA[deepfakes]]></category>
            <category><![CDATA[ai]]></category>
            <category><![CDATA[machine-learning]]></category>
            <category><![CDATA[tutorial]]></category>
            <dc:creator><![CDATA[Mehmet Emin Masca]]></dc:creator>
            <pubDate>Mon, 23 Aug 2021 17:17:16 GMT</pubDate>
            <atom:updated>2021-08-24T12:45:03.900Z</atom:updated>
            <content:encoded><![CDATA[<p>Deepfake is one of the sexiest technologies of our age, no doubt. How about trying it by yourself?</p><h3>SO WHAT IS THIS DEEPFAKE THING?</h3><p><strong>Deepfakes</strong> (a <a href="https://en.wikipedia.org/wiki/Portmanteau">portmanteau</a> of “<a href="https://en.wikipedia.org/wiki/Deep_learning">deep learning</a>” and “fake”<a href="https://en.wikipedia.org/wiki/Deepfake#cite_note-FoxNews2018-1">[1]</a>) are <a href="https://en.wikipedia.org/wiki/Synthetic_media">synthetic media</a><a href="https://en.wikipedia.org/wiki/Deepfake#cite_note-2">[2]</a> in which a person in an existing image or video is replaced with someone else’s likeness. While the act of faking content is not new, deepfakes leverage powerful techniques from <a href="https://en.wikipedia.org/wiki/Machine_learning">machine learning</a> and <a href="https://en.wikipedia.org/wiki/Artificial_intelligence">artificial intelligence</a> to manipulate or generate visual and audio content with a high potential to deceive.<a href="https://en.wikipedia.org/wiki/Deepfake#cite_note-:17-3">[3]</a> The main machine learning methods used to create deepfakes are based on deep learning and involve training generative <a href="https://en.wikipedia.org/wiki/Artificial_neural_network">neural network</a> architectures, such as <a href="https://en.wikipedia.org/wiki/Autoencoder">autoencoders</a><a href="https://en.wikipedia.org/wiki/Deepfake#cite_note-:17-3">[3]</a> or <a href="https://en.wikipedia.org/wiki/Generative_adversarial_network">generative adversarial networks</a> (GANs).<a href="https://en.wikipedia.org/wiki/Deepfake#cite_note-Schwartz-4">[4]</a><a href="https://en.wikipedia.org/wiki/Deepfake#cite_note-:14-5">[5]</a>, says Wikipedia.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/479/1*0H4lFJ9aUpy4za1FgpoBfQ.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/479/1*IV_PDAGibGsruLrpY_NMZQ.jpeg" /><figcaption>Replacing the heads (Source: <a href="https://github.com/iperov/DeepFaceLab">https://github.com/iperov/DeepFaceLab</a>)</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/479/1*VP6lqHPkfx_Pzgf-vBMMbg.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/479/1*_kX63aX3rdMfUwZAT7AWqg.jpeg" /><figcaption>Another example (Source: <a href="https://github.com/iperov/DeepFaceLab">https://github.com/iperov/DeepFaceLab</a></figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/731/1*WyNAJ76Y6agjIPixQ1BK4g.jpeg" /><figcaption>And this is an example from Turkey. The actor passed away in 2000. It’s from a TV advertisement for Ziraat Bank in 2021. <a href="https://www.youtube.com/watch?v=fPiwmoxa0QE&amp;ab_channel=ZiraatBankas%C4%B1">https://www.youtube.com/watch?v=fPiwmoxa0QE&amp;ab_channel=ZiraatBankas%C4%B1</a></figcaption></figure><h4>I have shocking news for you. You can do this too, with your computer at home. Huh, sounds interesting, right? Let’s get to the tutorial then!</h4><h3>STEP 1: DOWNLOADING</h3><ul><li>First of all, we need to get to the Github page of this project.</li></ul><h4><a href="https://github.com/iperov/DeepFaceLab">https://github.com/iperov/DeepFaceLab</a></h4><ul><li>You will see the “Releases” section when you scroll down. Pick the most suitable version for yourself. I used the Torrent Client to download.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/841/1*QvmfLrU3-CDxbmHiB4fuxQ.png" /></figure><ul><li>You don’t need to download all of them. Download only a suitable one for your graphic cards. I have an RTX 2060, and I downloaded the NVIDIA-up-to-RTX2080Ti one.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*pUGRElat6xaRFHWeShRm3g.jpeg" /></figure><ul><li>When downloading process is done, double click and hit “Extract.” We are ready to create miracles now!</li></ul><h3>STEP 2: BEFORE WE START</h3><ul><li>This page welcomes you. It’s better to get used to it because you will spend all your time here. You will be the BFFs! The “Workspace” folder is where you’ll do wonders. It all starts here.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/656/1*8rUw1nlJSz8Ms9_81W8E3Q.jpeg" /></figure><ul><li>Two .mp4 videos named “<strong>data_dst” </strong>and<strong> “data_src” </strong>welcome you when you enter the “Workspace” folder. These two videos come as default videos, and you can start working on them directly. I tried with these two videos, but I replaced them with new ones later, when I was working on new projects. That’s why, these two videos in the photo below this text, aren’t the default ones. I put them there.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/835/1*B8MdMhY1LLXNEMkzbUPPyw.jpeg" /><figcaption>videos named “data_dst ve data_src”</figcaption></figure><h4>“data_src” (source) is your source video.</h4><h4>“data_dst” (destination) is your destination video.</h4><p>Facesets from the data_src video will be extracted, and they will be replaced with the face in the data_dst video.</p><h3>Source and destination videos requirements</h3><ul><li>High resolution (4K WebM is best, lower than 1080p is not recommended)</li><li>Faces not too far from the camera and unobstructed</li><li>Multiple angles, facial expressions</li><li>Brightly and evenly lit</li><li>Faces should somewhat match (beard, hat, hair, skin color, shape, glasses)</li><li>Need at least 2 mins of good quality video. Interview videos work well.</li></ul><p><em>(</em><a href="https://pub.dfblue.com/pub/2019-10-25-deepfacelab-tutorial"><em>https://pub.dfblue.com/pub/2019-10-25-deepfacelab-tutorial</em></a><em>)</em></p><h3>A SMALL NOTE FROM THE AUTHOR</h3><blockquote>You have to name the videos that you will work as “data_src” and “data_dst.” This is a very significant point. You can create a new folder and put your old data, source, and result videos in it. My advice to you is not to delete them because it’s good to compile them, and you can go back and look at your old projects and their materials.<br>In addition, just click the “clear workspace” when you start a new project. Everything is going to be ready to go. The only thing you need to do is to put “data_src” and “data_dst” videos into the workspace then.</blockquote><figure><img alt="" src="https://cdn-images-1.medium.com/max/597/1*rwM7dRMFbaHWSUMbUeryWA.jpeg" /></figure><h3>STEP 3: GUYS, FASTEN YOUR SEAT BELTS. WE ARE STARTING!</h3><p>What you need to do is;</p><ul><li>2) <em>extract images from video data_src </em>(It extracts images from “data_src”) (Press the “Enter” a few times to use the default settings.)</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/976/1*qhIHrD3e8YHxPGxeB8xzcg.jpeg" /><figcaption>When it’s done, you will see “Press a Key To Continue.”</figcaption></figure><ul><li>3) <em>extract images from video data_dst FULL FPS </em>(It extracts images from “data_dst”) (Press the “Enter” a few times to use the default settings.)</li><li>4) <em>data_src faceset extract </em>(It extracts facesets from data_src. See? It’s Not Rocket Science guys!)</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/443/1*d5GAH8cKn1TDEhdtDL21jg.jpeg" /><figcaption>When it asks you for the Face Type, write “wf” and use default settings then.</figcaption></figure><ul><li>4.1) <em>data_src view aligned result </em>(You can see your results here. For the best results, delete unnecessary photos that do not meet our criteria before starting the training session. For example, misrecognized faces, distorted images, etc.)</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*zJ7AIGU15yvrVs-JtqaK2A.jpeg" /></figure><ul><li><em>5) data_dst faceset extract </em>(It extracts facesets from data_dst) (Same as step 4)</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/443/1*d5GAH8cKn1TDEhdtDL21jg.jpeg" /><figcaption>When it asks you for the Face Type, write “wf” and use default settings then.</figcaption></figure><ul><li>5.1) <em>data_dst view aligned results (</em>You can see your results here. For the best results, delete unnecessary photos that do not meet our criteria before starting the training session. For example, misrecognized faces, distorted images, etc.) (same as step 4.1)</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*mSEC7ZsmpY-shz50SwG4Bw.jpeg" /></figure><ul><li><em>5.XSeg) data_dst mask — edit</em></li></ul><p>Now it’s a critical point. In this chapter, we will mask faces manually. We must do the masking process carefully. If you mask incorrectly or sloppy, you will get an annoying result. I did the masking process a bit sloppy and included the individual’s hair in several places. This produced a frustrating result. I’ll put the photo at the end.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*krN88Lr-JRLnhVE5_49AtA.jpeg" /><figcaption>More masking = Better results</figcaption></figure><ul><li><em>5.XSeg) data_src mask — edit</em></li></ul><p>We do the same process again for our source video. Same as the previous step.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*2l3CP0h02L1IQFwIUqMheQ.jpeg" /></figure><ul><li><em>5.XSeg) train</em></li></ul><p>Now it’s time to start training our XSeg model. When it asks you for Face type, write “wf” and start the training session by pressing Enter. The exciting part begins!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/767/1*2FispAkt9CMeIBVL3-oXrQ.jpeg" /></figure><p>First, let’s agree on this:</p><p>THE MORE ITERATIONS = THE BETTER RESULT</p><blockquote>My suggestion to you is to have a minimum of 10,000 Iters. Of course it could be more. Because what we just said, THE MORE ITERATIONS = THE BETTER RESULT.</blockquote><p>When you say OK, that’s enough, you can press “Enter” and complete the model’s training. Let’s continue.</p><ul><li><em>5.XSeg) data_dst trained mask — apply </em>(We apply our trained model)</li><li><em>5.XSeg) data_src trained mask — apply </em>(We apply our trained model)</li><li><em>5.XSeg) data_src mask — edit (</em>We check the result, mask the bad results again to get the best output<em>)</em></li><li><em>5.XSeg) data_dst mask — edit (</em>We check the result, mask the bad results again to get the best output<em>)</em></li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*43Pu-KQF-tJGjv-G5fAyTg.jpeg" /></figure><ul><li><em>5.XSeg) train</em> (After remasking, we train some more. If you haven’t made any remaskings, you don’t need to retrain.)</li><li><em>5.XSeg) data_dst trained mask — apply</em> (We apply the retrained model just like previous steps.)</li><li><em>5.XSeg) data_src trained mask — apply (</em>We apply the retrained model just like previous steps.)</li></ul><h3>AND THE MAGIC STARTS!</h3><p>As the last step;</p><h4>6) train SAEHD</h4><p>We click and start the training of our model. Make sure to have a minimum of 100.000 iterations. The more, the better. If you wish, you can do 500.000 or 1.000.000 iterations. But the more iters, the better result! When you say “OK, it’s enough,” press the “Enter” key and complete the training session.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/643/1*ApnOz2-0qaYHrpMhzsJvyA.jpeg" /></figure><p>Your system will have hard times during this process. Your computer will get hot as hell. I went and bought a laptop cooler for myself while the process was going on. I’ll show you this with a picture.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*jv_8RXydptfcSvN5iGZT4A.jpeg" /><figcaption>Graphics Card</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*aHVo3Txmy9wpmgwpDCMTqA.jpeg" /><figcaption>Processor</figcaption></figure><h3>STEP 4: TOWARDS THE FINAL</h3><p>We have come to an end now.</p><ul><li><em>7) merge SAEHD</em></li></ul><p>And you’ll see an interactive screen.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/939/1*q-XKYf0IxSxKtknxPhpZcA.jpeg" /><figcaption>You can decide on the most appealing result by pressing options such as Q-A / W-S / E-D / R-F / T-G / Y-H-N / U-J. You can switch between screens by pressing the TAB key. When you’re done, press Shift + M and Shift + ? so you can apply them for previous and next frames. It would be more beneficial for you to try the options one by one.</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*6M0IYNNDOajkklVF7eyvBA.jpeg" /><figcaption>After you get your result, make sure to press “C” to apply “Color Transfer Mode.” You can play on it however you want. Remember, this is where you do wonders, and it has a massive impact on how realistic you will get the result.</figcaption></figure><p>In this example, you see the results of false masking. If the masking process had been done in more detail, I would have achieved an incredibly realistic result this time. I made this mistake on purpose so that you don’t make the same mistakes.</p><h3>STEP 5: GRAND FINAL!</h3><p><em>8) merged to mp4</em></p><p>Click it, and you will see your result. The result you get will be waiting for you in the “Workspace” folder with the name “result.mp4”. You can share your results with your friends and loved ones, on the internet or with me!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/861/1*1wjgcICwjRmVVTsxda53LQ.jpeg" /></figure><p>I hope this tutorial will be useful for you. You can ask me questions anytime.</p><p>You can contact me on:</p><p><strong>LinkedIn:</strong> <a href="https://www.linkedin.com/in/mehmet-emin-masca-359812207/">https://www.linkedin.com/in/mehmet-emin-masca-359812207/</a></p><p><strong>E-Mail:</strong> eminmasca@hotmail.com</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=aa2aa12c08f3" width="1" height="1" alt=""><hr><p><a href="https://medium.com/geekculture/creating-deepfake-miracles-with-deepfacelab-tutorial-saehd-model-aa2aa12c08f3">Creating Deepfake Miracles With DeepFaceLab Tutorial (SAEHD Model)</a> was originally published in <a href="https://medium.com/geekculture">Geek Culture</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[DeepFaceLab ile Birbirinden Gerçekçi Deepfake Videolar Oluşturma Rehberi!]]></title>
            <link>https://eminmasca.medium.com/deepfacelab-ile-birbirinden-ger%C3%A7ek%C3%A7i-deepfake-videolar-olu%C5%9Fturma-rehberi-948c75c643d0?source=rss-daacecdaab2c------2</link>
            <guid isPermaLink="false">https://medium.com/p/948c75c643d0</guid>
            <category><![CDATA[ai]]></category>
            <category><![CDATA[tutorial]]></category>
            <category><![CDATA[machine-learning]]></category>
            <category><![CDATA[deep-learning]]></category>
            <category><![CDATA[yazılım]]></category>
            <dc:creator><![CDATA[Mehmet Emin Masca]]></dc:creator>
            <pubDate>Wed, 18 Aug 2021 14:39:19 GMT</pubDate>
            <atom:updated>2021-11-11T20:23:28.455Z</atom:updated>
            <content:encoded><![CDATA[<h3>DeepFaceLab ile Birbirinden Gerçekçi Deepfake Videolar Oluşturma Rehberi! (SAEHD Model)</h3><p>Şüphesiz günümüzün en ilginç ve dikkat çeken teknolojilerinden biri Deepfakes’tir diyebiliriz. Deepfakes, 2017 yıllarının sonuna doğru Reddit’te bir patlamayla ortaya çıkıyor ve o günden sonra hiçbir şey eskisi gibi olmuyor.</p><h3>PEKİ NEDİR BU DEEPFAKES DENEN MERET?</h3><p>Vikipedi’deki tanımına göre Deepfakes: <strong><em>Deepfakes</em></strong><em>, mevcut bir görüntü veya videoda yer alan bir kişinin, </em><a href="https://tr.wikipedia.org/wiki/Yapay_sinir_a%C4%9Flar%C4%B1"><em>yapay sinir ağları</em></a><em> kullanarak bir başka kişinin görüntüsü ile değiştirildiği bir medya türüdür. Sıklıkla, otomatik kodlayıcılar ve üretken çekişmeli ağlar (GAN’lar) olarak bilinen </em><a href="https://tr.wikipedia.org/wiki/Makine_%C3%B6%C4%9Frenimi"><em>makine öğrenme</em></a><em> tekniklerini kullanarak mevcut medyanın kaynak medya üzerinde birleştirilmesi ve üst üste konması ile üretilirler.</em><a href="https://tr.wikipedia.org/wiki/Deepfake#cite_note-Schwartz2-1"><em>[1]</em></a><a href="https://tr.wikipedia.org/wiki/Deepfake#cite_note-:142-2"><em>[2]</em></a><em> Deepfakes, “deep learning” (</em><a href="https://tr.wikipedia.org/wiki/Derin_%C3%B6%C4%9Frenme"><em>derin öğrenme</em></a><em>) ve “fake” (sahte) kelimelerden türetilmiş bir </em><a href="https://tr.wikipedia.org/wiki/Birle%C5%9Fik_s%C3%B6zc%C3%BCk"><em>birleşik kelimedir</em></a><em>.</em><a href="https://tr.wikipedia.org/wiki/Deepfake#cite_note-FoxNews2018-3"><em>[3]</em></a></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/479/1*0H4lFJ9aUpy4za1FgpoBfQ.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/479/1*IV_PDAGibGsruLrpY_NMZQ.jpeg" /><figcaption>Bireylerin başlarını değiştirme</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/479/1*VP6lqHPkfx_Pzgf-vBMMbg.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/479/1*_kX63aX3rdMfUwZAT7AWqg.jpeg" /><figcaption>Bir başka örnek</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/731/1*WyNAJ76Y6agjIPixQ1BK4g.jpeg" /><figcaption>Bu da ülkemizden bir örnek. Görüntü, Ziraat Bankası’na ait bir reklamdan. <a href="https://www.youtube.com/watch?v=fPiwmoxa0QE&amp;ab_channel=ZiraatBankas%C4%B1">https://www.youtube.com/watch?v=fPiwmoxa0QE&amp;ab_channel=ZiraatBankas%C4%B1</a></figcaption></figure><h4>Sizlere şok edici bir haberim var. Bunu evdeki bilgisayarınız ile siz de yapabilirsiniz, hem de hiçbir kodlama bilgisine sahip olmadan! Şaşırtıcı değil mi? Öyleyse sizler için hazırladığım tutorial’a geçiş yapalım.</h4><h3><strong>ADIM 1: İNDİRME İŞLEMLERİ!</strong></h3><ul><li>Öncelikle sizlere verdiğim linkten projenin Github sayfasına gidiyoruz.</li></ul><h4><a href="https://github.com/iperov/DeepFaceLab">https://github.com/iperov/DeepFaceLab</a></h4><ul><li>Ardından sayfada biraz aşağı indiğinizde <strong>Releases </strong>kısmını göreceksiniz. Buradan kendinize uygun olan versiyonu seçiniz. Ben ilk seçeneği seçip Torrent ile indirmiştim.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/841/1*QvmfLrU3-CDxbmHiB4fuxQ.png" /></figure><ul><li>Linkteki bütün dosyaları indirmenize gerek yok. Ekran kartınız için hangisi uygunsa sadece onu indirmeniz yeterli. Ben acı yoldan tecrübe etmiştim:)</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*pUGRElat6xaRFHWeShRm3g.jpeg" /></figure><ul><li>Dosyamız indikten sonra çift tık yapıp <strong>Extract </strong>diyoruz ve hepsi bu kadar! Artık bu heyecan verici teknolojiyle harikalar yaratmaya hazırız.</li></ul><h3>ADIM 2: ÖN HAZIRLIKLAR</h3><ul><li>Bizleri böyle bir ekran karşılayacak. Bu ekrana alışın çünkü bütün vaktinizi burada geçireceksiniz. Ayrılmaz bir dost olacaksınız… Workspace dosyası sizin harikalar yaratacağınız yer. Bütün olay burada başlıyor.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/656/1*8rUw1nlJSz8Ms9_81W8E3Q.jpeg" /></figure><ul><li>Workspace klasörünün içine girdiğinizde sizi “<strong>data_dst” </strong>ve<strong> “data_src” </strong>isimli iki tane .mp4 dosyası karşılayacak. Bu iki video, programı indirdiğinizde default olarak geliyor ve direkt bu videolar üzerinden çalışmaya başlayabilirsiniz. Ben de ilk denememi o videolar üzerinde yapmıştım ancak sonradan farklı denemelerde de bulunduğum için bu iki dosyayı değiştirip yerlerine başka videolar koydum. Bu yüzden fotoğrafta gördüğünüz videolar, sizin programı indirdiğinizde karşılaştığınız videolar değil.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/835/1*B8MdMhY1LLXNEMkzbUPPyw.jpeg" /><figcaption>“data_dst ve data_src” isimli videolar</figcaption></figure><h4>“data_src” (source) sizin kaynak olarak kullanacağınız videodur.</h4><h4>“data_dst” (destination) sizin hedef videonuzdur.</h4><p>data_src videosundan faceset’ler çıkarılacak ve hedef nokta olan data_dst videosundaki bireye aktarılacaktır.</p><blockquote><strong><em>KAYNAK VE HEDEF VİDEOLARINIZI SEÇERKEN DİKKAT ETMENİZ GEREKEN HUSUSLAR</em></strong></blockquote><blockquote>Yüksek çözünürlüklü olmalı</blockquote><blockquote>Videodaki yüzler, kameradan çok uzak olmamalı</blockquote><blockquote>Bireylerin yüzleri, birden fazla açıdan çekilmiş ve mimik açısından zengin olmalı</blockquote><blockquote>Aydınlatma iyi olmalı</blockquote><blockquote>Yüzlerin bir şekilde eşleşmesi gerekiyor. Örneğin videoların birinde gözlüksüz birini kullanırken diğer videoda gözlüklü birini kullanmayın. Tecrübeyle sabittir:)</blockquote><h3>UFAK BİR NOT</h3><blockquote>Öncelikle sizlere ufak bir not geçmek istiyorum.</blockquote><blockquote>Çalışacağınız videoların ismi her zaman “data_dst” ve “data_src” olmalı. Workspace’inizdeki eski videoları, Masaüstünüzde yeni bir klasör açıp orada saklayabilirsiniz. Benim sizlere önerim silmemeniz yönünde çünkü ortaya çıkardığınız işleri belirli bir yerde derlemiş olursunuz ve istediğiniz zaman geriye dönüp tekrar bakabilirsiniz.</blockquote><blockquote>Ek olarak, yeni bir projeye başlayacağınız zaman, görselde olduğu gibi “clear workspace”e basarsanız sistem sizin için her şeyi hazır hale getirecek. “Workspace” klasörünüze hedef ve kaynak videolarınızı koyup çalışmaya başlayabilirsiniz.</blockquote><figure><img alt="" src="https://cdn-images-1.medium.com/max/597/1*rwM7dRMFbaHWSUMbUeryWA.jpeg" /></figure><h3>ADIM 3: EMNİYET KEMERLERİNİZİ BAĞLAYIN, BAŞLIYORUZ!</h3><p>Sırasıyla yapmanız gerekenler;</p><ul><li>2) <em>extract images from video data_src </em>(data_src.mp4 videosunu fotoğraflara bölüyor) (Çıkan ekranda birkaç defa “Enter” tuşuna basarak default ayarları kullanabilirsiniz.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/976/1*qhIHrD3e8YHxPGxeB8xzcg.jpeg" /><figcaption>İşleminiz bitince “Press a Key to Continue” yazacak ve ondan sonra ekranı kapatabilirsiniz.</figcaption></figure><ul><li>3) <em>extract images from video data_dst FULL FPS </em>(Bu sefer de data_dst.mp4 videosunu fotoğraflara bölüyor) (Çıkan ekranda birkaç defa “Enter” tuşuna basarak default ayarları kullanabilirsiniz)</li><li>4) <em>data_src faceset extract </em>(data_src.mp4 videosundan faceset’leri çıkarıyoruz)</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/443/1*d5GAH8cKn1TDEhdtDL21jg.jpeg" /><figcaption>Size Face Type sorduğunda “wf” yazın ve sonrasında default ayarları kullanmaya devam edin</figcaption></figure><ul><li>4.1) <em>data_src view aligned result </em>(Elde ettiğiniz sonuçları burada görebilirsiniz. En iyi sonuca ulaşmak için Training’e başlamadan önce burada kriterlerimize uymayan gereksiz fotoğrafları silin. Örneğin yanlış tanınan yüzler, yamuk fotoğraflar vs.)</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*zJ7AIGU15yvrVs-JtqaK2A.jpeg" /></figure><ul><li><em>5) data_dst faceset extract </em>(data_dst.mp4 videosundan faceset’leri çıkarıyoruz) (4.aşamanın aynısı)</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/443/1*d5GAH8cKn1TDEhdtDL21jg.jpeg" /><figcaption>Size Face Type sorduğunda “wf” yazın ve sonrasında default ayarları kullanmaya devam edin</figcaption></figure><ul><li>5.1) <em>data_dst view aligned results </em>(Elde ettiğiniz sonuçları burada görebilirsiniz. En iyi sonuca ulaşmak için Training’e başlamadan önce burada kriterlerimize uymayan gereksiz fotoğrafları silin. Örneğin yanlış tanınan yüzler, yamuk fotoğraflar vs.) (4.1. aşamanın aynısı)</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*mSEC7ZsmpY-shz50SwG4Bw.jpeg" /></figure><ul><li><em>5.XSeg) data_dst mask — edit</em></li></ul><p>İşte burası çok önemli arkadaşlar. Bu bölümde bazı yüzlere kendimiz manuel olarak maskeleme işlemi yapacağız. Maskeleme işlemini dikkatli yapmamız çok mühim bir mesele. Yanlış veya baştan savma bir maskeleme yaparsanız göze batan bir sonuç elde edersiniz. Ben maskeleme işlemini biraz baştan savma yapmıştım ve bireyin saçlarını da dahil etmiştim birkaç yerde. Bu da can sıkıcı bir sonuç ortaya çıkardı. En sona fotoğrafını koyacağım.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*krN88Lr-JRLnhVE5_49AtA.jpeg" /><figcaption>Ne kadar çok fotoğraf üzerinde maskeleme yaparsanız o kadar iyi fakat çok da abartmamak lazım.</figcaption></figure><ul><li><em>5.XSeg) data_src mask — edit</em></li></ul><p>Aynı işlemi bu sefer de kaynak videomuz için yapıyoruz. Bir önceki işlemin aynısı.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*2l3CP0h02L1IQFwIUqMheQ.jpeg" /></figure><ul><li><em>5.XSeg) train</em></li></ul><p>Şimdi bu XSeg modelimizi eğitmeye başlıyoruz. Sizlere Facetype sorusunu yönelttiğinde yine “wf” yazınız. Enter’a basıp işlemi başlatınız. Heyecan verici kısım başlıyor!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/767/1*2FispAkt9CMeIBVL3-oXrQ.jpeg" /></figure><p>Öncelikle şu konuda bir anlaşalım:</p><h3><strong>NE KADAR ÇOK ITERATIONS = O KADAR İYİ BİR SONUÇ</strong></h3><blockquote>Sizlere önerim minimum 10.000 Iters olması. Tabii ki daha fazlası da olur. Çünkü biraz önce ne dedik, NE KADAR ÇOK ITERATIONS = O KADAR İYİ BİR SONUÇ.</blockquote><p>Tamam bu kadar yeterli dediğiniz an “Enter”a basıp modelin eğitimini tamamlayabilirsiniz. Devam edelim.</p><ul><li><em>5.XSeg) data_dst trained mask — apply </em>(Eğitilmiş modelimizi uyguluyoruz)</li><li><em>5.XSeg) data_src trained mask — apply </em>(Eğitilmiş modelimizi uyguluyoruz)</li><li><em>5.XSeg) data_src mask — edit (Sonucu kontrol ediyoruz, en iyi çıktıyı elde etmek için kötü sonuçlara tekrar maskeleme yapıyoruz)</em></li><li><em>5.XSeg) data_dst mask — edit (Sonucu kontrol ediyoruz, en iyi çıktıyı elde etmek için kötü sonuçlara tekrar maskeleme yapıyoruz)</em></li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*43Pu-KQF-tJGjv-G5fAyTg.jpeg" /></figure><ul><li><em>5.XSeg) train</em> (Düzeltmeleri yaptıktan sonra biraz daha eğitiyoruz. Eğer hiçbir düzeltme yapmadıysanız tekrar eğitmenize gerek yok.)</li><li><em>5.XSeg) data_dst trained mask — apply</em> (Bu sefer de yeniden eğitilmiş halini uyguluyoruz, fark ettiyseniz öncekiyle aynı aşama)</li><li><em>5.XSeg) data_src trained mask — apply (</em>Bu sefer de yeniden eğitilmiş halini uyguluyoruz, fark ettiyseniz öncekiyle aynı aşama)</li></ul><h3><strong>ŞİMDİ SİHİR BAŞLIYOR</strong></h3><p>Son aşama olarak ise;</p><h4><em>6) train SAEHD</em></h4><p>diyoruz ve modelimizin eğitimine başlıyoruz. Minimum 100.000 iterations olmasına önem verin. Neydi, ne kadar çok olursa o kadar çok iyiydi. İsterseniz 500.000 isterseniz 1.000.000 iterations yapabilirsiniz. Ama iyi bir sonuç için ne-kadar-çok-o-kadar-iyi! Tamam yeter dediğiniz an “Enter” tuşuna basın ve eğitimi tamamlayın.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/643/1*ApnOz2-0qaYHrpMhzsJvyA.jpeg" /></figure><p>Bu aşamada sisteminiz biraz zorlanacak. Bilgisayarınız cehennem gibi ısınacak. Ben işlem devam ederken kendime gidip bir laptop soğutucu almıştım. Sistemin ne kadar zorlandığını size bir görselle kanıtlayacağım. Bilgisayarınıza ödediğiniz paradan kuruşuna kadar faydalanıyorsunuz bu işlem esnasında! :)</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*jv_8RXydptfcSvN5iGZT4A.jpeg" /><figcaption>Ekran Kartı</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*aHVo3Txmy9wpmgwpDCMTqA.jpeg" /><figcaption>İşlemci</figcaption></figure><h3><strong>ADIM 4: FİNALE DOĞRU</strong></h3><p>Eveet pek değerli arkadaşım, artık yüzdük yüzdük ve kuyruğuna geldik.</p><ul><li><em>7) merge SAEHD</em></li></ul><p>diyoruz ve karşımıza interaktif bir ekran çıkıyor.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/939/1*q-XKYf0IxSxKtknxPhpZcA.jpeg" /><figcaption>Q-A / W-S / E-D / R-F / T-G / Y-H-N / U-J gibi seçeneklere basarak göze en çok hitap eden sonuca karar verebilirsiniz. TAB tuşuna basarak ekranlar arasında geçiş yapabilirsiniz. İşiniz bitince <strong>Shift </strong>+ <strong>M</strong> ve <strong>Shift</strong> + <strong>? </strong>tuşlarına basarak önceki ve sonraki Frame’ler için uygulayabilirsiniz bunları. Buradaki seçenekleri karıştırıp tek tek denemek sizin için daha faydalı olur.</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*6M0IYNNDOajkklVF7eyvBA.jpeg" /><figcaption>Sonucunuzu elde ettikten sonra mutlaka “C”ye basarak “Color Transfer Mode”u uygulayın. Üzerinde istediğiniz gibi oynama yapabilirsiniz. Unutmayın, burası sizin harikalar yarattığınız yer ve ne kadar gerçekçi bir sonuç elde edeceğinize etkisi çok büyük.</figcaption></figure><p>Bu örnekte yanlış maskelemenin sonuçlarını görüyorsunuz arkadaşlar. Maskeleme işlemi daha detaylı yapılsaydı bu sefer inanılmaz gerçekçilikte bir sonuç elde edecektim. Amaa siz aynı hataları yapmayın diye ben sizin için önden yaptım:)</p><h3><strong>ADIM 5: BÜYÜK FİNAL!</strong></h3><p><em>8) merged to mp4 </em>seçeneğine tıklayarak artık videonuzu elde edebilirsiniz. Elde ettiğiniz sonuç “Workspace” klasöründe “result.mp4” ismiyle sizleri bekliyor olacak. İster arkadaşlarınızla ve sevdiklerinizle ister internette isterseniz de benimle de paylaşabilirsiniz sonuçlarınızı!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/861/1*1wjgcICwjRmVVTsxda53LQ.jpeg" /></figure><h4>Umarım sizler için faydalı bir tutorial olmuştur. Sorularınızı 7/24 iletebilirsiniz bana, müsait olduğum zamanlarda hepsine tek tek cevap vereceğim.</h4><h4>Sizlerle sosyal medya hesaplarımı da paylaşıyorum, bana istediğiniz mecradan ulaşabilirsiniz. Bir sonraki yazıma kadar görüşmek üzere;)</h4><p>E-Mail: eminmasca@hotmail.com</p><p>LinkedIn: <a href="https://www.linkedin.com/in/mehmet-emin-masca-359812207/">https://www.linkedin.com/in/mehmet-emin-masca-359812207/</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=948c75c643d0" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>