Skip to content

Out-of-the-box differential privacy for scalable SGD analyticsBolt-on Differential Privacy for Scalable Stochastic Gradient Descent-based Analytics

arXiv· arXiv:1606.04722· Xi Wu, Fengan Li, Arun Kumar, Kamalika Chaudhuri, Somesh Jha, Jeffrey F. NaughtonGoogle; University of California, San Diego; University of Wisconsin-MadisonIndexed by this site · 27 days ago· Originally publishedDefenses

Quick read

Defenses

Based on the paper PDF (AI-generated); refer to the original

The authors propose a bolt-on differentially private SGD based on output perturbation; integrated into Bismarck, it requires almost no changes and has no runtime overhead, and the authors state that test accuracy is up to 4 times that of SCS13/BST14.

Threat modelThe goal is to achieve (ε, δ)-differential privacy (including ε-DP with δ=0) on the training data, protecting the privacy value of a single individual; the mechanism is to add noise to the SGD training output, and the victim system is a scalable SGD analytics system within an RDBMS (Bismarck).

Questions
Scalable SGD analysis and differentially private SGD have each developed separately, but mainstream in-RDBMS analytics frameworks have not integrated differentially private SGD, because adding noise leads to low model accuracy and because developing and running private algorithms incurs high overhead.
Methods
The authors treat the SGD implementation as a black box, adopt the classical output perturbation technique, and inject noise only once after training ends; the core is a new analysis of the L2 sensitivity of SGD, exploiting the expansion property of the gradient operator so that less noise is needed at a constant number of passes.
Experiments and results
Comparing with SCS13 and BST14 on Bismarck: the algorithm in this paper requires only about 10 lines of Python code for integration and has almost no runtime overhead; the authors report that on multiple real datasets test accuracy is up to 4 times (public tuning)/3.5 times (private tuning), and that it scales linearly with data size.
Limitations and future work
The authors point out that convergence can be proven only for a single pass (1-pass), and that convergence bounds for multiple passes cannot yet match BST14; understanding of the convergence behavior of private SGD with a constant number of passes remains insufficient; the experiments cover only convex and strongly convex ERM (logistic regression, Huber SVM).
Experimental setuplogistic regression、Huber SVM · MNIST、Protein et al. · test accuracy、runtime et al.
Evaluated models
logistic regressionHuber SVM
Benchmarks
MNISTProteinForest CovertypeHIGGSKDDCup-99
Metrics
test accuracyruntimescalability
AI summaryResearchers propose an out-of-the-box differential privacy SGD algorithm based on output perturbation, tested on multiple real datasets with accuracy up to 4 times that of state-of-the-art algorithms. Using a new SGD L2 sensitivity analysis, the method achieves better convergence under the same privacy guarantee and with only a constant number of passes over the data. The algorithm has been integrated into Bismarck, a scalable SGD analytics system built on an RDBMS, with almost no additional overhead and good scalability.

Researchers propose an out-of-the-box differential privacy SGD algorithm based on output perturbation, tested on multiple real datasets with accuracy up to 4 times that of state-of-the-art algorithms. Using a new SGD L2 sensitivity analysis, the method achieves better convergence under the same privacy guarantee and with only a constant number of passes over the data. The algorithm has been integrated into Bismarck, a scalable SGD analytics system built on an RDBMS, with almost no additional overhead and good scalability.

Paper analysis

