DeepFake Detection

Timeframe Nov 2022
Colab View colab
tools Python TensorFlow Keras
00. Overview

DeepFake Detection.

This project focuses on classifying DeepFake images using convolutional neural networks (CNNs). The goal is to build a model that can classify images as either real or DeepFake, making this a binary classification problem. Three approaches were explored: a basic CNN as a baseline, a CNN with augmented images to improve generalization, and a pre-trained VGG16 model. The dataset consisted of 12,000 images, split into training, validation, and test sets, and the models were trained using Google Colab.

01. Methodology

Methodology.

Dataset Preparation:
A dataset of 12,000 images (8,000 manipulated, 4,000 original) was loaded, preprocessed, and split into training (65%), validation (20%), and test (15%) sets.
Model Architectures:
CNN: A simple CNN with three convolutional layers followed by max pooling and fully connected layers.
CNN with Augmentation: The same CNN architecture but trained with augmented data (rotation, shifting, flipping, and zooming) to improve generalization.
VGG16 Pretrained Model: A deep CNN architecture with frozen layers to extract features, followed by custom dense layers for classification.
The models were trained for 10 epochs, and their accuracy and loss were compared using training and validation data.
02. Results

Results.

Basic CNN: Performed the best in terms of accuracy and speed, achieving around 67-69% validation accuracy.
Augmented CNN: Showed underfitting; augmentation did not significantly improve performance, likely due to limited epochs and dropout.
VGG16 Model: Also exhibited underfitting but had steady improvement, reaching around 69-70% validation accuracy.
Computational Limitations: Training took several hours, limiting the ability to fine-tune models.