How to use from the
Use from the
Transformers library
# Gated model: Login with a HF token with gated access permission
hf auth login
# Use a pipeline as a high-level helper
from transformers import pipeline

pipe = pipeline("image-classification", model="buildborderless/CommunityForensics-DeepfakeDet-ViT")
pipe("https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/hub/parrots.png")
# Load model directly
from transformers import AutoImageProcessor, AutoModelForImageClassification

processor = AutoImageProcessor.from_pretrained("buildborderless/CommunityForensics-DeepfakeDet-ViT")
model = AutoModelForImageClassification.from_pretrained("buildborderless/CommunityForensics-DeepfakeDet-ViT")
Quick Links

You need to agree to share your contact information to access this model

This repository is publicly accessible, but you have to accept the conditions to access its files and content.

Log in or Sign Up to review the conditions and access this model content.

NOTICE: 7/14/2026

  • We have received multiple reports in the past few months regarding the misuse of this model and its license. For the time being until we can figure out a better solution, the model will temporarily be set to gated mode.
  • We encourage all to review the MIT License: the Community Forensics detection model can be forked, distributed, and utilized for use in for-profit operations, but attribution must be given.
  • Attribution details can be found below under "Citation" for the model. For the transformers implementation, a simple awknowledgement to Borderless would be appreciated.

Trained on 2.7M samples across 4,803 generators (see Training Data)

Model presented in Community Forensics: Using Thousands of Generators to Train Fake Image Detectors.

Uploaded for community validation as part of OpenSight - An upcoming open-source framework for adaptive deepfake detection.

Project OpenSight HF Spaces coming soon with an eval playground and eventually a leaderboard. Preview:

image/png

Model Details

Model Description

Vision Transformer (ViT) model trained on the largest dataset to-date for detecting AI-generated images in forensic applications.

  • Developed by: Jeongsoo Park and Andrew Owens, University of Michigan
  • Model type: Vision Transformer (ViT-Small)
  • License: MIT (compatible with CreativeML OpenRAIL-M referenced in [2411.04125v1.pdf])
  • Finetuned from: timm/vit_small_patch16_384.augreg_in21k_ft_in1k
  • Adapted for HF inference compatibility by Borderless.

HF Space will be open sourced shortly showcasing various ways to run ultra-fast inference. Make sure to follow us for updates, as we will be releasing a slew of projects in the coming weeks.

Links

Training Details

Training Data

  • 2.7mil images from 15+ generators, 4600+ models
  • Over 1.15TB worth of images

Training Hyperparameters

  • Framework: PyTorch 2.0
  • Precision: bf16 mixed
  • Optimizer: AdamW (lr=5e-5)
  • Epochs: 10
  • Batch Size: 32

Evaluation

Unverified Testing Results

  • Only unverified because we currently lack resources to evaluate a dataset over 1.4T large.
Metric Value
Accuracy 97.2%
F1 Score 0.968
AUC-ROC 0.992
FP Rate 2.1%

image/png

Re-sampled and refined dataset

  • Coming soonβ„’

Citation

BibTeX:

@misc{park2024communityforensics,
    title={Community Forensics: Using Thousands of Generators to Train Fake Image Detectors}, 
    author={Jeongsoo Park and Andrew Owens},
    year={2024},
    eprint={2411.04125},
    archivePrefix={arXiv},
    primaryClass={cs.CV},
    url={https://arxiv.org/abs/2411.04125}, 
}
Downloads last month
579,825
Safetensors
Model size
36M params
Tensor type
F32
Β·
Inference Providers NEW

Model tree for buildborderless/CommunityForensics-DeepfakeDet-ViT

Finetuned
(1)
this model
Quantizations
2 models

Spaces using buildborderless/CommunityForensics-DeepfakeDet-ViT 18

Collection including buildborderless/CommunityForensics-DeepfakeDet-ViT

Paper for buildborderless/CommunityForensics-DeepfakeDet-ViT