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.

LoRA Deepfake Detector

Self-contained inference package for the LoRA-augmented deepfake detector.

  • Backbone: facebook/dinov3-vith16plus-pretrain-lvd1689m (LoRA on attention projections)
  • Input: RGB image, letterboxed to 512Γ—512
  • Output: prob_fake in [0, 1] β€” label fake if prob_fake >= 0.5

Checkpoints

File Training step Notes
lora_75k.pth 75,000 Default
lora_115k.pth 115,000 Later checkpoint

Both were trained with HUGE_LORA_aug (augmentation on, 512px).

Setup

pip install -r requirements.txt

You must accept the DINOv3 license and be logged in:

huggingface-cli login
# or: export HF_TOKEN=...

Usage

CLI

python infer.py path/to/image.jpg
python infer.py path/to/image.jpg --weights lora_115k.pth --device cuda

Example output:

fake (0.8734)

Python

from lora import Model

model = Model.load(device="cuda")
result = model.predict("photo.jpg", device="cuda")
print(result)  # {"label": "fake", "prob_fake": 0.87}

Model architecture

  1. DINOv3 ViT-H+ with LoRA (r=16, alpha=32) on q/k/v/o_proj
  2. MMFuser β€” multi-layer feature fusion
  3. Head β€” L2-normalized CLS + mean patch tokens β†’ linear β†’ binary softmax

Preprocessing uses aspect-preserving letterbox to 512 (no stretch).

Files

  • lora.py β€” Model class and preprocessing
  • infer.py β€” command-line inference script
  • lora_75k.pth / lora_115k.pth β€” fine-tuned weights (state dict)
  • config.json β€” metadata

Citation

DFKI / GAI Joint project.

Downloads last month
16
Inference Providers NEW
This model isn't deployed by any Inference Provider. πŸ™‹ Ask for provider support