I-220Micro-Block Artifact Analysis
Detects micro-block boundary artifacts from neural network processing at various grid scales.
Algorithm / Model
Micro-Block Boundary Analysis
How it works
This method detects grid-aligned boundary artifacts produced by neural networks that process images in patches or blocks:\n\n1. Multi-Scale Grid Detection: Neural networks (super-resolution, inpainting, generation) often process images in fixed-size blocks (e.g., 64×64, 128×128, 256×256). At block boundaries, processing discontinuities create subtle artifacts. The method analyzes pixel differences across potential grid lines at scales S ∈ {8, 16, 32, 64, 128, 256}. For each scale, the average absolute difference between pixels at positions (x, S×k) and (x, S×k−1) is computed for all grid lines k. Elevated differences at a specific scale indicate processing at that block size.\n\n2. Frequency-Domain Grid Analysis: The 1D power spectrum of horizontal and vertical cross-sections is computed. Block boundary artifacts create spectral peaks at frequency f = 1/S where S is the block size. The method computes the blockiness metric B(S) = P(1/S) / P̄, where P(1/S) is the spectral power at the grid frequency and P̄ is the average surrounding spectral power. A high B(S) ratio indicates grid artifacts at scale S. This analysis is applied separately to each color channel.\n\n3. Boundary Continuity Analysis: At each potential block boundary, the method fits a 1D polynomial to pixel values on both sides and measures the discontinuity in the function value (0th order), first derivative, and second derivative. Neural network block boundaries typically show 1st or 2nd order discontinuities (smooth pixel values but discontinuous gradients) rather than the 0th order discontinuities seen in JPEG blocking. This distinguishes neural network artifacts from compression artifacts.\n\n4. Spatial Consistency Mapping: The block artifact strength is measured locally across the image, creating a spatial map. In images processed by patch-based neural networks, block artifacts are spatially uniform. In composited images, only the AI-processed region shows block artifacts. The method segments regions with consistent vs. absent block artifacts to localize neural network-processed areas.
Technical Parameters
Grid scales tested: {8, 16, 32, 64, 128, 256} pixels\nSpectral peak significance: B(S) > 1.5 (ratio threshold)\nPolynomial fit order: 3 (cubic)\nBoundary analysis margin: 4 pixels on each side\nSpatial map block size: 32×32 pixels\nMinimum image size: 64×64 pixels
Accuracy & Reliability
83–91% detection accuracy for neural network block artifacts. Grid scale identification is correct in 95% of cases when artifacts are present. Boundary continuity analysis distinguishes neural network from JPEG artifacts with 89% accuracy. Spatial localization of AI-processed regions achieves F1-score of 0.86. Performance is best on uncompressed or losslessly compressed images.
Strengths
• Directly targets a fundamental limitation of patch-based neural networks\n• Frequency-domain analysis reliably detects even subtle grid artifacts\n• Multi-scale approach identifies the specific network architecture by block size\n• Boundary continuity analysis distinguishes AI from compression artifacts\n• Spatial mapping localizes AI-processed regions within composites
Limitations
• Modern architectures using overlap-tile or seamless tiling produce fewer block artifacts\n• JPEG compression at the same block size (8×8) masks neural network grid artifacts\n• Image resizing disrupts grid alignment, reducing detection sensitivity\n• Fully convolutional networks without patch processing produce no block artifacts\n• Very small block artifacts (< 1 pixel intensity difference) may be below noise floor
Use Case
Detecting images processed by patch-based neural networks (super-resolution, denoising, inpainting). Identifying the specific block size used by the neural network architecture. Localizing AI-processed regions in composite images. Distinguishing neural network artifacts from JPEG compression artifacts.