Skip to main content
QUICK REVIEW

[Paper Review] CIFAKE: Image Classification and Explainable Identification of AI-Generated Synthetic Images

Jordan J. Bird, Ahmad Lotfi|arXiv (Cornell University)|Mar 24, 2023
Explainable Artificial Intelligence (XAI)Computer Science13 citations
TL;DR

The paper creates CIFAKE, a 120k-image CIFAR-10–sized dataset with real and SDM-generated images, trains CNNs to classify Real vs Fake with ~92.98% accuracy, and uses Grad-CAM for explanations.

ABSTRACT

Recent technological advances in synthetic data have enabled the generation of images with such high quality that human beings cannot tell the difference between real-life photographs and Artificial Intelligence (AI) generated images. Given the critical necessity of data reliability and authentication, this article proposes to enhance our ability to recognise AI-generated images through computer vision. Initially, a synthetic dataset is generated that mirrors the ten classes of the already available CIFAR-10 dataset with latent diffusion which provides a contrasting set of images for comparison to real photographs. The model is capable of generating complex visual attributes, such as photorealistic reflections in water. The two sets of data present as a binary classification problem with regard to whether the photograph is real or generated by AI. This study then proposes the use of a Convolutional Neural Network (CNN) to classify the images into two categories; Real or Fake. Following hyperparameter tuning and the training of 36 individual network topologies, the optimal approach could correctly classify the images with 92.98% accuracy. Finally, this study implements explainable AI via Gradient Class Activation Mapping to explore which features within the images are useful for classification. Interpretation reveals interesting concepts within the image, in particular, noting that the actual entity itself does not hold useful information for classification; instead, the model focuses on small visual imperfections in the background of the images. The complete dataset engineered for this study, referred to as the CIFAKE dataset, is made publicly available to the research community for future work.

Motivation & Objective

  • Motivate the need to detect AI-generated images to ensure data authenticity and trustworthiness.
  • Create a synthetic dataset (CIFAKE) mirroring CIFAR-10 with real and AI-generated images.
  • Develop CNN-based classifiers to distinguish Real vs Fake images.
  • Incorporate Explainable AI (Grad-CAM) to interpret model decisions on image features.

Proposed method

  • Generate synthetic CIFAKe dataset using Stable Diffusion 1.4 with 10 CIFAR-10 classes and domain-specific prompts to diversify images.
  • Train 36 CNN topologies by varying feature extractor filters and dense layer sizes to identify the best Real vs Fake classifier.
  • Evaluate models using binary classification metrics (accuracy, precision, recall, F1) on a 50k/50k train and 10k/10k test split.
  • Apply Grad-CAM to produce spatial heatmaps highlighting image regions influential to Real vs Fake decisions.
  • Provide public CIFAKE dataset release for community research.
Figure 1: Examples of images from the CIFAR-10 image classification dataset [ 24 ] .
Figure 1: Examples of images from the CIFAR-10 image classification dataset [ 24 ] .

Experimental results

Research questions

  • RQ1Can a CNN reliably distinguish high-quality AI-generated images from real CIFAR-10 images?
  • RQ2Which CNN topology (feature extractor and dense layers) yields the best binary classification performance for Real vs Fake in CIFAKE?
  • RQ3What visual cues, if any, do Grad-CAM explanations reveal as most influential in the classification decision?

Key findings

  • Best feature extractor topology: two layers of 128 filters yielded 92.98% validation accuracy with a 0.221 loss.
  • Overall average validation accuracy across feature extractors was 91.79%.
  • Highest F1-score observed was 0.936 when using a single dense layer of 64 neurons.
  • Grad-CAM analysis shows real images rely on holistic image regions, while fake images rely on sparse, localized areas with potential visual imperfections.
  • CIFAKE dataset comprises 120,000 images (60,000 real from CIFAR-10 + 60,000 synthetic) and is publicly released.
  • Classification experiments were conducted on a 50k/50k real/synthetic training split and 10k/10k testing split.
Figure 2: Examples of AI-generated images within the dataset contributed by this study, selected at random with regards to their real CIFAR-10 equivalent labels.
Figure 2: Examples of AI-generated images within the dataset contributed by this study, selected at random with regards to their real CIFAR-10 equivalent labels.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.