Modern lossy compressors aimed at realism make outputs look like real data instead of blurry averages. Many of them rely on dither: random noise that the encoder and decoder both know, added before quantization and removed afterwards. Theory and experiments agree that this shared randomness is not optional. Deterministic encoders fail to meet realism constraints at low bitrates, and removing common randomness costs a 3 dB penalty under strong realism. If the compressed stream must also stay secret from an eavesdropper, a second kind of randomness enters the system: a key. The natural engineering reflex is to treat all of it as key material, drawn from a certified physical source and processed by a randomness extractor (a function that turns biased, partly predictable physical bits into nearly uniform ones). The extractor must also be safe against an adversary who stores quantum side information and measures it only after the protocol is public.
This note argues that the reflex is wasteful, and that the waste is largest exactly where perceptual codecs are most interesting. In a nested-lattice dithered codec, the randomness needed for realism and the randomness needed for secrecy separate cleanly. The realism dither only has to be independent of the source. It can be public, or even fully known to the eavesdropper. Only a one-time pad on the discrete quantization index has to be extracted against quantum side information, and its length is set by smooth conditional min-entropy. At ultra-low bitrates the dither rate can exceed the message rate; the quantized-dither codec of Optimal Neural Compressors for the Rate-Distortion-Perception Tradeoff uses 1.58 bits per dimension of dither. In that regime the split more than halves the secret-bit budget. We also propose to measure what an eavesdropper can reconstruct when the key is shorter than the message, scoring her with the same distortion and realism metrics used for the legitimate receiver.
Core Claim
Let $X$ be the source, $\Lambda_f \subset \mathbb{R}^n$ the quantization lattice, and $\Lambda_c \subset \Lambda_f$ a coarse sublattice whose cells index the message. The message rate is then $R = \frac{1}{n}\log|\Lambda_f/\Lambda_c|$ bits per dimension. The codec sends the index $Q_f(X + U) \bmod \Lambda_c$, where $Q_f$ rounds to the nearest point of $\Lambda_f$ and $U$ is the realism dither. Add a key $K$ that is uniform over the quotient $\Lambda_f/\Lambda_c$, so that $n R$ bits of key cover each block. The transmitted symbol becomes
$$M = \big(Q_f(X+U) + K\big) \bmod \Lambda_c .$$
Given $U$ and $X$, this is uniform; this is the discrete form of the lattice "crypto lemma." The eavesdropper's view of $(M, U)$ is therefore independent of $X$ whenever $K$ is uniform given everything she holds, including her quantum register $E$. Two facts follow. Bob's realism, meaning how closely the distribution of his reconstructions matches the true data distribution, depends only on $U$ being uniform and independent of $X$. Secrecy depends only on $K$ being close to uniform conditioned on $E$.
Suppose $K$ is produced by two-universal hashing of a weak physical string $W$. Leftover Hashing Against Quantum Side Information then bounds the trace distance of $K$ from an ideal key by $\frac{1}{2}\sqrt{2^{\,l - H_{\min}^{\epsilon}(W|E)}} + \epsilon$, where $l = nR$ is the key length and $H_{\min}^{\epsilon}(W|E)$ is the smooth conditional min-entropy of $W$ given Eve's register. Trace distance bounds Eve's advantage at every task. Her best reconstruction, under any distortion measure and any realism divergence, is therefore within that distance of what she could achieve from the prior alone.
The total secret randomness is $nR$ bits per block rather than $n(R + R_c)$, where $R_c$ is the dither rate. The dither can come from a public source, or from an extractor sized only by the unconditional entropy $H_{\min}(W)$.
The non-trivial part is the regime where the key is shorter than $nR$. Here we pad only the coarse levels of a nested chain $\Lambda_c \subset \Lambda_m \subset \Lambda_f$. Our prediction is that Eve then holds the source modulo $\Lambda_m$: fine texture without coarse structure. Her reconstructions should be locally realistic but have high distortion. That is a new and measurable "eavesdropper perception-distortion curve" indexed by key rate.
Relation to Prior Work
The proposal reuses its coding machinery from the dithered rate-distortion-perception literature. Optimal Neural Compressors for the Rate-Distortion-Perception Tradeoff shows that lattice transform coding with shared dither matches the Gaussian rate-distortion-perception bound and that quantized shared dither with nesting ratio 3 needs 1.58 bits per dimension. Universal Rate-Distortion-Perception Representations for Lossy Compression shows that a distortion-optimized encoder can be steered along the realism frontier at the decoder using dither.
Both papers assume ideal, non-secret seeds. We keep their codecs and ask which part of their randomness must be secret.
The case that shared randomness is necessary comes from two results. Rate-Distortion-Perception Trade-off with Strong Realism Constraints: Role of Side Information and Common Randomness shows that common randomness removes a 3 dB penalty under strong realism. The Rate-Distortion-Perception Trade-off: The Role of Private Randomness shows that encoder private randomness is useless below source entropy. Both treat randomness only as a coding resource, never as a secret against an adversary.
The extraction side is constrained by negative results. Exponential separations for one-way quantum communication complexity, with applications to cryptography exhibits an extractor that is secure against classical observers but broken by a small quantum memory. Two-Source Extractors Secure Against Quantum Adversaries shows a factor-of-two loss when the adversary holds entangled storage. Together these rule out sizing the key by classical entropy accounting.
Two further papers supply deployable extractors. The quantum leftover hash lemma provides the key extractor. Real-time seedless post-processing for quantum random number generators provides a seedless option that runs at 64 Gbps on an FPGA, but only against product side information and only for min-entropy rates above 1/2. This proposal does not claim new extractor constructions.
Research Program
The first strand is analytical. We will state the two-role decomposition for nested-lattice codecs with shared dither, prove the eavesdropper's leakage bound from the quantum leftover hash lemma, and characterize the partial-key regime for Gaussian sources. For the Gaussian case we will derive Eve's minimum distortion given the source modulo an intermediate lattice $\Lambda_m$, and her realism gap in terms of the second moment of $\Lambda_m$'s cell. We expect closed forms for the Gaussian case, because the residue modulo a lattice of a Gaussian vector has a computable distribution.
We will also say explicitly what is not claimed. The decomposition applies to dither-based codecs. It does not apply to diffusion codecs whose randomness enters nonlinearly, such as Towards image compression with perfect realism at ultra-low bitrates, for which we will only test empirically.
The second strand is a simulation harness. The weak sources are biased and correlated bit models whose parameters are fitted to the published characterizations of DRAM metastability and memristor switching. For quantum side information, we build small classical-quantum toy states in which Eve holds a few qubits correlated with $W$. Her guessing probability, and hence $H_{\min}(W|E)$, can then be computed exactly by semidefinite programming. We also include a Raz-style instance in which classical entropy accounting overestimates the extractable key.
Baselines
The naive reference is SD-LTC as published, with seeds from an ordinary pseudo-random generator and no secrecy at all. It fixes Bob's distortion-perception curve, which every secure variant must reproduce. A secure variant fails if it moves Bob's curve by more than the run-to-run spread of the naive codec. For this baseline the file reports that SD-LTC "perfectly matched the theoretical RDP lower bound" on 8-dimensional Gaussians, and that a dither nesting ratio of 3 needs 1.58 bits per dimension (Optimal Neural Compressors for the Rate-Distortion-Perception Tradeoff). No reported scalar distortion or realism values were found on Lacuna for MNIST, speech, or physics data.
The strongest secure competitor is "everything secret." The key and the dither are both extracted from $W$ by one quantum-proof hash, with total length $n(R+R_c)$. It is the default a careful practitioner would build and is secure by the same lemma. We run it with the same codec weights, the same weak-source model, and the same smoothing parameter $\epsilon$. Our split beats it if it reaches the same Bob curve and the same leakage bound while consuming fewer extracted secret bits. Because the saving is exactly the dither length, we predict it at $R_c$ bits per dimension, for example 1.58 bits per dimension at nesting ratio 3. We will report this fraction against message rate on each dataset.
A computational baseline completes the picture: AES-encrypted bitstream with pseudo-random dither. It is reported for context on Bob's quality and throughput, not on information-theoretic secrecy.
The ablations isolate the key ingredient. In the first, raw unextracted weak bits drive the dither while the pad stays properly extracted; this tests the claim that realism needs only independence and near-uniformity, so mild bias should cost little. In the second, a properly extracted dither is paired with a pad whose length is set by classical min-entropy on the Raz-style toy instance. We expect Eve's advantage there to exceed the bound, which shows the quantum accounting is necessary rather than decorative.
Why not just…?
Why not just encrypt the bitstream with AES and generate dither from a pseudo-random generator? For many deployments this is the right answer, and we say so. It gives only computational security. Against an adversary who stores ciphertext now and attacks later, the guarantee depends on unproven hardness assumptions. Our question is information-theoretic: how many certified secret bits a realism codec actually needs. That count matters exactly when computational assumptions are unacceptable. The AES baseline is included to show that our scheme does not degrade Bob's quality relative to it.
Why not just drop shared dither and use only decoder-side private noise, so that secrecy reduces to encrypting the index? This is a real alternative, and it also needs only $nR$ secret bits. It pays in reconstruction quality instead. Rate-Distortion-Perception Trade-off with Strong Realism Constraints: Role of Side Information and Common Randomness proves a 3 dB penalty without common randomness. Optimal Neural Compressors for the Rate-Distortion-Perception Tradeoff reports that deterministic encoders fail realism at low bitrates. We will run a private-decoder-noise codec at matched secret-bit budget. Our claim is that public dither recovers the shared-randomness curve for free. If the measured gap is small on real data rather than Gaussians, the practical case for our split weakens to the Gaussian regime.
Why not just hash the physical source with a simple two-universal function sized by its classical min-entropy? Why Simple Hash Functions Work: Exploiting the Entropy in a Data Stream justifies this against classical observers. For the pad, however, the separation of Exponential separations for one-way quantum communication complexity, with applications to cryptography and the entangled-storage loss of Two-Source Extractors Secure Against Quantum Adversaries show that classical sizing can fail. The second ablation tests this directly on toy states with exactly computable guessing probability. For the dither, our claim is that simple hashing, or none at all, is enough, and the first ablation tests that.
Proposed Experiments
We evaluate on the benchmarks where dithered lattice codecs have been run: 8-dimensional synthetic Gaussians, MNIST, the 16-dimensional physics measurements and 33-dimensional speech features from Optimal Neural Compressors for the Rate-Distortion-Perception Tradeoff, and SVHN as used in Universal Rate-Distortion-Perception Representations for Lossy Compression. Bob is scored on mean squared error and on a realism divergence. The realism divergence is computed exactly for Gaussians and as Wasserstein distance or Fréchet distance in learned features on images and speech. We report the gap between the feature-based estimates and true divergences as a caveat, since the file flags it as a known limitation.
The first decisive check tests whether realism is blind to secrecy. Bob's curve with public dither plus extracted pad should coincide with the everything-secret baseline on every dataset, while consuming $R_c$ fewer secret bits per dimension. We will plot the saving as a fraction of the total secret budget against rate. We expect it to exceed one half below roughly 1.58 bits per dimension of message rate.
The second check measures the eavesdropper's own perception-distortion curve. We train the strongest attacker decoder we can, giving it full knowledge of the dither and the unpadded lattice levels, at key rates from zero to $R$. We then compare its distortion and realism with the Gaussian closed form. The prediction is falsifiable: Eve's realism should improve faster than her distortion as key rate falls, because fine levels carry texture. If instead her distortion and realism move together, the "texture without structure" picture is wrong.
The third check tests the quantum accounting. On simulated classical-quantum sources, a pad sized by $H_{\min}^{\epsilon}(W|E)$ should keep Eve's measured advantage below the leftover-hash bound. A pad sized classically should violate it on the Raz-style instance.
A last, exploratory run applies index padding to the diffusion codec of Towards image compression with perfect realism at ultra-low bitrates on Kodak. It asks whether its decoder noise can likewise stay public without hurting Bob's FID. The file reports PerCo's operating range, down to 0.003 bpp and below 0.04 bpp, but no extracted scalar FID values, so this comparison is relative only.
References
- Optimal Neural Compressors for the Rate-Distortion-Perception Tradeoff
- Leftover Hashing Against Quantum Side Information
- Universal Rate-Distortion-Perception Representations for Lossy Compression
- Rate-Distortion-Perception Trade-off with Strong Realism Constraints: Role of Side Information and Common Randomness
- The Rate-Distortion-Perception Trade-off: the Role of Private Randomness
- Exponential separations for one-way quantum communication complexity, with applications to cryptography
- Two-Source Extractors Secure Against Quantum Adversaries
- Real-time seedless post-processing for quantum random number generators
- Towards image compression with perfect realism at ultra-low bitrates
- Why Simple Hash Functions Work: Exploiting the Entropy in a Data Stream