Background
Let ( X , d ) (\mathcal{X}, d) ( X , d ) be a metric space, and f f f be a function X → R n \mathcal{X} \rightarrow \mathbb{R}^n X → R n .
A Gaussian mechanism adds Gaussian noise to the output of f f f , such that for all neighboring pairs x , y ∈ X x, y \in \mathcal{X} x , y ∈ X with d ( x , y ) = 1 d(x, y) = 1 d ( x , y ) = 1 , it is hard to distinguish the outputs, i.e., their outputs distributions are similar.
Definition. The sensitivity Δ \Delta Δ of f f f is defined as
Δ = max x , y ∈ X , d ( x , y ) = 1 ∥ f ( x ) − f ( y ) ∥ 2 ,
\Delta = \max_{x, y \in \mathcal{X}, d(x, y) = 1 } \Vert f(x) - f(y) \Vert_2,
Δ = x , y ∈ X , d ( x , y ) = 1 max ∥ f ( x ) − f ( y ) ∥ 2 , where ∥ ⋅ ∥ 2 \Vert \cdot \Vert_2 ∥ ⋅ ∥ 2 is the ℓ 2 \ell_2 ℓ 2 -norm of a vector in R n \mathbb{R}^n R n .
Definition. Given f f f and a variance parameter σ 2 \sigma^2 σ 2 , the output of the Gaussian mechanism is a random variable defines as
g ( x ) = f ( x ) + X ,
g(x) = f(x) + X,
g ( x ) = f ( x ) + X , where X = ( X 1 , X 2 , . . . , X n ) ∼ N ( 0 , σ 2 I ) X = (X_1, X_2, ..., X_n) \sim N(0, \sigma^2 I) X = ( X 1 , X 2 , ... , X n ) ∼ N ( 0 , σ 2 I ) .
Privacy Guarantee
Theorem. For δ , ϵ ∈ ( 0 , 1 ) \delta, \epsilon \in (0, 1) δ , ϵ ∈ ( 0 , 1 ) , if σ 2 = Δ 2 ϵ 2 ( 2 ln 1 δ + ϵ ) \sigma^2 = \frac{ \Delta^2 }{ \epsilon^2 } \Big( 2 \ln \frac{1}{\delta} + \epsilon \Big) σ 2 = ϵ 2 Δ 2 ( 2 ln δ 1 + ϵ ) , then ∀ x , y ∈ X \forall x, y \in \mathcal{X} ∀ x , y ∈ X , s.t., d ( x , y ) = 1 d(x, y) = 1 d ( x , y ) = 1 , and for all measurable subset S ⊂ R n S \subset \mathbb{R}^n S ⊂ R n , it holds
Pr [ g ( x ) ∈ S ] ≤ e ϵ ⋅ Pr [ g ( y ) ∈ S ] + δ
\Pr[ g(x) \in S] \le e^\epsilon \cdot \Pr[ g(y) \in S] + \delta
Pr [ g ( x ) ∈ S ] ≤ e ϵ ⋅ Pr [ g ( y ) ∈ S ] + δ
It is obvious that if we set σ → ∞ \sigma \rightarrow \infty σ → ∞ , then the Gaussian distribution converge to a uniform one and it holds that Pr [ g ( x ) ∈ S ] = Pr [ g ( y ) ∈ S ] \Pr[ g(x) \in S] = \Pr[ g(y) \in S] Pr [ g ( x ) ∈ S ] = Pr [ g ( y ) ∈ S ] .
Therefore, we are interested in how small σ \sigma σ can be.
We claim that σ = O ( Δ ϵ ) \sigma = O(\frac{\Delta}{\epsilon } ) σ = O ( ϵ Δ ) suffices.
This is based on three observations:
Most of the probability mass of a Gaussian distribution concentrates on a ball centered at its mean with radius O ( σ ) O(\sigma) O ( σ ) .
The density ratio of any two points within the ball is bounded by a constant.
The distance between the distribution center of g ( x ) g(x) g ( x ) and g ( y ) g(y) g ( y ) is bounded by Δ \Delta Δ .
Proof. To ease the notations, we write g ( y ) = f ( y ) + Y g(y) = f(y) + Y g ( y ) = f ( y ) + Y to distinguish it from g ( x ) g(x) g ( x ) .
By definition,
g ( x ) ∼ N ( f ( x ) , σ 2 I ) , g ( y ) ∼ N ( f ( y ) , σ 2 I ) . g(x) \sim N(f(x), \sigma^2 I), \quad g(y) \sim N( f(y), \sigma^2 I).
g ( x ) ∼ N ( f ( x ) , σ 2 I ) , g ( y ) ∼ N ( f ( y ) , σ 2 I ) . Let p x p_x p x and p y p_y p y the density functions of g ( x ) g(x) g ( x ) and g ( y ) g(y) g ( y ) respectively.
The sketch of the proof is as follows: we partition R n \mathbb{R}^n R n into two parts:
Y 1 = { t ∈ R n : p x ( t ) ≤ e ϵ ⋅ p y ( t ) } Y 2 = { t ∈ R n : p x ( t ) > e ϵ ⋅ p y ( t ) } .
\mathcal{Y}_1 = \{ t \in \mathcal{R}^n : p_x(t) \le e^\epsilon \cdot p_y(t) \} \\
\mathcal{Y}_2 = \{ t \in \mathcal{R}^n : p_x(t) > e^\epsilon \cdot p_y(t) \}.
Y 1 = { t ∈ R n : p x ( t ) ≤ e ϵ ⋅ p y ( t )} Y 2 = { t ∈ R n : p x ( t ) > e ϵ ⋅ p y ( t )} . If Pr [ g ( x ) ∈ Y 2 ] ≤ δ \Pr[ g(x) \in \mathcal{Y}_2 ] \le \delta Pr [ g ( x ) ∈ Y 2 ] ≤ δ ( \big( ( here we measure the size of Y 2 \mathcal{Y}_2 Y 2 by the probability measure induced by g ( x ) g(x) g ( x ) ) \big) ) , then
Pr [ g ( x ) ∈ S ] = Pr [ g ( x ) ∈ S ∩ Y 1 ] + Pr [ g ( x ) ∈ S ∩ Y 2 ] ≤ Pr [ g ( x ) ∈ S ∩ Y 1 ] + Pr [ g ( x ) ∈ Y 2 ] ≤ Pr [ g ( x ) ∈ S ∩ Y 1 ] + δ = ∫ S ∩ Y 1 p x ( t ) d t + δ ≤ ∫ S ∩ Y 1 e ϵ ⋅ p y ( t ) d t + δ = e ϵ ⋅ Pr [ g ( y ) ∈ S ∩ Y 1 ] + δ . ≤ e ϵ ⋅ Pr [ g ( y ) ∈ S ] + δ .
\begin{aligned}
\Pr[ g(x) \in S]
&= \Pr[ g(x) \in S \cap \mathcal{Y}_1] + \Pr[ g(x) \in S \cap \mathcal{Y}_2] \\
&\le \Pr[ g(x) \in S \cap \mathcal{Y}_1] + \Pr[ g(x) \in \mathcal{Y}_2] \\
&\le \Pr[ g(x) \in S \cap \mathcal{Y}_1] + \delta \\
&= \int_{S \cap \mathcal{Y}_1 } p_x(t) \ d t + \delta \\
&\le \int_{S \cap \mathcal{Y}_1 } e^\epsilon \cdot p_y(t) \ d t + \delta \\
&= e^\epsilon \cdot \Pr[ g(y) \in S \cap \mathcal{Y}_1] + \delta. \\
&\le e^\epsilon \cdot \Pr[ g(y) \in S ] + \delta. \\
\end{aligned}
Pr [ g ( x ) ∈ S ] = Pr [ g ( x ) ∈ S ∩ Y 1 ] + Pr [ g ( x ) ∈ S ∩ Y 2 ] ≤ Pr [ g ( x ) ∈ S ∩ Y 1 ] + Pr [ g ( x ) ∈ Y 2 ] ≤ Pr [ g ( x ) ∈ S ∩ Y 1 ] + δ = ∫ S ∩ Y 1 p x ( t ) d t + δ ≤ ∫ S ∩ Y 1 e ϵ ⋅ p y ( t ) d t + δ = e ϵ ⋅ Pr [ g ( y ) ∈ S ∩ Y 1 ] + δ . ≤ e ϵ ⋅ Pr [ g ( y ) ∈ S ] + δ . As p y ( t ) > 0 p_y(t) > 0 p y ( t ) > 0 for all t ∈ R n t \in \mathbb{R}^n t ∈ R n , we can rewrite
Y 1 = { t ∈ R n : ln p x ( t ) p y ( t ) ≤ ϵ } Y 2 = { t ∈ R n : ln p x ( t ) p y ( t ) > ϵ } .
\mathcal{Y}_1 = \Big\{ t \in \mathcal{R}^n : \ln \frac{p_x(t) }{ p_y(t) } \le \epsilon \Big\} \\
\mathcal{Y}_2 = \Big\{ t \in \mathcal{R}^n : \ln \frac{p_x(t) }{ p_y(t) } > \epsilon \Big\}.
Y 1 = { t ∈ R n : ln p y ( t ) p x ( t ) ≤ ϵ } Y 2 = { t ∈ R n : ln p y ( t ) p x ( t ) > ϵ } . In literature, the ratio ln p x ( t ) p y ( t ) \ln \frac{p_x(t) }{ p_y(t) } ln p y ( t ) p x ( t ) is know as privacy loss . Substituting p x ( t ) p_x(t) p x ( t ) and p y ( t ) p_y(t) p y ( t ) with their definitions, and letting t ′ = t − f ( x ) t' = t - f(x) t ′ = t − f ( x ) and v = f ( x ) − f ( y ) v = f(x) - f(y) v = f ( x ) − f ( y ) , we get
ln p x ( t ) p y ( t ) = ln 1 2 π σ 2 exp ( − ∥ t − f ( x ) ∥ 2 2 σ 2 ) 1 2 π σ 2 exp ( − ∥ t − f ( y ) ∥ 2 2 σ 2 ) = − ∥ t ′ ∥ 2 − ∥ t ′ + v ∥ 2 2 σ 2 = 2 v T t ′ + ∥ v ∥ 2 2 σ 2 .
\begin{aligned}
\ln \frac{ p_x( t) }{ p_y(t)}
&= \ln \frac{ \frac{1}{ \sqrt{2 \pi \sigma^2} } \exp \Big( -\frac{ \Vert t - f(x)\Vert ^2 }{ 2 \sigma^2 } \Big) }{ \frac{1}{ \sqrt{2 \pi \sigma^2} } \exp \Big( -\frac{ \Vert t - f(y) \Vert ^2 }{ 2 \sigma^2 } \Big) } \\
&= -\frac{ \Vert t' \Vert ^2 - \Vert t' + v \Vert ^2 }{ 2 \sigma^2 } \\
&= \frac{ 2 v^T t' + \Vert v \Vert ^2 }{ 2 \sigma^2 } .
\end{aligned}
ln p y ( t ) p x ( t ) = ln 2 π σ 2 1 exp ( − 2 σ 2 ∥ t − f ( y ) ∥ 2 ) 2 π σ 2 1 exp ( − 2 σ 2 ∥ t − f ( x ) ∥ 2 ) = − 2 σ 2 ∥ t ′ ∥ 2 − ∥ t ′ + v ∥ 2 = 2 σ 2 2 v T t ′ + ∥ v ∥ 2 . If t ∼ N ( f ( x ) , σ 2 I ) t \sim N( f(x), \sigma^2 I) t ∼ N ( f ( x ) , σ 2 I ) , it holds that t ′ ∼ N ( 0 , σ 2 I ) t' \sim N( 0, \sigma^2 I) t ′ ∼ N ( 0 , σ 2 I ) .
Then v T t ′ ∼ N ( 0 , ∥ v ∥ 2 σ 2 ) v^T t' \sim N(0, \Vert v \Vert ^2 \sigma^2) v T t ′ ∼ N ( 0 , ∥ v ∥ 2 σ 2 ) . Let Z ∼ N ( 0 , 1 ) Z \sim N(0, 1) Z ∼ N ( 0 , 1 ) , then ln p x ( t ) p y ( t ) \ln \frac{ p_x( t) }{ p_y(t)} ln p y ( t ) p x ( t ) has the same distribution as
2 ∥ v ∥ σ Z + ∥ v ∥ 2 2 σ 2 = ∥ v ∥ 2 2 σ 2 + ∥ v ∥ σ Z ∼ N ( ∥ v ∥ 2 2 σ 2 , ∥ v ∥ 2 σ 2 ) .
\frac{ 2 \Vert v\Vert \sigma Z + \Vert v\Vert ^2 }{ 2 \sigma^2 } = \frac{ \Vert v\Vert ^2 }{ 2 \sigma^2 } + \frac{ \Vert v\Vert }{ \sigma } Z \sim N \Big( \frac{ \Vert v\Vert ^2 }{ 2 \sigma^2 }, \frac{ \Vert v\Vert ^2 }{ \sigma^2 } \Big). \\
2 σ 2 2∥ v ∥ σ Z + ∥ v ∥ 2 = 2 σ 2 ∥ v ∥ 2 + σ ∥ v ∥ Z ∼ N ( 2 σ 2 ∥ v ∥ 2 , σ 2 ∥ v ∥ 2 ) . Now,
∥ v ∥ 2 2 σ 2 + ∥ v ∥ σ Z ≥ ϵ ⟷ Z ≥ σ ∥ v ∥ ϵ − ∥ v ∥ 2 σ
\frac{ \Vert v\Vert ^2 }{ 2 \sigma^2 } + \frac{ \Vert v\Vert }{ \sigma } Z \ge \epsilon \\
\longleftrightarrow Z \ge \frac{ \sigma }{ \Vert v\Vert } \epsilon - \frac{ \Vert v\Vert }{ 2 \sigma }
2 σ 2 ∥ v ∥ 2 + σ ∥ v ∥ Z ≥ ϵ ⟷ Z ≥ ∥ v ∥ σ ϵ − 2 σ ∥ v ∥ As Z ∼ N ( 0 , 1 ) Z \sim N(0, 1) Z ∼ N ( 0 , 1 ) , ∀ z ∈ R ≥ 0 \forall z \in \mathbb{R}_{\ge 0} ∀ z ∈ R ≥ 0 ,
Pr [ Z ≥ z ] ≤ exp ( − z 2 2 ) .
\Pr[ Z \ge z] \le \exp \Big( -\frac{ z^2 }{2} \Big).
Pr [ Z ≥ z ] ≤ exp ( − 2 z 2 ) . Assuming that σ 2 ≥ ∥ v ∥ 2 2 ϵ \sigma^2 \ge \frac{\Vert v \Vert^2}{ 2 \epsilon } σ 2 ≥ 2 ϵ ∥ v ∥ 2 .
Then σ ∥ v ∥ ϵ − ∥ v ∥ 2 σ ≥ 0 \frac{ \sigma }{ \Vert v\Vert } \epsilon - \frac{ \Vert v\Vert }{ 2 \sigma } \ge 0 ∥ v ∥ σ ϵ − 2 σ ∥ v ∥ ≥ 0 .
Replacing z z z with σ ∥ v ∥ ϵ − ∥ v ∥ 2 σ \frac{ \sigma }{ \Vert v\Vert } \epsilon - \frac{ \Vert v\Vert }{ 2 \sigma } ∥ v ∥ σ ϵ − 2 σ ∥ v ∥ ,
Pr [ z ≥ t ] ≤ exp ( − 1 2 ( σ ∥ v ∥ ϵ − ∥ v ∥ 2 σ ) 2 ) .
\Pr[ z \ge t ] \le \exp \Big( -\frac{1}{2} \Big( \frac{ \sigma }{ \Vert v\Vert } \epsilon - \frac{ \Vert v\Vert }{ 2 \sigma } \Big)^2 \Big).
Pr [ z ≥ t ] ≤ exp ( − 2 1 ( ∥ v ∥ σ ϵ − 2 σ ∥ v ∥ ) 2 ) . We would like to bound this probability by some δ ∈ ( 0 , 1 ) \delta \in (0, 1) δ ∈ ( 0 , 1 ) , then
exp ( − 1 2 ( σ ∥ v ∥ ϵ − ∥ v ∥ 2 σ ) 2 ) ≤ δ ⟹ σ ∥ v ∥ ϵ − ∥ v ∥ 2 σ ≥ 2 ln 1 δ ⟹ ϵ ∥ v ∥ σ 2 − 2 ln 1 δ σ − ∥ v ∥ 2 ≥ 0
\begin{aligned}
&\exp \Big( -\frac{1}{2} \Big( \frac{ \sigma }{ \Vert v\Vert } \epsilon - \frac{ \Vert v\Vert }{ 2 \sigma } \Big)^2 \Big) \le \delta \\
&\Longrightarrow \frac{ \sigma }{ \Vert v\Vert } \epsilon - \frac{ \Vert v\Vert }{ 2 \sigma } \ge \sqrt{2 \ln \frac{1}{\delta} } \\
&\Longrightarrow \frac{\epsilon }{\Vert v\Vert } \sigma^2 - \sqrt{2 \ln \frac{1}{\delta} } \sigma - \frac{ \Vert v\Vert }{2} \ge 0
\end{aligned}
exp ( − 2 1 ( ∥ v ∥ σ ϵ − 2 σ ∥ v ∥ ) 2 ) ≤ δ ⟹ ∥ v ∥ σ ϵ − 2 σ ∥ v ∥ ≥ 2 ln δ 1 ⟹ ∥ v ∥ ϵ σ 2 − 2 ln δ 1 σ − 2 ∥ v ∥ ≥ 0 Finally, we get
σ ≥ 2 ln 1 δ + 2 ln 1 δ + 2 ϵ 2 ϵ ∥ v ∥
\sigma \ge \frac{ \sqrt{ 2 \ln \frac{1}{\delta} } + \sqrt{ 2 \ln \frac{1}{\delta} + 2 \epsilon } }{ 2 \frac{\epsilon }{\Vert v\Vert } }
σ ≥ 2 ∥ v ∥ ϵ 2 ln δ 1 + 2 ln δ 1 + 2 ϵ By concavity of the square root function, it suffices to take
σ = ∥ v ∥ ϵ 0.5 ⋅ 2 ln 1 δ + 0.5 ⋅ ( 2 ln 1 δ + 2 ϵ ) = ∥ v ∥ ϵ 2 ln 1 δ + ϵ ,
\sigma = \frac{ \Vert v\Vert }{ \epsilon } \sqrt{ 0.5 \cdot 2 \ln \frac{1}{\delta} + 0.5 \cdot \Big( 2 \ln \frac{1}{\delta} + 2 \epsilon \Big) } = \frac{ \Vert v\Vert }{ \epsilon } \sqrt{ 2 \ln \frac{1}{\delta} + \epsilon },
σ = ϵ ∥ v ∥ 0.5 ⋅ 2 ln δ 1 + 0.5 ⋅ ( 2 ln δ 1 + 2 ϵ ) = ϵ ∥ v ∥ 2 ln δ 1 + ϵ , i.e.,
σ 2 = ∥ v ∥ 2 ϵ 2 ( 2 ln 1 δ + ϵ ) .
\sigma^2 = \frac{ \Vert v\Vert ^2 }{ \epsilon^2 } \Big( 2 \ln \frac{1}{\delta} + \epsilon \Big).
σ 2 = ϵ 2 ∥ v ∥ 2 ( 2 ln δ 1 + ϵ ) . ■ \blacksquare ■
Reference
[1] G. Kamath, “Lecture 5 — Approximate Differential Privacy”, CS 860 - Algorithms for Private Data Analy sis.
← Back to all notes Back to top ↑