/ Модель

Характеристики

Лицензия
CC BY-NC-SA 4.0
Базовая модель
dinov2-base
Библиотека
pytorch
Опубликована
25 окт 2026

dfd-detector

Классификация изображенийИзображение → label3 профессии

Исследовательский набор детекторов для классификации синтетических изображений, сгенерированных лиц и подмены лиц в видео с возможностью воздержаться и направить результат на проверку.

0скачиваний за 30 дней0лайковвеса обновлены25 окт 2026

Бенчмарки

Как модель справилась с задачами пользователей ailist и что о ней публикуют открытые лидерборды

Публичные оценки

Из открытых лидербордов. Сравнивайте результаты одного теста при одинаковых условиях — отсутствие оценки не значит, что модель хуже.

В подключённых источниках результатов для этой модели пока нет.

Что умеет модель

Описание составлено по карточке модели и метаданным Hugging Face

Набор из трёх исследовательских детекторов синтетических изображений и дипфейков, разработанный как демонстрационный проект. Модели построены на замороженной основе DINOv2-base с LoRA-адаптерами и классификационными головами; видеодетектор дополнительно учитывает признаки восьми кадров клипа. Репозиторий содержит веса адаптеров и голов, калибровочные пороги и отчёты. Лицензия — CC BY-NC-SA 4.0.

Модели предназначены для выявления целиком сгенерированных изображений, лиц, созданных текстовыми генераторами, и подмены лиц в видео. Калибровка предусматривает три исхода: «подделка», «оригинал» или «воздержание» с передачей случая на проверку. Видеодетектор анализирует временно выбранные кадры с лицами; весь набор ориентирован на исследования и демонстрации устойчивого к обработке соцсетями выявления подделок.

Результаты заметно различаются между сценариями и наборами данных. Доля воздержаний составляет примерно 42–83%; отдельные оценки получены в одном запуске. Детектор лиц не предназначен для обнаружения подмены лиц в отдельных изображениях, а качество на реальных видеоподменах и анимации говорящих голов ограничено. Возможны ошибки на новых генераторах и на материалах из реальных условий; решения требуют проверки человеком и не подходят для автоматических санкций, юридических, журналистских или идентификационных выводов.

Сценарии применения

  • проверка изображения на синтетическую генерацию
  • выявление лиц, созданных текстовыми генераторами
  • поиск подмены лица в видео
  • триаж подозрительных изображений и видеоклипов с передачей неопределённых случаев человеку

Ограничения

Доля воздержаний высока, а качество зависит от типа генерации и условий данных; калибровка на отобранных наборах не гарантирует целевой уровень ошибок в реальных условиях. Детектор сгенерированных лиц не распознаёт надёжно подмены лиц, а видеодетектор не предназначен для анимации говорящих голов; результаты требуют проверки человеком.

Для каких профессий подходит3

Разделы каталога профессий, в задачах которых используется эта модель

Все профессии

Карточка модели

README от автора на Hugging Face, как он его опубликовал

Открыть на Hugging Face

DFD research detectors (general image, AI-face, face-swap video)

Three calibrated deepfake / AI-generated-media detectors from a research demo, served together behind a conservative router. Research use only. Not for enforcement decisions. Uncertain cases are meant to go to human review, and every model here sends a large share of inputs there by design.

FolderWhat it detectsInput
general_all/AI-generated / synthetic whole imagesimage (224 px centre crop)
face_t2i_b3/AI-generated (text-to-image) faceslargest detected face, 1.8x square crop
video_v3/Face-swap videos8 time-sampled face crops per clip (YuNet, 1.3x square)

Each folder holds best.pt (LoRA + head weights only; the frozen backbone is facebook/dinov2-base), calibration.json (temperature + split-conformal thresholds), config.yaml, and the training/eval reports.

Architecture

  • Backbone: DINOv2-base (frozen) with LoRA (rank 8) on the last 3 blocks; features = layer-normed CLS + mean patch token from layers 4, 8, 10, 12.
  • Head: variational information bottleneck (latent 128) + linear classifier.
  • Video: a temporal adapter over per-frame features, 8 frames per clip.
  • Training augmentation: platform transcoding emulation (resize, JPEG/WebP re-compression, blur, noise, colour jitter, beauty-filter simulation) to survive social-media processing.
  • Calibration: temperature scaling + split-conformal thresholds fit only on a held-out calibration split (target FPR 1%, per-generator FNR 2%). Output is three-way: fake (p >= tau_fake), real (p < tau_real), otherwise abstain (route to review). If the calibration file is missing or was fit for a different crop mode, every verdict must be treated as abstain.

Results

All numbers come from the reports in this repo or the project build log. "Single run" means one training run with no confidence interval.

general_all (Tiny-GenImage, all 7 generators)

  • Generalization is measured with the same recipe under nested leave-one-generator-out (7 rotations; the test generator is never seen in training): mean AUC 0.915, mean TPR@1%FPR 0.42; conformal FPR / FNR / abstain about 1.2% / 6.6% / 45%. The weakest unseen generator is Midjourney (AUC 0.741).
  • This exact checkpoint is trained on all 7 generators, so its own validation numbers are in-distribution (7,000 images): AUC 0.963, TPR@1%FPR 0.61, conformal FPR 0.97%, abstain 42%. [single run]
  • A pre-registered ablation (attention-MIL patch pooling) did not improve generalization (mean dAUC -0.0002, 95% CI [-0.0028, +0.0023]).

