V-168Frame Duplication Detection

Pixel Analysisvideo2015

Detects duplicated or near-duplicated frames indicating temporal manipulation or AI generation loops.

Video Frame Duplication Forensics
This method detects video tampering by identifying frames that have been duplicated, removed, or reordered — a common technique in both traditional video editing fraud and AI-generated video content:\n\n1. Perceptual Hashing for Fast Frame Matching: Every frame is compressed into a compact perceptual hash — a 64-bit DCT-based hash (pHash) that captures the visual structure while being robust to minor quality variations. The method computes pairwise Hamming distances between all frame hashes. Authentic video has smoothly changing hashes with Hamming distance proportional to temporal separation. Duplicated frames produce exact or near-exact hash matches (Hamming distance ≤ 3) at non-adjacent temporal positions. The method also detects near-duplicates — frames that are identical except for minor modifications (slight crop, brightness adjustment, noise addition) used to disguise the duplication.\n\n2. Temporal Correlation Matrix Analysis: The method constructs a frame-by-frame correlation matrix using SSIM (Structural Similarity Index) between all frame pairs. In authentic video, the correlation matrix has a characteristic banded structure — high SSIM near the diagonal (adjacent frames are similar) decaying smoothly with temporal distance. Frame duplication creates off-diagonal high-SSIM blocks that break this banded structure. The method detects these anomalous blocks using a sliding window analysis: for each frame, the method identifies all frames with SSIM > 0.95 and checks whether their temporal positions are consistent with natural video motion (they should be temporally adjacent, not separated by large gaps).\n\n3. Optical Flow Discontinuity Detection: Between consecutive frames connected by genuine camera motion, the optical flow field should be spatially smooth and temporally consistent. At frame duplication boundaries (where a duplicated segment begins or ends), the optical flow exhibits discontinuities: (a) sudden changes in flow magnitude or direction at the splice point, (b) inconsistent motion between the duplicated segment and surrounding original frames, (c) zero or near-zero optical flow within a duplicated static segment followed by sudden motion resumption. The method uses Farneback dense optical flow and computes the frame-to-frame flow magnitude histogram to detect these temporal discontinuities.\n\n4. Sensor Noise Pattern Temporal Analysis: Camera sensor noise (PRNU — Photo Response Non-Uniformity) creates a device-specific fingerprint present in every frame. The method extracts noise residuals using the wavelet-based denoising approach of Lukas et al. (2006) and tracks the noise pattern correlation across frames. Authentic video maintains consistent PRNU correlation. Frame duplication from a different segment of the same video shows correct PRNU (same camera) but inconsistent scene noise statistics. Frame insertion from a different source shows PRNU discontinuities or different sensor fingerprints at the splice point.
Perceptual hash: pHash algorithm, 64-bit DCT hash\nDuplication threshold: Hamming distance ≤ 3 bits\nSimilarity metric: SSIM with threshold > 0.95 for near-duplicate\nOptical flow: Farneback method (pyramid scale 0.5, 5 levels)\nFlow discontinuity threshold: > 3σ from local mean\nPRNU extraction: wavelet denoising (Daubechies-4, level 4)\nMinimum duplicate segment: 3 consecutive frames\nAnalysis resolution: 640×360 (downscaled for efficiency)\nBatch processing: 1000-frame windows with 100-frame overlap
88–95% accuracy detecting frame duplication in uncompressed and lightly compressed video. pHash matching achieves precision of 0.96 for exact duplicates. SSIM correlation matrix analysis detects near-duplicates with F1-score of 0.91. Performance decreases with heavy re-encoding (multiple compression generations reduce SSIM of duplicated frames). Optical flow analysis is most effective for detecting splice boundaries.
• Perceptual hashing enables efficient search across long videos\n• SSIM correlation matrix reveals duplication patterns visually\n• Optical flow discontinuity detects splice points even with re-encoding\n• PRNU analysis can identify frames from different sources\n• Works for both exact duplicates and near-duplicates with modifications
• Heavy re-compression degrades frame similarity and hash accuracy\n• Natural repetitive content (e.g., looping machinery) may produce false positives\n• Very short duplicated segments (1–2 frames) are difficult to distinguish from natural pauses\n• AI video generation may not use explicit frame duplication — produces novel frames\n• Computational cost scales quadratically with video length for full pairwise analysis
Detecting video temporal tampering by frame duplication or removal. Forensic analysis of surveillance footage for evidence authentication. Detecting AI video generation loops where content repeats cyclically. Identifying video editing fraud in security and legal contexts.