6 questions; open one to read the full answer

  1. What problem does this paper attempt to solve?

    Scalable SGD systems and differentially private SGD research are disconnected: accuracy is low and development and runtime overhead are high; the authors propose a bolt-on approach.

    Core problem: mainstream scalable analytics frameworks (such as in-RDBMS systems) have not integrated differentially private SGD, and research is disconnected from practice.

    • Scenario and importance: SGD is the core optimization algorithm of in-RDBMS analytics systems such as Bismarck, and a private SGD version can automatically derive private versions of various convex analytical ML techniques; as applications such as personalized medicine and finance increasingly need to protect individual privacy, differential privacy is regarded as the gold standard for protecting data privacy (as stated by the authors).
    • Shortcomings of existing methods: after integrating the two state-of-the-art private SGD algorithms SCS13 and BST14 into Bismarck, the authors found that both have accuracy far below non-private SGD, and that their "white box" paradigm requires deep modification of the SGD gradient update code to inject noise, bringing significant runtime overhead.
    • Core observation: the authors' key observation is that for non-adaptive randomized algorithms (such as PSGD), it suffices to fix the randomness sequence per-record to bound the L2 sensitivity; combined with the expansiveness property of the gradient operator, the differing data point is visited only once per pass over the data, yielding a smaller sensitivity upper bound.
    • Proposed approach: propose a bolt-on private SGD based on classical output perturbation—treat the SGD implementation as a black box and inject noise only once at the end; and give a new L2 sensitivity analysis for the convex and strongly convex cases, giving better convergence under a constant number of passes.
    • Threat model:
      • Protection target: the privacy value of a single individual in the training set (neighboring datasets are defined as data differing by one individual).
      • Privacy guarantee: (ε, δ)-differential privacy, including ε-differential privacy when δ=0.
      • Mechanism location: add noise to the output model after SGD training is complete (output perturbation), trusting a centralized authority that can compute over the entire original dataset (distinct from local differential privacy).
      • Victim system: a scalable SGD analytics system on an RDBMS (Bismarck/PostgreSQL).
  2. What related research exists?

    Related work falls into three categories: output perturbation, objective perturbation, and online algorithms; this paper directly compares with SCS13 and BST14 and is distinct from local differential privacy systems.

    Three main paradigms of differentially private convex optimization

    • Output perturbation ([10, 13, 24, 33]): first find the exact convex optimum, then add noise. The paper points out that its privacy guarantee usually assumes an exact optimum can be found, which often does not hold in practice.
    • Objective perturbation ([13, 27]): exactly solve an optimization problem after random perturbation. The paper likewise points out that it relies on the assumption of an exact optimum.
    • Online algorithms ([10, 15, 24, 35]): includes SGD-style iterative noise-adding methods, and is the object of direct comparison in this paper.

    Baselines directly compared

    • SCS13 (Song, Chaudhuri, Sarwate [35]): adds noise at each SGD iteration so that the iterates satisfy differential privacy; the original source supports only a single pass over the data, and the authors extend it to support multiple passes.
    • BST14 (Bassily, Smith, Thakurta [10]): reduces the noise per iteration through subsampling and guarantees optimal convergence under O(m) passes over the data, but supports only (ε, δ)-DP; the original source requires O(m²) iterations, and the authors extend it to support a constant number of passes (cm iterations) and mini-batch, making it more competitive in the experiments.
    • Jain, Kothari, Thakurta [24]: its Algorithm 6 is similar to the strongly convex +(ε, δ)-DP setting of this paper, but uses Implicit Gradient Descent (a proximal-type algorithm), which the authors consider harder to implement than SGD, so no experimental comparison is made; its Algorithm 3 adds an amount of noise per step comparable to this paper, and is also not compared.

    Other related directions

    • Differential privacy for deep learning (Abadi et al. [9]): non-convex optimization; the paper points out that it has no convergence result and can guarantee only (ε, δ)-DP.
    • RAPPOR [18]: the local differential privacy model, with no trusted central authority; the authors point out that it is not directly comparable to the results of this paper.
    • Stability tools: the analysis in this paper borrows the Growth Recursion of Hardt, Recht, Singer [21] and the expansiveness property of the gradient operator [29, 31], as well as Shamir's [34] convergence result for SGD with without-replacement sampling.

    Positioning: The authors state that, unlike previous white-box approaches, this paper treats SGD as a black box and adds noise only at the output, thereby simultaneously solving integration overhead and runtime overhead, and, through a new sensitivity analysis, achieves better accuracy than SCS13/BST14 under a constant number of passes.

  3. How does the paper address this problem?

    Treat PSGD as a black box and only add noise at the output end; the core is to give a new analysis of the L2 sensitivity of PSGD and prove 1-pass convergence.

    Overall approach: using classical output perturbation as the framework, treat standard permutation-based SGD (PSGD) as a black-box call, and after training ends inject noise once, calibrated to a new L2 sensitivity bound, so that no internal SGD code needs to be modified.

    Problem setting and key definitions

    • Convex ERM setting: the loss function ℓ satisfies L-Lipschitz and β-smooth, with convex (γ=0) and γ-strongly convex cases; taking L2-regularized logistic regression as an example, when ‖x‖≤1 and ‖w‖≤R, L=1+λR, β=1+λ, γ=λ.
    • PSGD: first randomly sample a permutation τ, then cycle through the data k times according to τ (k-pass PSGD); PSGD is a non-adaptive algorithm (the random choices do not depend on the input data values).
    • Differential privacy: neighboring datasets differ by one individual; ε-DP uses noise with density p(κ) ∝ exp(−ε|κ|/Δ2) (Theorem 1), and (ε, δ)-DP uses Gaussian noise (Theorem 3).

    Core algorithms (Algorithm 1 and 2)

    • Algorithm 1 (convex): run k passes of PSGD with a constant learning rate η≤2/β, take the sensitivity upper bound Δ2 = 2kLη, sample noise κ, and return w+κ.
    • Algorithm 2 (strongly convex): run k passes of PSGD with a decreasing learning rate ηt = min(1/β, 1/γt), take Δ2 = 2L/(γm), add noise and return; in the strongly convex case the noise does not depend on the number of passes k.
    • Key difference: the two algorithms differ only in the L2 sensitivity on line 3; PSGD is called as a black box on line 2.

    Key techniques in the sensitivity analysis

    • Fixing randomness per-record: for non-adaptive algorithms, it suffices to bound max kA(r; S) − A(r; S')k under a fixed random sequence r (Lemma 5), avoiding the complex interaction of two different random sequences.
    • Expansiveness and growth recursion: use the ρ-expansiveness of the gradient operator (1-expansive in the convex case, (1−ηγ)-expansive in the strongly convex case with η≤1/β, Lemma 1–2) and its (ηL)-boundedness (Lemma 3), combined with the Growth Recursion of Hardt et al. (Lemma 4), to bound the distance δT between the two trajectories.
    • Each pass touches the differing point only once: under permutation sampling, each data point is visited only once per pass, and the contribution of the differing data point is subsequently attenuated by the contraction operator, giving δT ≤ 2kLη in the convex case (Corollary 1) and δT ≤ 2L/(γm) in the strongly convex case (Lemma 8).

    Extensions (Section 3.2.3)

    • (ε, δ)-DP: simply switch to Gaussian noise (Theorems 6–7).
    • Mini-batching: a batch size b improves the sensitivity bound by a factor of b.
    • Model averaging: the weighted average output w̄ = Σαt wt does not affect the sensitivity bound (Lemma 10).
    • Resampling the permutation each pass and constrained optimization (projected gradient) both apply verbatim.

    Convergence proof

    • Based on Shamir's [34] convergence result for SGD with without-replacement sampling and Zinkevich's [38] regret bound, proves the excess empirical risk bound of 1-pass PSGD with output perturbation: in the convex case E[LS(w̃) − LS∗] ≤ ((L + 2(12 + √L))R)/(√m) + 2dLR/(ε√m) (Theorem 10), and similarly in the strongly convex case (Theorem 12).
    • The authors state that compared with the convergence of BST14 under a constant number of passes, this is better by a log^{3/2} m factor in the convex case and by a √d log m factor in the strongly convex case (Table 2); and point out that this paper gives a convergence result for ε-DP, whereas BST14 gives convergence only for (ε, δ)-DP.

    Private parameter tuning

    • Two paths: tune with public data from the same distribution, or use a private tuning algorithm (Algorithm 3, from [13]): split the data into l+1 parts, train one model for each parameter combination (k, b, λ), and then use the exponential mechanism to select, with probability pi ∝ e^{−εχi/2}, the model with a small number of errors χi on the held-out set.
  4. What experiments did the paper conduct?

    Comparing the algorithm in this paper with SCS13 and BST14 on Bismarck: integration takes about 10 lines of code and has almost no overhead, and the authors state that accuracy is up to 4 times.

    Experimental setup

    • Compared algorithms: Noiseless (Bismarck's native mini-batch SGD), the algorithm in this paper (Alg. 1/2 + mini-batch + constrained optimization), SCS13 (extended to support multiple passes), BST14 (extended to support a constant number of passes, cm iterations, and mini-batch, Algorithm 4/5).
    • System environment: Bismarck on PostgreSQL (UDA implemented in C); Intel Xeon E5-2680 2.50GHz (48 cores), 64GB RAM, Ubuntu 14.04.4.
    • Datasets (Table 3): MNIST (10 classes, 60000 training/10000 test, 784 dimensions randomly projected to 50 dimensions), Protein (binary classification, 72876/72875, 74 dimensions), Forest Covertype (binary classification, 498010/83002, 54 dimensions); the appendix additionally has HIGGS (m=10,500,000) and KDDCup-99.
    • Tasks and losses: Logistic regression (main text) and Huber SVM (Appendix B, h=0.1); the convex case uses no regularization, and the strongly convex case uses L2 regularization.
    • Four test scenarios: convex+ε-DP, convex+(ε,δ)-DP, strongly convex+ε-DP, strongly convex+(ε,δ)-DP; BST14 participates only in the (ε,δ) scenarios. ε values: {0.1,…,4} for MNIST, {0.01,…,0.4} for Protein/Covertype; δ=1/m².
    • Hyperparameters: batch size b=50; λ is privately tuned over {0.0001, 0.001, 0.01}; k is tuned over {5, 10}; R=1/λ; MNIST uses one-vs.-all and splits the privacy budget evenly across the 10 sub-models. Runtimes are the mean of 4 warm-cache runs, and error bars are 90% confidence intervals.

    Main results

    The main results are reported as figures (Figure 3, 6); the summary numbers given in the main text are as follows:

    ResultValueSource
    With public-data tuning, the accuracy of the algorithm in this paper is at best better than SCS13/BST14up to 4XFigure 3, as stated by the authors
    With private tuning, at best better than BST14 / SCS13up to 3.5X / 3XFigure 6, as stated by the authors
    At 20 epochs and b=10, SCS13/BST14 are slower than the algorithm in this paper2X–3XFigure 5
    At b=1 and 1 epoch, SCS13/BST14 are slower than the algorithm in this paperup to 6XFigure 5
    Amount of integration code for the algorithm in this paperabout 10 lines of PythonSection 4.2
    • The authors state that on all datasets and parameter settings, the accuracy of the algorithm in this paper is better than SCS13 and BST14, and it converges faster to the noiseless level (at smaller ε).
    • The authors state that the algorithm in this paper has almost no runtime overhead and scales linearly with data size (Figure 2; both in-memory 3.7–18.6GB and on-disk 149–447GB are linear).
    • Integration comparison: SCS13/BST14 require adding dozens of lines of code in the C UDA transition function and implementing the noise sampling distribution in C; the algorithm in this paper adds only about 10 lines in the front-end Python controller (Figure 1).

    Effect of parameters (Figure 4)

    • Number of passes k: On MNIST convex ε-DP (b=1), at ε=4.0 the accuracy drops from 0.71 at 1 pass to 0.45 at 20 passes (Figure 4a); on strongly convex ε-DP (b=50), more passes instead improve accuracy (Figure 4b), because in the strongly convex case the noise does not depend on k.
    • Batch size b: On convex ε-DP at 20 passes, increasing b from 1 to 10 raises the accuracy from 0.45 to 0.71 (Figure 4c); Appendix D reports that when b is increased to 200, the algorithm in this paper approaches noiseless accuracy, while SCS13/BST14 remain clearly lower.

    Other datasets and Huber SVM

    • HIGGS/KDDCup-99 (Appendix C, Figure 8/9): On HIGGS the algorithm in this paper almost reaches noiseless accuracy, and the authors state that SCS13/BST14 remain clearly worse at small ε.
    • Huber SVM (Appendix B, Figure 7): The authors report that on MNIST the accuracy of the algorithm in this paper is up to 6 times that of BST14 and 2.5 times that of SCS13.

    Other ablations and analyses

    • With private tuning, on Protein the accuracy of BST14 and the algorithm in this paper are close, but the algorithm in this paper is still consistently better (Figure 6 row 2, as stated by the authors).
    • On Covertype the algorithm in this paper approaches the baseline at ε≈0.05, while BST14 approaches the baseline only after ε=0.4 (Figure 6 row 3, as stated by the authors).
    • Scalability: In memory, the runtime overhead of SCS13/BST14 grows linearly with data size; in the on-disk scenario I/O cost dominates, and the runtimes of the algorithms are close (Figure 2).
    • When the batch size is increased to 500, the runtime gap between the algorithms essentially disappears (Figure 5 row 2).
  5. What are some points that can be further explored?

    The authors point out that only 1-pass convergence can be proven; the experiments cover convex/strongly convex ERM and three main datasets, and do not report non-convex or multi-query scenarios.

    Limitations and future directions noted by the authors

    • Missing convergence proof for multiple passes (Section 6): the method in this paper converges well in practice with multiple passes, but only 1-pass convergence can be proven; the authors pose as an open question whether a multi-pass convergence bound can be proven and matched to the BST14 bound.
    • Insufficient understanding of private SGD convergence at a constant number of passes (Section 6): the authors state that the convergence behavior of private SGD when only a constant number of passes over the data can be afforded needs to be better understood.
    • Batch size sweet spot (Section 4.3): the authors leave "formally determining the optimal batch size among efficiency, noise and accuracy" as future work.
    • Multi-query settings (Section 4.6): this paper only addresses how to answer one "query" privately and effectively; how to allocate the privacy budget across multiple queries is orthogonal to this paper, and the authors believe there remains a gap between theory and practice in differentially private analytics systems.

    Scope of experiments

    • The compared algorithms are Noiseless, the algorithm in this paper, SCS13 and BST14, 4 in total; the IGD algorithm of Jain et al. was not experimentally compared because it is harder to implement (Section 4.1).
    • Task types cover convex and strongly convex ERM, with loss functions logistic regression (main text) and Huber SVM (Appendix B); non-convex models are not covered.
    • The main experimental datasets are MNIST, Protein and Forest Covertype (Table 3), with HIGGS and KDDCup-99 added in the appendix; MNIST is reduced to 50 dimensions via random projection.
    • Privacy parameters: ε∈{0.1,…,4} on MNIST, ε∈{0.01,…,0.4} on Protein/Covertype, δ=1/m²; the batch size is fixed at b=50 in the main experiments, and tested up to 200 in Appendix D.
    • The paper does not report the number of repetitions or confidence intervals for the accuracy experiments (only runtime reports the mean of 4 warm-cache runs with 90% confidence intervals).
  6. Summarize the main content of the paper

    Output-perturbation bolt-on private SGD: black-box integration, almost zero overhead, and the authors state that accuracy is up to 4 times that of SCS13/BST14.

    A systems-algorithms work on differentially private SGD, with the goal of bringing differential privacy into in-RDBMS scalable analytics systems.

    • Problem: Scalable SGD systems (such as Bismarck) and private SGD research have each developed separately but have never been combined, because adding noise leads to low accuracy and white-box private algorithm development and runtime overhead are high.
    • Method: Treat PSGD as a black box and, after training ends, inject noise once, calibrated to a new L2 sensitivity bound (output perturbation). The new analysis uses three facts—that for non-adaptive algorithms randomness can be fixed per-record, the expansiveness of the gradient operator, and that under permutation sampling a differing point is visited only once per pass—to obtain sensitivity bounds of Δ2=2kLη in the convex case and Δ2=2L/(γm) in the strongly convex case, and proves 1-pass convergence based on Shamir's without-replacement sampling result.
    • Integration and overhead: On Bismarck/PostgreSQL, the algorithm in this paper requires only about 10 lines of Python code in the front end and has almost no runtime overhead; SCS13/BST14 require adding dozens of lines of code in C UDA and are 2–3 times slower at 20 epochs and b=10, and up to 6 times slower at b=1 and 1 epoch (Figure 5).
    • Accuracy: The authors report that on MNIST, Protein, and Forest Covertype, with public-data tuning the accuracy of the algorithm in this paper is up to 4 times that of SCS13/BST14 (Figure 3), and with private tuning up to 3.5 times (Figure 6); on Huber SVM on MNIST it is up to 6 times that of BST14 (Appendix B).
    • Parameter patterns: In the convex case, more passes increase noise (on MNIST at ε=4.0, 0.71 at 1 pass → 0.45 at 20 passes); in the strongly convex case, noise is independent of the number of passes; increasing the batch size from 1 to 10 raises the accuracy at 20 passes from 0.45 back to 0.71 (Figure 4).
    • Authors' conclusion: Output perturbation plus the new sensitivity analysis simultaneously solves the three problems of integration, overhead, and accuracy; the limitation is that only 1-pass convergence can be proven, and multi-pass convergence bounds and multi-query budget allocation are left as future directions.
Read originalarxiv.org