face_t2i_b3 (AI-generated faces)

Trained on DeepFakeFace (IMDB-WIKI reals with SD1.5 / inpainting / InsightFace fakes), SFHQ-T2I (SDXL; DALL-E 3 used only for checkpoint selection) and FFHQ real portraits. Flux was held out entirely. [single run]

  • Held-out Flux: AUC 0.988, TPR@1%FPR 0.85; SFHQ-val Flux dev / pro / schnell caught 86% / 91% / 93%.
  • FairFace (10,954 real faces): FPR 0.58% overall, review burden 18.7%. Worst race: Middle Eastern 0.99%; worst race x gender: Middle Eastern male 1.35%; ages 0-2 / 3-9: 0.5% / 0.4%. No race group is significantly above 1% (exact binomial + Holm); Wilson 95% CIs are in eval_external_fairface.json.
  • Not a face-swap detector: WildDeepfake frames are at chance (AUC 0.53) and 41% of in-the-wild face-swap frames get a confident real. In-the-wild real-face FPR is 2.4% on WildDeepfake, above the 1% target.

video_v3 (face-swap video; WildDeepfake + Celeb-DF v2)

Warm-started from an earlier WildDeepfake-only model; Celeb-DF fakes capped at 2:1 per target identity. Checkpoint chosen on validation only; each test split scored once. [single run]

Test splitAUCTPR@1%FPRReal called fakeFake called realAbstain
WildDeepfake official test (806 clips)0.8770.2830.5%1.0%75.4%
Celeb-DF v2 official test list (518 clips)0.8450.1711.1%0.0%83.4%
Talking-head animation (TalkingHeadBench) vs CelebV-HQ reals (1,179)0.4410.0070.0%41.4%60.4%
  • Celeb-DF's official split shares swapped-in identities with train, so part of the Celeb-DF score is in-domain.
  • Does not detect talking-head animation (below-chance AUC; 41% of those fakes score real).

Intended use and how it is served

Research and demonstration of calibrated, abstaining deepfake detection under social-media processing. In the demo, a router runs the general detector on the whole image and the face detector on the largest face (at least 64 px and 1% of the image). Videos also get the clip model when a face is found in at least half the sampled frames. Fusion is conservative: fake if any specialist says fake; real only if every specialist that ran says real; otherwise review. Fusing can only raise the false-positive rate (up to about the sum of the specialists' FPRs).

Out of scope

  • Automated takedowns, legal, journalistic or identity decisions; any use without human review.
  • Talking-head / audio-driven animation, modern text-to-video (Sora/Kling/Wan-class), audio deepfakes.
  • Real-world face swaps in still images (no model here handles them).
  • Commercial use (see licences).

Training data and licences

DataUseLicence / terms
Tiny-GenImage (TheKernel01/Tiny-GenImage)general modelCC-BY-NC-SA 4.0
DeepFakeFace (OpenRL/DeepFakeFace)face modelApache-2.0; IMDB-WIKI reals research-only
SFHQ-T2Iface modelMIT (source repository)
FFHQ (gaunernst/ffhq-1024-wds)face modelCC-BY-NC-SA 4.0
WildDeepfakevideo modelApache-2.0
Celeb-DF v2video modelnon-commercial research only, no redistribution, citation required
FairFace, TalkingHeadBench, CelebV-HQevaluation onlyCC-BY 4.0 / MIT / research terms

Because several sources are non-commercial (and FFHQ / Tiny-GenImage are ShareAlike), these weights are released under CC-BY-NC-SA 4.0 and must not be used commercially. No dataset media is redistributed here.

Usage

The inference code (dfd package: dfd.inference.pipeline.DetectionPipeline, dfd.inference.router.MultiDetector / VideoClipScorer) lives in the project repository.

from dfd.inference.pipeline import DetectionPipeline
from PIL import Image

pipe = DetectionPipeline("general_all/best.pt", None, "auto", crop_mode="center")  # reads calibration.json beside it
res = pipe.score_pil(Image.open("photo.jpg").convert("RGB"))
print(res.verdict, res.p_fake)  # "fake" / "real" / "abstain"

Checkpoints load with torch.load(..., weights_only=True); they contain only tensors and plain metadata.

Limitations

  • Most face and video results are single runs; only the image LOGO protocol has spread across rotations.
  • Abstention is high (42-83%), which is the price of the 1% FPR target.
  • Calibration was fit on curated datasets; in-the-wild real content (low-resolution, re-compressed video faces) can exceed the 1% FPR target, as WildDeepfake real faces show for the face model (2.4%).
  • New generators appear constantly; thresholds need recalibration and the models need retraining.

Как запустить

На своей GPU в ailist. Цена — по текущим предложениям провайдеров

GPU в ailist

Универсальный рантайм · pytorch · image-classification

Нельзя запустить

В репозитории нет config.json: не понять архитектуру модели.

Ревизия весов
2291c3c

0 моделей