Skip to content

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

1 watching

Forks

Repository files navigation

AI-Generated vs Real Image Categorisation

  • Luca Pedranzini
  • Florian Tilliet

All notebooks can be viewed here in their html rendered version

Overview

This repository contains a deep learning project aimed at categorizing images as either AI-generated or real. The project explores various deep learning techniques, model architectures, and data processing methods to enhance the accuracy of image classification.

Project Structure

The project is divided into several iterations, each with objective of improving upon the previous one or trying a different architecture. This modular approach allows for detailed analysis and comparison of different methodologies and configurations.

Project Iterations

  • v1.0: Baseline implementation based on an example project.
  • v1.1: Subdivision of the baseline into distinct steps with performance evaluation on a laptop.
  • v1.2: Addition of data augmentation and early stopping techniques.
  • v1.3: Implementation using ResNet and other similar architectures.
  • v2.0: Experimentation with a similar dataset.
  • v3.0: Implementation using Vision Transformer (ViT) architecture.

Dataset Loading

We decided to use the CIFAKE: Real and AI-Generated Synthetic Images

Results

  • Adapted and executed a Kaggle deep learning notebook locally to understand its implementation and results.
  • Preprocessing:
    • CIFake dataset size: ~0.5GB
    • Numpy arrays size: ~2.5GB
    • Processing time: ~1.5min
    • Loading time: ~0.5min
  • Training:
    • Time: ~10min on Nvidia 950m laptop GPU
    • Model size: 0.5MB
  • Testing:
    • Fast loading and prediction
  • Data Augmentation and Early Stopping:
    • Performance was worse than without these techniques
    • Hyperparameter tuning is crucial for optimal performance
  • Fine Tuning:
    • Training ResNet: ~10 hours on laptop, ~6 hours on Colab/Kaggle free-tier
    • results
  • Different Dataset (Missing):
    • todo
  • Vit:
    • Utilized Vision Transformers (ViT) combined with CNNs for weighted fusion.
    • Performance was actually worse than ResNet.

Potential Problems

  • Watermarks: Handling visible and invisible watermarks in images.
  • Image Resizing: Addressing issues from downsizing or upsizing images of different resolutions.
  • Choosing Generated Images: Deciding on images generated by specific models or multiple models, and their relevance.
  • Image Types: Selecting between drawings, specific art styles, photorealistic images, or a combination.
  • Model Performance: Evaluating older/simpler architectures against newer, complex ones.

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages