TL;DR
This paper investigates the trade-offs between differential privacy (DP) and deep learning performance, specifically focusing on convergence and model calibration. They find that DP noise primarily impacts privacy risk, while per-sample gradient clipping significantly affects convergence and calibration. Crucially, larger clipping norms lead to better-calibrated models with comparable accuracy and privacy.
What Problem Does This Paper Address?
Deep learning models are increasingly used with sensitive data, raising privacy concerns. Differential privacy (DP) offers a rigorous way to protect this data, but it often comes at the cost of slower training (convergence) and less accurate or reliable models (mis-calibration). While DP training methods like DP-SGD are widely used, the theoretical understanding of why these trade-offs occur, particularly concerning convergence and calibration, has been limited. This paper aims to demystify these phenomena by providing a theoretical framework and empirical validation.
Methods
The authors employ a continuous-time analysis framework using the Neural Tangent Kernel (NTK) to model the dynamics of DP training. This approach allows them to disentangle the effects of two key DP components: noise addition and per-sample gradient clipping. They analyze how these components influence the NTK matrix and, consequently, the convergence and calibration of the models. They also investigate two styles of gradient clipping: "flat clipping" and "layerwise clipping."
Datasets
The paper uses several standard datasets for evaluation:
- CIFAR10: Image classification dataset.
- MNIST: Image classification dataset.
- SNLI: Natural Language Inference dataset.
- California Housing: Regression dataset.
- Wine Quality: Regression dataset.
Key Insights and Ideas
- Noise vs. Clipping: The most striking finding is that the noise added for privacy has no impact on the convergence or calibration of the model in the continuous-time limit. Instead, it solely affects the privacy risk. This is a significant theoretical result that shifts focus to the clipping mechanism.
- Clipping's Dual Role: Per-sample gradient clipping, on the other hand, is shown to be the primary driver of changes in both convergence speed and model calibration.
- The "Small Clipping Norm" Paradox: DP models trained with a small clipping norm tend to achieve higher accuracy but are poorly calibrated, meaning their confidence in predictions doesn't match their actual accuracy. They are often "over-confident."
- The "Large Clipping Norm" Solution: Conversely, using a large clipping norm not only maintains the same privacy guarantee but also leads to significantly better calibration with comparable accuracy. This suggests a practical strategy for improving DP model reliability.
- NTK as the Key: The analysis hinges on how clipping modifies the Neural Tangent Kernel (NTK) matrix, impacting its properties like symmetry and positive definiteness, which are crucial for convergence guarantees.
Key Results
- Theoretical: The paper provides a continuous-time analysis of DP-SGD using the NTK, showing that noise addition does not affect convergence or calibration, while clipping does. They formally characterize how small clipping norms can break the positive semi-definiteness of the NTK, leading to non-monotonic loss decrease and potential convergence to non-zero loss. Large clipping norms, conversely, preserve the NTK's desirable properties.
- Empirical: Experiments on CIFAR10, MNIST, and SNLI datasets demonstrate that:
- DP models with small clipping norms are often over-confident and mis-calibrated.
- DP models with large clipping norms achieve similar accuracy and privacy but are significantly more calibrated.
- For large models like Transformers, large clipping norms are crucial for achieving both high accuracy and good calibration.
Limitations and Future Work
- Discrete-time Analysis: The current analysis primarily focuses on the continuous-time limit (infinitesimal learning rate). The authors acknowledge that in the discrete-time setting, especially with non-negligible learning rates and noise, the noise addition can affect convergence. This is identified as a key area for future investigation.
- Mini-batch Optimizers: The analysis is extended to mini-batch optimizers, but the dynamics are noted to become stochastic, requiring further study using stochastic differential equations.
- Cross-entropy vs. Accuracy: The inconsistency between cross-entropy loss and prediction accuracy, and its connection to calibration, remains an intriguing area for theoretical understanding.
- Global Clipping: While explored, the paper suggests that with large clipping norms, global clipping offers negligible differences from existing clipping methods in terms of convergence and calibration.
Summary updated