Dwork Roth 2014 - Laplace Mechanism
Summary
For numeric queries , adding independent noise to each coordinate gives -DP (Thm. 3.6), where is the -sensitivity. With probability no coordinate is off by more than (Thm. 3.8). Counting and histogram queries have sensitivity , so error is independent of database size and, for histograms, of the number of cells.
Overview
Numeric queries “are one of the most fundamental types of database queries”. How accurately they can be answered under DP is governed by their -sensitivity: “the magnitude by which a single individual’s data can change the function in the worst case, and therefore, intuitively, the uncertainty in the response that we must introduce in order to hide the participation of a single individual.”
Main Content
Definition 3.1 - -sensitivity (p. 31)
The -sensitivity of is
Definition 3.2 - Laplace distribution (p. 31)
The Laplace distribution (centred at ) with scale has density and variance . Write for the distribution or a random variable . It is a symmetric version of the exponential distribution.
Definition 3.3 - Laplace mechanism (p. 32)
Given , the Laplace mechanism is with i.i.d. .
Theorem 3.6 (p. 32)
The Laplace mechanism preserves -differential privacy.
Proof (p. 32)
Let with and let be the densities of and . At an arbitrary point :
The first inequality is the triangle inequality, the last is the definition of . The bound follows by symmetry.
Footnote (p. 31): Gaussian noise with variance calibrated to achieves -DP (Appendix A), but the Laplace mechanism is cleaner and the two behave similarly under composition (Thm. 3.20).
Counting, linear and histogram queries
Example 3.1 - Counting queries (pp. 32-33)
Setup. “How many elements in the database satisfy Property ?” Counting is “an extremely powerful primitive”: it captures everything learnable in the statistical queries model and many data-mining tasks. Sensitivity. Adding or deleting one individual changes a count by at most , so . Release. -DP by adding ; expected distortion , independent of database size. Many queries. A fixed arbitrary list of counting queries has worst-case sensitivity (one individual may change every count), so noise scaled to per answer is needed. Responding to large numbers of arbitrary queries is the query release problem.
Example 3.2 - Histogram queries (p. 33)
When queries are structurally disjoint, noise need not scale with the number of queries. The universe is partitioned into cells and the query asks how many elements lie in each. Because cells are disjoint, one element affects exactly one cell by at most , so the histogram has sensitivity and each count is answered by adding an independent draw.
Fact 3.7 (p. 33)
If then .
Theorem 3.8 - Accuracy of the Laplace mechanism (p. 34)
Let and . Then for all :
Proof (p. 34)
, by the union bound and Fact 3.7 with , .
Example 3.3 - First names (p. 34)
Setup. Which first names, from 10,000 potential names, were most common among participants of the 2010 census? The query is , a histogram query, so (each person has at most one first name). Solution. All 10,000 name frequencies can be released simultaneously with -DP; with probability 95% no estimate is off by more than . Interpretation. “That’s pretty low error for a nation of more than 300,000,000 people!”
Differentially private selection
The task in Example 3.3 is differentially private selection: the outcome space is discrete and the goal is to output a “best” answer (here, the most populous cell). Example 3.4 and Report Noisy Max (next note) show how to do this at noise cost even when the vector of counts has high -sensitivity: Dwork Roth 2014 - Report Noisy Max and the Exponential Mechanism.
Examples
import numpy as np, math
rng = np.random.default_rng(0)
def laplace_mechanism(f_x, sensitivity, eps, rng=rng):
f_x = np.atleast_1d(np.asarray(f_x, float))
return f_x + rng.laplace(0.0, sensitivity / eps, size=f_x.shape)
# Example 3.3: 10,000-cell histogram, eps = 1, Delta f = 1
counts = rng.poisson(30_000, size=10_000)
noisy = laplace_mechanism(counts, 1.0, 1.0)
bound = math.log(10_000 / 0.05) * 1.0 / 1.0
print(np.abs(noisy - counts).max(), bound) # max error vs ln(k/delta)*Delta/eps = 12.2
# fraction of runs with error beyond the bound should be <= delta = 0.05
bad = np.mean([np.abs(laplace_mechanism(counts, 1, 1) - counts).max() > bound for _ in range(500)])
print(bad)Reading Theorem 3.8. The bound has only a dependence on the number of released counts, so releasing cells at costs a maximum error near 12, versus about for -query noise scale with a high-sensitivity query set (Example 3.1).
Connections
- Marketing measurement. A report of conversions by campaign (each user converting in at most one campaign, or contributions capped) is a histogram with (or the cap): per-cell noise of scale with a maximum error across cells near . For campaign-days at and 95% confidence that is about conversions: negligible for large cells and dominant for cells with fewer than about 50 conversions. Compare with the sampling noise discussion in Geo-Experiment Design and Power Analysis: DP noise adds a variance term of per cell that can be modelled explicitly.
- The union-bound inflation is the same structure as a Bonferroni correction (Multiple Testing Corrections).
See Also
- Dwork Roth 2014 - Report Noisy Max and the Exponential Mechanism
- Dwork Roth 2014 - Advanced Composition and the Gaussian Mechanism
- Dwork 2006 - Sensitivity and the Laplace Mechanism (original statement and the adaptive version)
- Wasserman Zhou 2010 - Histogram Release Mechanisms (histograms perturbed with Laplace noise, statistical rates)