Explainable Deepfake Detection — project checkpoints
Real/fake face classifiers from the thesis project Explainable Deepfake Detection using Vision Transformer.
All files are PyTorch checkpoints {'epoch', 'model_state', 'optimizer_state'}; label 0 = real, 1 = fake; input = 224×224 MTCNN face crop, ImageNet-normalised.
| File | Architecture | Training data |
|---|---|---|
model.pt | ViT-B/16 (timm vit_base_patch16_224) | FaceForensics++ c23 + Celeb-DF-v2 |
freqfusion_model.pt | Dual-branch spatial-frequency ViT | FaceForensics++ c23 + Celeb-DF-v2 |
xception_model.pt | Xception (timm legacy_xception) | FaceForensics++ c23 + Celeb-DF-v2 |
ffpp_only_model.pt | ViT-B/16 | FaceForensics++ c23 only |
celebdf_only_model.pt | ViT-B/16 | Celeb-DF-v2 only |
custom/*_custom.pt | same five architectures | the file above it, fine-tuned on a custom set of AI-generated portrait re-renders (293 train crops) with replay of the original domain |
Custom-data fine-tuned checkpoints (custom/)
| File | Custom test acc / ROC-AUC (n=64) | Original in-domain acc (n=3000 subset) |
|---|---|---|
custom/model_custom.pt | 0.844 / 0.898 (was 0.500 / 0.502) | 0.969 (was 0.973) |
custom/freqfusion_model_custom.pt | 0.797 / 0.879 (was 0.469 / 0.495) | 0.969 (was 0.974) |
custom/xception_model_custom.pt | 0.844 / 0.934 (was 0.453 / 0.465) | 0.952 (was 0.971) |
custom/ffpp_only_model_custom.pt | 0.875 / 0.929 (was 0.484 / 0.452) | 0.961 (was 0.970) |
custom/celebdf_only_model_custom.pt | 0.875 / 0.977 (was 0.500 / 0.429) | 0.960 (was 0.982) |
custom/custom_finetune_results.json holds every metric and per-epoch history; custom/custom_manifest.csv is the identity-disjoint split of the custom set.
from huggingface_hub import hf_hub_download
import timm, torch
ckpt = torch.load(hf_hub_download("mahedi420/deepfake-vit-detector", "custom/model_custom.pt"), map_location="cpu")
model = timm.create_model("vit_base_patch16_224", pretrained=False, num_classes=2)
model.load_state_dict(ckpt["model_state"]); model.eval()