TL;DR
OptMark introduces a robust, multi-bit semantic watermarking framework for diffusion models by optimizing watermarks directly within the intermediate latent space during inference. By strategically embedding a structural watermark early in the denoising process and a detail watermark later, it achieves state-of-the-art resilience against both geometric transformations and generative regeneration attacks. Crucially, it leverages the adjoint sensitivity method to reduce optimization memory overhead from $O(N)$ to a constant $O(1)$, making end-to-end inference-time watermarking practically viable.
What Problem Does This Paper Address?
As generative AI tools flood the internet with hyper-realistic imagery, invisible watermarking has become essential for copyright protection and provenance tracking. However, existing methods suffer from a frustrating trade-off:
- Zero-bit watermarks (which only detect if an image is AI-generated) lack the capacity to embed unique user IDs for large-scale tracking.
- Multi-bit watermarks usually operate either at the pixel level or the semantic level. Pixel-level methods are easily erased by "regeneration attacks" (running the image back through a VAE or a diffusion model). Semantic-level methods, which alter the image layout, are often fragile against basic geometric edits like cropping, scaling, or horizontal flipping.
OptMark addresses this gap by proposing an optimization-based approach that embeds high-capacity, multi-bit messages while remaining comprehensively robust against both physical image manipulations and generative AI attacks.
Methods
OptMark optimizes a multi-bit watermark end-to-end during the diffusion model's inference phase. The pipeline consists of two main stages:
1. Dual-Watermark Mechanism
The authors observe that a diffusion model's denoising trajectory transitions from formulating high-level structure to refining low-level details. OptMark exploits this by injecting two distinct learnable watermarks:
- Structure Watermark ($w_s$): Injected at the very first timestep ($t_s = T$). This embeds the watermark into high-level semantic layouts, making it incredibly difficult to erase via generative regeneration attacks.
- Detail Watermark ($w_d$): Injected at a later intermediate step ($t_d \in [200, 300]$). This acts closer to the pixel level, providing robust defense against geometric and valuemetric (color, blur, compression) transformations.
2. Inference-Time Optimization & Adjoint Method
During generation, OptMark optimizes the latent vectors $w_s$ and $w_d$ so that a pre-trained, self-supervised image encoder (DINO) can successfully decode the target $k$-bit message from the final image.
Standard backpropagation through $N$ diffusion steps requires storing the entire computation graph, leading to massive GPU memory consumption ($O(N)$). To solve this, OptMark integrates the Adjoint Sensitivity Method, treating the DDIM sampler as an Ordinary Differential Equation (ODE) solver. This allows gradients to be computed by solving a second, adjoint ODE backward in time, slashing memory usage to a constant $O(1)$.
3. Quality-Preserving Constraints
To ensure the watermark remains invisible, OptMark enforces statistical constraints (mean, variance, skewness, and kurtosis) on the modified latents, keeping them close to a standard Gaussian profile that the diffusion model is trained to handle.
Datasets
- DiffusionDB (Stable-Diffusion-Prompts subset): Used as the source of text prompts to generate 1,000 evaluation images at $512 \times 512$ resolution using StableDiffusion-v2.1.
- MS-COCO-2017: Utilized to evaluate the Fréchet Inception Distance (FID) to measure the quality and fidelity of the watermarked image distribution against real data.
Key Insights and Ideas
- Stage-Aware Vulnerability: The core "aha moment" is realizing that different types of attacks exploit different stages of the diffusion process. Generative attacks destroy fine details but preserve structure; geometric attacks destroy spatial coordinates but preserve local textures. A single watermark cannot easily defend against both, necessitating the dual-stage approach.
- Dynamic Semantics: By analyzing classifier-free guidance noise, the authors proved that fundamental image semantics stabilize after the first few hundred steps, identifying the optimal window ($t \in [200, 300]$) to inject detail watermarks without distorting the prompt's intent.
Key Results
OptMark was evaluated against seven multi-bit baselines (including RivaGAN, SSL Watermark, and Gaussian Shading) across 16 different attack types:
- Robustness: OptMark achieved an average bit accuracy of 98.3% and a True Positive Rate (TPR) of 97.2% at a strict False Positive Rate of $10^{-6}$. It showed no weak spots, outperforming pixel-level methods on regeneration attacks and semantic methods on geometric attacks.
- Image Quality: It maintained exceptional visual fidelity, achieving an FID score of 127.378 (lower/better than SSL Watermark's 128.053) and a CLIP score tightly aligned with unwatermarked baselines.
- Efficiency: Without the adjoint method, optimizing a 30-step diffusion process required 76 GB of GPU memory. OptMark uniformly reduced this to just 9 GB, making it feasible on standard commercial hardware.
Limitations and Future Work
While highly robust, OptMark's performance under heavy generative regeneration attacks is slightly lower than some pure zero-bit semantic watermarking methods (like Gaussian Shading). The authors attribute this to their choice of message decoder (the DINO network), which operates on the final image latent space rather than inverting the image back into the initial noise space.
Future work will focus on exploring alternative extraction spaces—such as utilizing the internal denoising UNet features of the diffusion model itself—to achieve even higher resilience against regeneration.
Summary updated