Adaptive Hyperparameter Selection for Differentially Private Gradient Descent

Dominik Fay, Sindri Magnússon, Jens Sjölund, Mikael JohanssonTMLR 2023

Abstract

We present an adaptive mechanism for hyperparameter selection in differentially private optimization that addresses the inherent trade-off between utility and privacy. The mechanism eliminates the often unstructured and time-consuming manual effort of selecting hyperparameters and avoids the additional privacy costs that hyperparameter selection otherwise incurs on top of that of the actual algorithm. We instantiate our mechanism for noisy gradient descent on non-convex, convex and strongly convex loss functions, respectively, to derive schedules for the noise variance and step size. These schedules account for the properties of the loss function and adapt to convergence metrics such as the gradient norm. When using these schedules, we show that noisy gradient descent converges at essentially the same rate as its noise-free counterpart. Numerical experiments show that the schedules consistently perform well across a range of datasets without manual tuning.

Introduction

Training machine learning models with Differential Privacy (DP) typically involves adding noise to gradients, creating a fundamental trade-off: excessive noise degrades model utility, while insufficient noise compromises privacy. Currently, practitioners navigate this by manually tuning hyperparameters such as the noise scale ($\sigma$) and step size ($\eta$). This process is not only computationally expensive but also incurs a "privacy tax"—every access to the data during tuning consumes part of the privacy budget ($\epsilon$). This work introduces an adaptive framework that selects these parameters automatically during training by optimizing a Privacy-Utility Ratio (PUR) at every step, ensuring optimal utility without additional privacy leakage.

Methodology

The core innovation is the optimization of the PUR at each iteration, defined as: $$\text{PUR}(\sigma_t, \eta_t) = \frac{\text{Privacy Cost}}{\text{Utility Improvement}}$$

By minimizing this ratio, the algorithm dynamically adjusts noise levels and step sizes. Key methodological components include:

  • Utility Estimation: A "descent lemma" is used to provide a mathematical bound on the expected decrease in the loss function.
  • Role Reversal: Contrary to standard DP-GD, which often uses constant noise and decaying step sizes, this research demonstrates that keeping the step size constant and decaying the noise proportional to the gradient norm is often more effective.
  • Data-Independent Schedules: To prevent the schedule itself from leaking information, the authors derive schedules based on analytical upper bounds of the gradient's evolution, ensuring the noise levels are set without direct, sensitive data access.

Theoretical Guarantees and Results

The proposed adaptive schedules achieve convergence rates that match or exceed existing state-of-the-art private optimization methods. Notably, the algorithm converges at essentially the same rate as non-private gradient descent (e.g., $O(1/T)$ for convex functions), adjusted by a constant factor.

Table 1: Comparison of convergence rates for convex functions, showing improved iteration complexity and competitive excess loss.

For strongly convex loss functions, the method achieves the optimal privacy-utility trade-off, matching established theoretical lower bounds.

Table 2: Comparison of convergence rates for strongly convex functions, highlighting that the proposed method reaches the theoretical lower bound for excess loss.

Experimental Evaluation

The approach was validated using regularized logistic regression across diverse benchmarks, including synthetic data, MNIST, CIFAR-10 (via ScatterNet features), and various UCI repository datasets like KDD Cup ’99. In these experiments, the adaptive schedules performed as well as—and often better than—the best constant noise variance found through exhaustive (and privacy-expensive) grid searches. The schedules proved robust across different datasets without requiring manual, dataset-specific adjustments.

Conclusion and Future Work

This work establishes a robust framework for self-tuning DP-GD. By maintaining a constant signal-to-noise ratio as the model approaches the optimum, the method achieves convergence rates comparable to non-private gradient descent. Future research will focus on extending the PUR framework to Stochastic Gradient Descent (SGD), accounting for privacy amplification by sub-sampling, and addressing the challenges posed by non-smooth loss functions.

Summary updated

BibTeX
@article{fay2023adaptive,
  author = {Dominik Fay and Sindri Magnússon and Jens Sjölund and Mikael Johansson},
  title = {{Adaptive Hyperparameter Selection for Differentially Private Gradient Descent}},
  journal = {Accepted by TMLR},
  year = {2023},
  url = {https://openreview.net/forum?id=LLKI5Lq2YN},
}
Figure