Share your thoughts, 1 month free Claude Pro on usSee more
WorkDL logo mark

Differentially Private Optimization for Non-Decomposable Objective Functions

About

Unsupervised pre-training is a common step in developing computer vision models and large language models. In this setting, the absence of labels requires the use of similarity-based loss functions, such as contrastive loss, that favor minimizing the distance between similar inputs and maximizing the distance between distinct inputs. As privacy concerns mount, training these models using differential privacy has become more important. However, due to how inputs are generated for these losses, one of their undesirable properties is that their $L_2$ sensitivity grows with the batch size. This property is particularly disadvantageous for differentially private training methods, such as DP-SGD. To overcome this issue, we develop a new DP-SGD variant for similarity based loss functions -- in particular, the commonly-used contrastive loss -- that manipulates gradients of the objective function in a novel way to obtain a sensitivity of the summed gradient that is $O(1)$ for batch size $n$. We test our DP-SGD variant on some CIFAR-10 pre-training and CIFAR-100 finetuning tasks and show that, in both tasks, our method's performance comes close to that of a non-private model and generally outperforms DP-SGD applied directly to the contrastive loss.

Weiwei Kong, Andr\'es Mu\~noz Medina, M\'onica Ribero• 2023

Related benchmarks

TaskDatasetResultRank
ClassificationCIFAR10 (test)
Accuracy32.1
331
Image ClassificationF-MNIST (test)
Accuracy81.5
156
Text-to-Image RetrievalCUHK-PEDES (test)
Recall@112.4
114
ClassificationEuroSAT
Top-1 Accuracy49.1
26
ClassificationEuroSAT (test)
Top-1 Acc51.4
24
Image-to-Text RetrievalCUHK-PEDES (test)--
24
ClassificationCAMELYON
Accuracy70.6
20
ClassificationCAMELYON (test)
Accuracy68.3
20
Text-to-image person retrievalRSTPReid (test)--
17
Text-to-Image RetrievalFashion (test)
Retrieval Accuracy3.1
10
Showing 10 of 14 rows

Other info

Follow for update