DOI: 10.3390/electronics15215150 ISSN: 2079-9292

A Self-Recovery Fragile Watermarking Scheme Based on Vector-Quantized Variational Autoencoder Codebook Indices

Chin-Feng Lee, Shao-Ting Huang, Sue-Chen Hsueh, Yung-Chen Chou

Face images are widely used in recognition, social media, and digital evidence, so tampering can undermine trust. This study proposes a blind tamper detection and self-recovery method for aligned, grayscale CelebA face images. A vector-quantized variational autoencoder (VQ-VAE) turns each image into a discrete codebook index map, which is scrambled, redundantly embedded by 2-LSB substitution, and recovered at verification by position-wise mode voting; a feature-consistency mask and a pixel-residual mask then localize tampering and guide fusion-based restoration. Watermark embedding introduces negligible distortion (whole-image average PSNR 44.19 dB, SSIM 0.985). On 23 test images, F1-scores are close to 1 for large-area contiguous tampering and image splicing at tampered-area ratios up to 80%, whereas salt-and-pepper noise lowers precision. Whole-image average recovery PSNR/SSIM is 30.96 dB/0.918 and 20.50 dB/0.699 under 40% and 80% large-area tampering (30.95 dB/0.919 and 20.36 dB/0.689 for splicing); these values are influenced by the intact pixels retained during fusion and do not measure tampered-region fidelity. The results apply to accidental corruption and uninformed tampering; benign processing such as JPEG compression or resizing is treated as tampering. VQ-VAE codebook indices thus serve as embeddable, bit-exact self-recovery information recoverable by mode-based voting.

More from our Archive