Eren8705 commited on
Commit
87a9dd8
·
verified ·
1 Parent(s): 5da8a6a

Upload README.md

Browse files
Files changed (1) hide show
  1. README.md +92 -0
README.md ADDED
@@ -0,0 +1,92 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: other
3
+ task_categories:
4
+ - image-classification
5
+ tags:
6
+ - deepfake-detection
7
+ - ai-generated-faces
8
+ - face-classification
9
+ - computer-vision
10
+ - mtcnn
11
+ pretty_name: Real vs. AI-Generated MTCNN-Cropped Faces
12
+ size_categories:
13
+ - 10K<n<100K
14
+ ---
15
+
16
+ # Real vs. AI-Generated MTCNN-Cropped Faces (98,797 Images)
17
+
18
+ This dataset is the curated, MTCNN-cropped binary face classification training pool built for the [face_classification_project](https://github.com/Eren386/face_classification_project) repository.
19
+
20
+ > **Note:** The companion classification project has been **archived / discontinued** due to insufficient training samples for frontier generative models (such as xAI Grok/FLUX and Ideogram). This dataset is published openly so anyone continuing the project or training their own deepfake/AI-face detectors can reuse the compiled 98.7k cropped faces directly.
21
+
22
+ ---
23
+
24
+ ## Archive Contents (98,797 Images Total)
25
+
26
+ All images are pre-cropped tightly around detected faces using **MTCNN (`facenet-pytorch`)** and packaged inside their `ImageFolder` class subdirectories (`fake_faces/` and `real_faces/`).
27
+
28
+ | Archive File | Class Folder Inside | Image Count | Archive Size | Contents |
29
+ | --- | --- | ---: | ---: | --- |
30
+ | `fake_faces.zip` | `fake_faces/` | 36,829 | 1.07 GB (1,100.79 MB) | StyleGAN / TPDNE + StyleGAN3 + Stable Diffusion + Modern AI Collages |
31
+ | `real_faces_celeba.zip` | `real_faces/` | 9,976 | 0.10 GB (100.06 MB) | CelebA-HQ (256x256) studio & celebrity portraits |
32
+ | `real_faces_ffhq_part1.zip` | `real_faces/` | 25,996 | 4.03 GB (4,123.29 MB) | FFHQ (Flickr-Faces-HQ) real portraits — Part 1 of 2 |
33
+ | `real_faces_ffhq_part2.zip` | `real_faces/` | 25,996 | 4.01 GB (4,108.89 MB) | FFHQ (Flickr-Faces-HQ) real portraits — Part 2 of 2 |
34
+ | **Total** | | **98,797** | **9.21 GB** | |
35
+
36
+ ---
37
+
38
+ ## Dataset Composition & Sources
39
+
40
+ ### Real Human Faces (`real_faces/` — 61,968 images)
41
+ - **FFHQ (Flickr-Faces-HQ):** `51,992` MTCNN-cropped everyday human portraits across diverse ages, lighting, and backgrounds.
42
+ - **CelebA-HQ (256x256):** `9,976` MTCNN-cropped studio-lit and celebrity portraits (extracted from a 10,000-image subset) added to fix domain shift on professional photography.
43
+
44
+ ### AI-Generated / Fake Faces (`fake_faces/` — 36,829 images)
45
+ - **GAN Face Collections (StyleGAN / ThisPersonDoesNotExist & Kaggle GAN sets):** `24,514` images (`14,630` numbered + `9,884` UUID files).
46
+ - **StyleGAN3:** `2,001` images (`styleGAN3_*.jpg`).
47
+ - **Stable Diffusion (768px & 1024px):** `5,987` images (`2,987` @ 768px + `3,000` @ 1024px) sourced from Kaggle (`mohannadaymansalah/stable-diffusion-dataaaaaaaaa`) and cropped with MTCNN.
48
+ - **Modern AI Multi-Face Collages:** `4,327` faces (`collage_fake_*.jpg`) extracted via multi-face MTCNN from 44 custom multi-subject collages generated with **ChatGPT (GPT-Image)**, **Google Gemini**, **xAI Grok (FLUX)**, and **Ideogram**.
49
+
50
+ ---
51
+
52
+ ## Quickstart (Download & Train)
53
+
54
+ ```bash
55
+ pip install huggingface_hub
56
+ ```
57
+
58
+ Download all archives into `Data_cropped/` using Python:
59
+
60
+ ```python
61
+ import os
62
+ import zipfile
63
+ from huggingface_hub import hf_hub_download
64
+
65
+ REPO_ID = "Eren8705/real-vs-ai-cropped-faces"
66
+ FILES = [
67
+ "fake_faces.zip",
68
+ "real_faces_celeba.zip",
69
+ "real_faces_ffhq_part1.zip",
70
+ "real_faces_ffhq_part2.zip",
71
+ ]
72
+
73
+ os.makedirs("Data_cropped", exist_ok=True)
74
+ for fname in FILES:
75
+ zip_path = hf_hub_download(repo_id=REPO_ID, filename=fname, repo_type="dataset")
76
+ with zipfile.ZipFile(zip_path, "r") as zf:
77
+ zf.extractall("Data_cropped")
78
+ ```
79
+
80
+ After extraction, `Data_cropped/` will have the exact structure expected by `train.py` in [Eren386/face_classification_project](https://github.com/Eren386/face_classification_project):
81
+
82
+ ```text
83
+ Data_cropped/
84
+ ├── fake_faces/ (36,829 images)
85
+ └── real_faces/ (61,968 images)
86
+ ```
87
+
88
+ ---
89
+
90
+ ## License & Attribution
91
+
92
+ This dataset is a compilation of subsets derived from public academic/community datasets (FFHQ, CelebA-HQ, StyleGAN/StyleGAN3, Stable Diffusion) and custom-generated AI face collages. All original upstream licenses and non-commercial / research terms of the respective source datasets apply (`license: other`).