A Robust Approach for Deepfake Detection Using SWIN Transformer | Research Square window.SnipcartSettings = { analytics: { enabled: false } }; (function() { var accessVector = localStorage.getItem('access_vector') || ''; window.dataLayer = window.dataLayer || []; if (accessVector) { window.dataLayer.push({ user: { profile: { profileInfo: { snid: accessVector } } } }); } })(); (function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start':new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0],j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src='https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f);})(window,document,'script','dataLayer','GTM-K279D39R'); Browse Preprints In Review Journals COVID-19 Preprints AJE Video Bytes Research Tools Research Promotion AJE Professional Editing AJE Rubriq About Preprint Platform In Review Editorial Policies Our Team Advisory Board Help Center Sign In Submit a Preprint Cite Share Download PDF Research Article A Robust Approach for Deepfake Detection Using SWIN Transformer Soumya Ranjan Mishra, Hitesh Mohapatra, Mahendra Kumar Gourisaria This is a preprint; it has not been peer reviewed by a journal. https://doi.org/ 10.21203/rs.3.rs-4672886/v1 This work is licensed under a CC BY 4.0 License Status: Posted Version 1 posted You are reading this latest preprint version Abstract The widespread use of deepfake technology in recent years has made it extremely difficult to differentiate between real and fake images, usually AI-generated images. Effective detection techniques are desperately needed because one can generate fake images and spread them with ease. In response to the situation, this research paper explores the effectiveness of employing SWIN Transformer, a cutting-edge transformer-based architecture, for deep fake image detection. The foundation of the suggested detection framework is an architecture made up of bottleneck, encoder, and decoder parts which is a type of SWIN transformer. It uses various self-attention mechanisms and advanced features to analyse the images closely whether it is a real image or a deepfake one. It relies on the concept of shifted windows during the processing of the images and is considered more effective than the traditional CNN methods. Our test results show how well the SWIN Transformer-based method performs in precisely recognizing deep fake images. The accuracy is found to be 97.91% for CelebDF dataset and 95.715% for FF++ dataset. The AUC for the newly modelled SWIN transformer is 0.99 and 0.9625 for CelebDF and FF++ datasets respectively. The Log Loss has been calculated to be 0.034 for CelebDF dataset and 0.1573 for FF++ dataset. The proposed methodology not only enhances the accuracy of detecting manipulated images but also offers potential for scalable and efficient deployment in real-world scenarios where the proliferation of deepfakes presents significant challenges to maintaining trust and authenticity in visual media. Deepfake Image classification SWIN transformers fake image generation image detection Hierarchical Representation Transformer Block Quadratic Complexity SWIN Transformer blocks Object Detection Full Text Additional Declarations No competing interests reported. Cite Share Download PDF Status: Posted Version 1 posted You are reading this latest preprint version Research Square lets you share your work early, gain feedback from the community, and start making changes to your manuscript prior to peer review in a journal. As a division of Research Square Company, we’re committed to making research communication faster, fairer, and more useful. We do this by developing innovative software and high quality services for the global research community. Our growing team is made up of researchers and industry professionals working together to solve the most critical problems facing scientific publishing. Also discoverable on Platform About Our Team In Review Editorial Policies Advisory Board Help Center Resources Author Services Accessibility API Access RSS feed Manage Cookie Preferences © Research Square 2026 | ISSN 2693-5015 (online) Privacy Policy Terms of Service Do Not Sell My Personal Information {"props":{"pageProps":{"initialData":{"identity":"rs-4672886","acceptedTermsAndConditions":true,"allowDirectSubmit":true,"archivedVersions":[],"articleType":"Research Article","associatedPublications":[],"authors":[{"id":322523857,"identity":"ef24c788-a8ed-42b0-9e9e-ef08798359e2","order_by":0,"name":"Soumya Ranjan Mishra","email":"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAZAAAAAyAQMAAABI0h/eAAAABlBMVEX///8AAABVwtN+AAAACXBIWXMAAA7EAAAOxAGVKw4bAAABOklEQVRIie3RMUvEMBQH8MaCU4+uhRP6FSridRI/iEvKra0oB0eHWgJCuxzOFfT8ChWh4JYjkC4B18qBnA5ObsLRQcSXHg7aK+ImmD/kkZT3Iy9U01RU/nYoLEfDq20IVdfJb4iQBP1EVmmIhpKmriV2Otm9MaIH20Xs+ak6ig/dlCJ2PD05MFMgdVh8J44Qg7nBR9u3hLs7vsNGWwJr7Lwog4whgiZi3iKWD2QTo5zSQd93qJfBbKxX8IAA0VHSInYmyTvez2m5BBJ7mbkAcsGDqw6iVUB6CfZyKuQtupdZ8hYSBXkHcQQf31+e4SGQMRAG5JEwg9PgGshszVvs9LSoXpZ4L6/Kou+/ycGG7NWI4mB6x2aLOmwPBtkwZLXo57n5HazZ0jXtTUstq0m+fIw7mlVUVFT+YT4A9FGBVRnxYgAAAAAASUVORK5CYII=","orcid":"","institution":"KIIT (Deemed to be) University","correspondingAuthor":true,"prefix":"","firstName":"Soumya","middleName":"Ranjan","lastName":"Mishra","suffix":""},{"id":322523858,"identity":"01a22bcf-40b4-4d4b-94ee-15e95b13468a","order_by":1,"name":"Hitesh Mohapatra","email":"","orcid":"","institution":"KIIT (Deemed to be) University","correspondingAuthor":false,"prefix":"","firstName":"Hitesh","middleName":"","lastName":"Mohapatra","suffix":""},{"id":322523859,"identity":"1dcd1903-1bdb-4502-ae85-8735e1d571b9","order_by":2,"name":"Mahendra Kumar Gourisaria","email":"","orcid":"","institution":"KIIT (Deemed to be) University","correspondingAuthor":false,"prefix":"","firstName":"Mahendra","middleName":"Kumar","lastName":"Gourisaria","suffix":""}],"badges":[],"createdAt":"2024-07-02 09:00:19","currentVersionCode":1,"declarations":"","doi":"10.21203/rs.3.rs-4672886/v1","doiUrl":"https://doi.org/10.21203/rs.3.rs-4672886/v1","draftVersion":[],"editorialEvents":[],"editorialNote":"","failedWorkflow":false,"files":[{"id":61115809,"identity":"7f202d98-4784-49f9-9bc1-8f2e0f48e18f","added_by":"auto","created_at":"2024-07-25 19:37:20","extension":"pdf","order_by":1,"title":"","display":"","copyAsset":false,"role":"manuscript-pdf","size":754497,"visible":true,"origin":"","legend":"","description":"","filename":"manuscriptswin.pdf","url":"https://assets-eu.researchsquare.com/files/rs-4672886/v1_covered_63b19595-0ef4-479b-8d1c-7bf2fc134249.pdf"}],"financialInterests":"No competing interests reported.","formattedTitle":"A Robust Approach for Deepfake Detection Using SWIN Transformer","fulltext":[],"fulltextSource":"","fullText":"","funders":[],"hasAdminPriorityOnWorkflow":false,"hasManuscriptDocX":false,"hasOptedInToPreprint":true,"hasPassedJournalQc":"","hasAnyPriority":false,"hideJournal":true,"highlight":"","institution":"","isAcceptedByJournal":false,"isAuthorSuppliedPdf":true,"isDeskRejected":"","isHiddenFromSearch":false,"isInQc":false,"isInWorkflow":false,"isPdf":true,"isPdfUpToDate":true,"isWithdrawnOrRetracted":false,"journal":{"display":true,"email":"
[email protected]","identity":"researchsquare","isNatureJournal":false,"hasQc":true,"allowDirectSubmit":true,"externalIdentity":"","sideBox":"","snPcode":"","submissionUrl":"/submission","title":"Research Square","twitterHandle":"researchsquare","acdcEnabled":true,"dfaEnabled":false,"editorialSystem":"","reportingPortfolio":"","inReviewEnabled":false,"inReviewRevisionsEnabled":true},"keywords":"Deepfake, Image classification, SWIN transformers, fake image generation, image detection, Hierarchical Representation, Transformer Block, Quadratic Complexity, SWIN Transformer blocks, Object Detection","lastPublishedDoi":"10.21203/rs.3.rs-4672886/v1","lastPublishedDoiUrl":"https://doi.org/10.21203/rs.3.rs-4672886/v1","license":{"name":"CC BY 4.0","url":"https://creativecommons.org/licenses/by/4.0/"},"manuscriptAbstract":"\u003cp\u003eThe widespread use of deepfake technology in recent years has made it extremely difficult to differentiate between real and fake images, usually AI-generated images. Effective detection techniques are desperately needed because one can generate fake images and spread them with ease. In response to the situation, this research paper explores the effectiveness of employing SWIN Transformer, a cutting-edge transformer-based architecture, for deep fake image detection. The foundation of the suggested detection framework is an architecture made up of bottleneck, encoder, and decoder parts which is a type of SWIN transformer. It uses various self-attention mechanisms and advanced features to analyse the images closely whether it is a real image or a deepfake one. It relies on the concept of shifted windows during the processing of the images and is considered more effective than the traditional CNN methods. Our test results show how well the SWIN Transformer-based method performs in precisely recognizing deep fake images. The accuracy is found to be 97.91% for CelebDF dataset and 95.715% for FF++ dataset. The AUC for the newly modelled SWIN transformer is 0.99 and 0.9625 for CelebDF and FF++ datasets respectively. The Log Loss has been calculated to be 0.034 for CelebDF dataset and 0.1573 for FF++ dataset. The proposed methodology not only enhances the accuracy of detecting manipulated images but also offers potential for scalable and efficient deployment in real-world scenarios where the proliferation of deepfakes presents significant challenges to maintaining trust and authenticity in visual media.\u003c/p\u003e","manuscriptTitle":"A Robust Approach for Deepfake Detection Using SWIN Transformer","msid":"","msnumber":"","nonDraftVersions":[{"code":1,"date":"2024-07-25 19:21:12","doi":"10.21203/rs.3.rs-4672886/v1","editorialEvents":[{"type":"communityComments","content":0}],"status":"published","journal":{"display":true,"email":"
[email protected]","identity":"researchsquare","isNatureJournal":false,"hasQc":true,"allowDirectSubmit":true,"externalIdentity":"","sideBox":"","snPcode":"","submissionUrl":"/submission","title":"Research Square","twitterHandle":"researchsquare","acdcEnabled":true,"dfaEnabled":false,"editorialSystem":"","reportingPortfolio":"","inReviewEnabled":false,"inReviewRevisionsEnabled":true}}],"origin":"","ownerIdentity":"edf8268f-dffc-4788-89c2-d36bd1962b09","owner":[],"postedDate":"July 25th, 2024","published":true,"recentEditorialEvents":[],"rejectedJournal":[],"revision":"","amendment":"","status":"posted","subjectAreas":[],"tags":[],"updatedAt":"2024-07-25T19:21:14+00:00","versionOfRecord":[],"versionCreatedAt":"2024-07-25 19:21:12","video":"","vorDoi":"","vorDoiUrl":"","workflowStages":[]},"version":"v1","identity":"rs-4672886","journalConfig":"researchsquare"},"__N_SSP":true},"page":"/article/[identity]/[[...version]]","query":{"redirect":"/article/rs-4672886","identity":"rs-4672886","version":["v1"]},"buildId":"qtupq5eGEP_6zYnWcrvyt","isFallback":false,"isExperimentalCompile":false,"dynamicIds":[84888],"gssp":true,"scriptLoader":[]}
Text is read by the "Ask this paper" AI Q&A widget below.
Extraction quality varies by source — PMC NXML preserves structure
cleanly, OA-HTML may include some navigation residue, and OA-PDF can
have broken hyphenation. The publisher copy
(via DOI)
is the canonical version.