Skip to content

a deep learning project that uses ResNet and Inception architectures to classify real vs AI-generated face images. The project includes two models trained on a custom dataset, achieving validation accuracies of 52.45% (ResNet) and 52.94% (Inception). Built with TensorFlow and Flask, and a web interface for real time face classification

License

Notifications You must be signed in to change notification settings

arsath-eng/face_classification

Repository files navigation

Face Classification Project 🎭

Python Flask TensorFlow HuggingFace

A deep learning project for detecting and classifying real and artificially generated face images using ResNet and Inception architectures. 👤✨

Project Banner

📋 Table of Contents

🔍 Overview

This project implements two deep learning models to classify images as either real or AI-generated faces:

  • Model 1: ResNet-based architecture with residual connections
  • Model 2: Inception-style network with multi-scale feature processing

🏗️ Model Architecture

ResNet Model (Model 1)

  • Deep CNN with residual connections
  • Handles vanishing gradient problem
  • Effective for complex feature learning
  • Multiple residual blocks with increasing filter sizes
  • Dropout layers for regularization

Inception Model (Model 2)

  • Multi-scale feature processing
  • Efficient computational design
  • Parallel convolutional paths
  • Adaptive to varying face sizes and orientations
  • Better generalization capabilities

📊 Performance

Model Validation Accuracy Validation Loss
ResNet 52.45% 0.7246
Inception 52.94% 0.6913

Project Overview

## 🚀 Installation

1. Set up Conda Environment

# Create new environment
conda create -p face python=3.9

# Activate environment
conda activate face

# Install requirements
pip install -r requirements.txt

2. Requirements

Create a requirements.txt file with:

Flask==2.1.0
tensorflow
numpy
opencv-python
pillow

💻 Usage

output

output

ouput

Running the Flask App

python app.py

Visit http://localhost:5000 in your web browser to access the application.

🔗 Model Links

🔄 Future Improvements

  1. 📈 Data Quality

    • Investigate dataset biases
    • Enhance data diversity
  2. 🔧 Model Architecture

    • Experiment with hybrid models
    • Implement transfer learning
    • Test ensemble methods
  3. ⚡ Performance

    • Extended training periods
    • Hyperparameter optimization
    • Advanced data augmentation techniques

🔗 Dataset

👥 Contributors

  • Arsath S.M
  • Faahiht K.R.M
  • Arafath M.S.M

📄 License

License: MIT

This project is licensed under the MIT License - see the LICENSE file for details.


Made with ❤️ at University of Jaffna Faculty of Engineering

About

a deep learning project that uses ResNet and Inception architectures to classify real vs AI-generated face images. The project includes two models trained on a custom dataset, achieving validation accuracies of 52.45% (ResNet) and 52.94% (Inception). Built with TensorFlow and Flask, and a web interface for real time face classification

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published