--- license: other task_categories: - image-classification tags: - ai-generated-image-detection - deepfake-detection - wildfake dataset_info: features: - name: image_bytes dtype: binary - name: split dtype: string - name: group dtype: string - name: category dtype: string - name: source_zip dtype: string - name: source_path dtype: string - name: width dtype: int32 - name: height dtype: int32 - name: condition dtype: string - name: family dtype: string - name: order dtype: string splits: - name: train num_examples: 30000 configs: - config_name: default data_files: - split: train path: data/train-* --- # WildFake-Sample A 30,000-image curated sample drawn from **WildFake** (Hao et al., AAAI 2025, [arXiv:2402.11843](https://arxiv.org/abs/2402.11843); [original dataset](https://modelscope.cn/datasets/hy2628982280/WildFake)), built for evaluating AI-generated-image detectors' generalization to generators and real-image sources they were **not** trained on. Built for [`Buxt-Codes/AIGI-Detection`](https://github.com/Buxt-Codes/AIGI-Detection) (branch `LoRC-PC`) — see that repo's `HANDOFF.md` for the full evaluation methodology and results. **This is a sample, not the full WildFake dataset** (which is ~3.6M images across the same generators). All credit for the underlying images and the dataset's design goes to WildFake's original authors — see their paper and dataset page for licensing/usage terms; this sample exists purely to give a fixed, reproducible evaluation slice across machines/checkpoints without re-downloading from the ~39 multi-GB source archives every time. ## Why this composition The detector this sample was built to evaluate trained on SD-based fakes over COCO real images (DDA-Training-Set) and was previously evaluated on FLUX fakes (SID). This sample deliberately covers generators and real sources **outside** both of those: 26 fake generators spanning GAN-based, diffusion-based (non-SD and SD-family), and other architectures, plus 6 real sources. WildFake's own COCO real split is deliberately excluded here since the detector's training data is COCO-based — including it would risk sampling images already seen in training. ## Composition **Fake — 750 images per generator (19,500 total):** | Category | Generators | |---|---| | GAN-based | BigGAN, StyleGAN, StarGAN, DF-GAN, GALIP, GigaGAN | | Diffusion (non-SD) | ADM, DDPM, DDIM, Imagen, VQDM, DALL-E 2, DALL-E 3, Midjourney v4, Midjourney v5 | | Diffusion (SD family) | SDXL, Original SD, SD+ControlNet, SD+LoRA, SD+LyCORIS, Personalized SD (DreamBooth), Personalized SD (finetune) | | Other | MAGE, VQGAN, VQVAE, MAE | **Real — 1,750 images per source (10,500 total):** LAION-5B, ImageNet, LSUN-Church, FFHQ, AFHQ, CelebA-HQ. Total: **30,000 images** (19,500 fake / 10,500 real). ## Files ``` data/train-*.parquet the dataset itself — 8 shards, one row per image (see columns below) manifest.csv / .json same per-image metadata as the parquet's columns, as plain CSV/JSON, for anyone who wants it without going through `datasets` transform_plan.csv / .json the per-image condition assignment on its own (see below) — a subset of what's in the parquet ``` ### Columns (`data/train-*.parquet`, and equivalently `manifest.csv` joined with `transform_plan.csv` by row) `image_bytes` (binary — the original image file's bytes, unmodified: a PNG regardless of the image's format inside WildFake, since many of the fakes are natively PNG but reals are often JPEG; not JPEG-recompressed at sampling time, so any JPEG compression applied during evaluation is the only lossy step, applied once, consistently), `split` (real/fake), `group` (generator or real-source name), `category` (GAN_based/Diffusion_based/Other_based/ Real), `source_zip` / `source_path` (which WildFake archive and path inside it this image came from), `width`, `height`, `condition` (e.g. "JPEG q=30", "Blur sigma=1.0" — see "Transform assignment" below), `family` (JPEG/Blur/ Resize/Noise/ColorJitter/CenterCrop), `order` (always `transform_first` — the condition is applied to the image, then a final standard q=96 JPEG pass is applied last, standardizing the final encoding every image ends up in regardless of which condition it drew). **Why `image_bytes` is plain binary, not the `datasets` library's `Image` feature type**: `Image` hit two separate bugs on this dataset (a crash in `push_to_hub`'s internal shard-embedding step, and — after working around that — silently-empty bytes from `to_parquet()` skipping the same embedding step instead of erroring). Plain bytes have no such embedding step to break. Decode with: ```python from PIL import Image import io img = Image.open(io.BytesIO(row["image_bytes"])) ``` ### Transform assignment **How it was made** (no randomness, fully reproducible from the manifest alone): within each group independently, images are sorted by pixel area ascending, then cycled round-robin through 14 conditions (JPEG q90/70/50/30, Gaussian blur σ0.5/1.0/2.0, resize 0.5x/0.25x, Gaussian noise σ.02/.05/.10, color jitter, center-crop). Sorting before cycling stratifies the assignment across resolution (any 14 consecutive area-sorted images cover every condition once, so no condition is systematically biased toward small or large images); cycling makes it uniform (every condition gets within 1 image of an even split per group). ## How this was built Sampled from WildFake's ModelScope-hosted archives (several 51–53GB each, some bundling multiple generators together) via HTTP Range requests — reading only each archive's central directory (a listing) plus the exact compressed bytes of the specific images sampled, never downloading an archive in full. First-N selection per generator/source in each archive's own listing order (no random sampling). See `data_prep/build_wildfake_eval.py`, `data_prep/build_wildfake_transform_plan.py`, and `data_prep/push_wildfake_to_hf.py` in the GitHub repo above for the exact code.