Manuscript Offprint
arXiv:2611.05208Privacy for Free in Efficient Agnostic Halfspace Learning
Open access. PaperVantage converted this article to text, so layout and figures may differ from the original.
Abstract
We provide the first computationally efficient, differentially private algorithms for agnostically learning halfspaces. In particular, we study three different settings of agnostic learning: improper learning under Gaussian and log-concave marginals; proper learning under Gaussian marginals; and semi-agnostic learning under Gaussian marginals. In all three aforementioned settings, the added cost in the sample complexity due to privacy matches the respective non-private sample complexity, implying that we get privacy for free.
1 Introduction
Learning halfspaces is a classical problem in learning theory. A halfspace is specified by a weight vector and a threshold , and classifies a point according to . We write for the distribution of labeled examples and for its input marginal. In classical realizable PAC learning, the distribution is assumed to be linearly separable and the learner is required to output a classifier with for any accuracy parameter . In the agnostic setting, the labels in the dataset may be arbitrary. Thus, the guarantee is relaxed to requiring the learner to output a classifier with error
where OPT is the minimum error achievable by a halfspace under . This setting allows the data to be noisy or imperfectly separable by a linear decision boundary. Differential privacy (DP) (Dwork et al., 2006) imposes an additional constraint, requiring the distribution of the learner's output to change only slightly when a single training example is replaced. In this paper, we study whether agnostic halfspace learning can be made differentially private with small computational and statistical overhead relative to non-private learning.
Agnostically learning halfspaces is known to be computationally hard, even for non-private improper learners, i.e., learners whose output need not be a halfspace (Tiegel, 2023). To overcome this, a rich line of work has focused on distributions with structured marginals but arbitrary labels. Under Gaussian and more generally log-concave marginals, Kalai et al. (2008) provided the first algorithm for agnostic learning of halfspaces whose runtime is polynomial in the dimension for every fixed accuracy. For Gaussian marginals, their complexity scales as which was later improved to by Diakonikolas et al. (2010). However, their algorithm was improper. A proper algorithm must output a halfspace and can be desirable because a linear halfspace offers a more compact and interpretable representation of the classifier with parameters. For Gaussian marginals, Diakonikolas et al. (2021a) provided the first agnostic proper learner for halfspaces
Authors are listed in alphabetical order.
| Marginal | Learner | Error | Sample complexity |
|---|---|---|---|
| Gaussian | Improper | OPT+ | |
| Log-concave | Improper | OPT+ | |
| Gaussian | Proper | OPT+ | |
| Gaussian | Proper |
Table 1: The rows correspond, respectively, to Theorem 2.1, Theorem D.1, Theorem 3.1, and Theorem 4.1. Here, and match known rates in the non-private setting (Diakonikolas et al., 2010; Kalai et al., 2008), and suppresses polylogarithmic factors.
with somewhat comparable statistical and computational complexity. For DP agnostic learning, Kasiviswanathan et al. (2008) provided the first agnostic private learners for finite classes with sample complexity scaling logarithmically in the size of the hypothesis class. Alon et al. (2020) and Li et al. (2025) provided general reductions from agnostic learning to realisable learning. However, their reductions are not shown to be computationally efficient. For halfspaces over finite domains, Beimel et al. (2019) provided efficient private agnostic learners, but over infinite domains such as , distribution-free private learning of halfspaces is information-theoretically impossible even in the realisable setting due to their infinite Littlestone dimension (Bun et al., 2015; Alon et al., 2019). Distributional assumptions on the marginal are therefore essential for both privacy and computational efficiency. Given the non-private agnostic learners under structured marginals (Kalai et al., 2008; Diakonikolas et al., 2021a), our goal in this work is to obtain matching statistical and computational complexities under differential privacy.
However, even under Gaussian marginals, the dependence on statistical and therefore computational complexity is likely unavoidable for approaches using polynomial regression due to known SQ lower bounds (Diakonikolas et al., 2021b; Goel et al., 2020). A natural relaxation for the problem is semi-agnostic proper learning, which allows halfspaces with
where is a known universal constant. Non-private learners, under Gaussian marginals, can achieve this guarantee in time polynomial in both and simultaneously (Diakonikolas et al., 2022). This raises the natural question of whether the polynomial dependence on can be maintained for semi-agnostic learning under privacy. Together, these lead to the following question:
What statistical and computational guarantees can DP algorithms get under Gaussian marginals for i) agnostic improper, ii) agnostic proper, and iii) semi-agnostic proper learning of halfspaces ?
Agnostic Improper learning. Our first result in Section 2 gives a private improper agnostic learner under the standard Gaussian marginal. The algorithm relies on private polynomial regression using clipped Hermite features of degree . A key step is to control the effect of clipping on the error and then convert the expected excess-loss bound to a high-probability one. This achieves an error at most with high probability using sample complexity
The first term in Equation (1) is the statistical cost of the problem due to finite samples and the second term is the cost due to privacy. In Appendix D, we extend this approach to known log-concave marginals using , incurring an additional factor in the privacy term of Equation (1) (as shown in Table 1).
Agnostic Proper learning. In Section 3, we give a proper DP learner for halfspaces under Gaussian marginals with error at most . As shown in Table 1, its sample size is
The learner works by first estimating a polynomial privately, similar to the improper case, which gives the first two terms in Equation (2). Then we show that this polynomial can be used to obtain a subspace of dimension which contains a halfspace with error close to OPT. Finally, creating a discrete cover of halfspaces supported on this space, and using the exponential mechanism leads to the final output. This subspace creation, discretisation, and exponential mechanism costs the last two terms in Equation (2).
Semi-Agnostic Proper learning. In Section 4, we give a proper learner under Gaussian marginals with error at most . The sample complexity, as described in Table 1, is
The learner works by utilizing a privatized semi-agnostic learner from Diakonikolas et al. (2022) that provides the error guarantee of , where is known a priori. However, since we do not know what is, we search over a small candidate set of 's by using the said privatized learner, and then pick the best hypothesis using the exponential mechanism on a fresh validation set.
Remark 1. Note that . We fix for both improper and proper agnostic settings, such that it is the smallest guaranteeing the existence of the polynomial bases that accurately approximate halfspaces. In other words, we use the same as required by the known non-private counterparts of our algorithms (Diakonikolas et al., 2010; Pesenti et al., 2026). Thus, whatever exponent has in the sample complexity of the respective non-private learners, we achieve that, while keeping the additional cost in poly explicitly outside the exponent of .
Remark 2. We additionally note that the added cost in our sample complexity due to DP matches the non-private sample complexity (terms without or ) for each of the three Gaussian settings above when . In that sense, we get privacy for free. This is commonly observed in DP statistical estimation (see, e.g., Karwa and Vadhan (2018); Kamath et al. (2019)), and such sample complexity is often tight for various problems, such as mean and covariance estimation (Kamath et al., 2022).
Notation. We denote the class of halfspaces by . For a classifier , its population error is and, given a sample , its empirical error is
. Unless stated otherwise, the input marginal is ; the only exception is our result for log-concave marginals (Theorem D.1). We define . For a function and , we write . The formal definition of differential privacy and associated properties are given in Appendix B.2.
2 Private Improper Agnostic Learning
In this section, we give a differentially private algorithm for agnostically learning halfspaces under Gaussian marginals. We build on the polynomial regression algorithm of Kalai et al. (2008), which fits a low-degree polynomial to the labels and then thresholds its predictions.
To privatize this approach, we need two additional properties. We first need a bounded domain that contains the coefficients of a good polynomial approximation to every halfspace. Working in the orthonormal Hermite basis, the unit-norm approximation guarantee of Lemma B.10 allows us to restrict the coefficient vector to the Euclidean unit ball. Second, we need uniformly bounded feature norms so that the regression loss is Lipschitz in the coefficient vector. We obtain this by clipping the feature vectors. This increases the population loss by at most the probability of clipping, which we bound in Lemma C.2. These two properties allow us to fit the coefficients using private convex optimisation (Kulkarni et al., 2021). We then repeat the DP optimisation step on independent samples to boost its success probability and use the exponential mechanism (McSherry and Talwar, 2007) to privately select among the resulting thresholded classifiers. Our main result is stated as follows.
Theorem 2.1 (DP improper agnostic learner for Gaussian marginals). Let . Set for a sufficiently large universal constant , and . Suppose , where is a sufficiently large universal constant. Let be any distribution on with marginal . Then Algorithm 1 is -DP. Given
i.i.d. samples from , it returns a classifier satisfying with probability at least . The algorithm runs in time poly.
The two terms in the sample complexity arise from statistical estimation and private optimization, respectively. When , the privacy term is absorbed into the statistical term, so privacy is free up to logarithmic factors. The sample complexity matches the dependence on of known algorithms for non-private agnostic learning of halfspaces under Gaussian marginals (Diakonikolas et al., 2010). Moreover, the cost is necessary in the statistical query model, even without privacy (Diakonikolas et al., 2021b). In Appendix D, we extend the method to log-concave marginals and establish an analogous guarantee.
2.1 The Algorithm
We represent each input by its feature vector of normalized Hermite polynomials (O'Donnell, 2014) of degree at most . The degree suffices to approximate every halfspace in up to error (Diakonikolas et al., 2010). To bound the influence of any single example and make the regression loss Lipschitz in its coefficients, we clip the feature vectors to norm at most : . Then, by Lemma C.2, the
Algorithm 1 Private polynomial regression
Require: Sample of size ; parameters .
1: Set , , , , and as in (14b)–(14c).
2: Partition into training blocks of size and a validation block of size .
3: for do
4: output of the -DP optimizer on over .
5: end for
6: For , set and .
7: Sample with probability proportional to .
8: return .
clipping probability is at most . Given a sample , the regression step approximately minimizes the empirical loss
over the unit ball . This loss is convex and -Lipschitz in , so we apply the private convex ERM algorithm of Kulkarni et al. (2021), restated in Lemma B.4. A potential alternative approach is to implement polynomial regression using statistical queries (Kearns, 1998) and then simulate these queries privately (Kasiviswanathan et al., 2008). For the clipped regression problem of Equation (4), these queries can estimate the expected subgradients. However, making this SQ implementation explicit and replacing its query answers with actual private estimates leads to an algorithm with basically the same structure as ours. For this reason, we do not write the SQ version of this algorithm here.
Next, the regression guarantee holds in expectation, so we repeat the regression step on independent training blocks to ensure that at least one output has small population loss with high probability. Specifically, Algorithm 1 first partitions the sample into training blocks of size and a validation block of size . It runs the private optimizer on each training block to obtain coefficient vectors with scores , and then thresholds them at evenly spaced points in to produce candidate classifiers. Finally, it selects one candidate using the exponential mechanism (McSherry and Talwar, 2007), scoring each candidate by its fraction of misclassified validation examples. Repeating the regression step on blocks boosts its success probability, and the validation step chooses the coefficient vector and the threshold jointly.
2.2 Analysis
In this section, we outline the accuracy analysis; the full accuracy and privacy proofs are deferred to Appendix C. Define the population loss and its minimum over the unit ball . For a universal constant , we first compare the minimum regression loss with the error of the best halfspace:
We then show that the algorithm returns a classifier whose error satisfies
with probability at least . Together, these give with the same probability.
We begin with Equation (5), which compares the clipped regression problem with the best halfspace. Fix . By Lemma B.10 (Diakonikolas et al., 2010; Pesenti et al., 2026), there is a polynomial with and . Let , so that . Since with , and ,
The first inequality follows by adding and subtracting and applying the triangle inequality. Taking expectations gives
The three terms are the classification error of , the polynomial approximation error, and the clipping bias. Since , Lemma C.2 bounds the last term by . Clipping thus enters only through its probability. The approximation error is also at most , so . As , we have , and taking the infimum over gives (5).
For Equation (6), we first show that at least one of the regression runs is nearly optimal. The loss is convex and -Lipschitz and thus for each training block, Lemma B.4 from Kulkarni et al. (2021) bounds the expected optimization error. Then, standard Rademacher complexity bound for linear predictors under loss (Lemma B.7), applied with , bounds the expected deviation between the empirical and population losses. We choose so that these two contributions sum to at most (see (14b)), giving
where the expectation is over and the optimizer's randomness. Since lies in the unit ball, its excess loss is non-negative. Markov's inequality therefore gives with probability at least . The runs are independent, so with probability at least , some run satisfies this bound.
We next show that thresholding this run yields a good candidate classifier. For any fixed regression output , a uniformly random threshold gives expected classification error at most , where the expectation is over (Kalai et al., 2008, see also Fact B.6). Rounding to the midpoint of its grid interval makes it uniform over the grid thresholds and increases the expected classification error by at most . Thus, at least one grid threshold has error no larger than this average. On the event that some run satisfies this loss bound, we have that
This establishes that the candidate set contains a good classifier. It remains to select one privately. The algorithm uses the exponential mechanism on the independent validation sample to select among the candidate classifiers. By Lemma B.5, with as in (14c), the selected classifier has error at most above the best candidate with probability at least . A union bound over the training and validation failure events proves Equation (6).
Finally, since and , the choices of and give the sample bound of Theorem 2.1. Computing the features, running the private optimizers, and evaluating the candidates on take poly arithmetic operations. The detailed proof, along with privacy and runtime calculations appear in Appendix C.
Remark 3. The dimension assumption in Theorem 2.1 allows us to use the clipping radius . To obtain a guarantee in every dimension, we instead take for a sufficiently small universal constant . Orthonormality and Markov's inequality give
Replacing Lemma C.2 with this bound, the same analysis (see Appendix C) establishes the learning guarantee of Theorem 2.1 for every . The statistical term in the sample complexity remains unchanged, and the privacy term acquires an additional factor.
3 Private Proper Agnostic Learning
The agnostic learner in Section 2 is improper since its output need not be a halfspace. In this section, we provide a private proper learner that outputs a halfspace in . A halfspace requires only parameters, compared to coefficients for the improper hypothesis, and is faster to evaluate on a point and also easier to interpret.
We will adapt the low-rank subspace reduction of Diakonikolas et al. (2021a) to design the learner. First, it constructs a finite class of halfspaces from a polynomial with sufficiently small excess squared loss. The resulting class is guaranteed to contain a halfspace whose error is close to the best halfspace. Once we have this finite class of halfspaces, we use the exponential mechanism (McSherry and Talwar, 2007) to privately select a halfspace from it. Our main result is stated below.
Theorem 3.1 (DP proper agnostic learner). Let and . Set for a sufficiently large universal constant and a sufficiently small universal constant , let , and suppose that for a sufficiently large universal constant . Let be any distribution on with marginal . Then Algorithm 2 is -DP and, given
i.i.d. samples from , returns a halfspace satisfying with probability at least . The algorithm runs in time .
A proof sketch appears at the end of this section, and the full proof is given in Appendix E. We use a strengthened version of the subspace reduction of Diakonikolas et al. (2021a), reducing the polynomial degree from to . This reduces the subspace dimension from to and yields a smaller finite class for the exponential mechanism. We also extend the reduction to labels in . Lemma 3.2 states this guarantee.
Thus, our sample bound has the same dependence on the dimension as non-private improper agnostic learning under Gaussian marginals (Diakonikolas et al., 2010), while returning a halfspace. When , the privacy terms are absorbed into the statistical terms , up to logarithmic factors. In this regime, privacy comes essentially for free.
The factor in the running time arises from constructing and searching a finite cover of halfspaces of at most this size, so the running time is polynomial in for every fixed accuracy . The non-private proper learner of Diakonikolas et al. (2021a) also searches such a cover, and its running time likewise includes a term exponential in .
Lemma 3.2. There exist universal constants such that the following holds. Let have any joint distribution with and . Fix , and set . Let denote the space of polynomials on of degree at most . Suppose that satisfies
Using just and , we can construct a finite class of halfspaces satisfying , such that, for every , there exists with .
The proof is stated in Appendix E. A natural idea is to obtain the polynomial from our private improper learner in Theorem 2.1. However, the coefficients obtained in each regression run of Algorithm 1 only satisfy the following guarantee:
which does not imply the excess squared-loss bound in Equation (8). Moreover, the function is a linear combination of clipped Hermite features and therefore need not be a polynomial as required in Lemma 3.2. We therefore need a different private polynomial construction that directly controls excess squared loss.
3.1 Constructing a private polynomial with small excess squared loss
To construct the polynomial, we propose a simple estimator based on the correlations between the labels and the Hermite features. For squared-loss regression, these correlations give the coefficients of the optimal polynomial (see Lemma 3.3 below). However, clipping changes the correlations between the labels and the Hermite features. Write for the original correlation vector and for the correlation vector computed using clipped features. Then
where the first inequality uses Cauchy–Schwarz and orthonormality of Hermite functions, and the last inequality uses bound on the clipping probability from Section 2 (see Lemma C.2). Thus, a bound on the difference between the original and clipped correlations only gives an bound on excess squared loss, whereas Lemma 3.2 requires an excess squared loss. Therefore, we need our estimated coefficients to be within of the optimal coefficients.
We show that this can be achieved by constructing the polynomial for the clipped labels , using the loss . Note that . Then, the corresponding correlation vector is . By orthonormality of the Hermite basis, is exactly the coefficient vector minimizing over .
Lemma 3.3. Let , let , and write . The polynomial is the unique minimizer of over .
Proof of Lemma 3.3. Every polynomial in can be written as for some . Using orthonormality of the Hermite basis, we get . Then,
(9)
Algorithm 2 Private proper learning of Gaussian halfspaces
Require: Sample of size , accuracy , failure probability , and privacy parameters .
1: Set , , and , where is a sufficiently small universal constant.
2: Split into disjoint blocks of size each, independently of the sample values.
3: Draw with .
4: and set .
5: Construct using the construction in Lemma 3.2 with accuracy .
6: Sample with probability proportional to .
7: return .
The first two terms do not depend on . Thus, the loss is minimized uniquely at .
Thus, our goal is to estimate privately. For any estimate , using Equation (9), we get that the polynomial satisfies
It therefore suffices to estimate a coefficient vector such that for some constant . The regression step in Algorithm 2 (Step 4) estimates these correlations using the Gaussian mechanism and projects the estimate onto the coefficient unit ball. Since , projection cannot increase the estimation error. The following lemma gives the guarantee for the resulting polynomial.
Lemma 3.4. Let and . Let be the polynomial constructed in Step 4 of Algorithm 2, using the independent samples in . Its release is -differentially private, and on every run. If , then, with probability at least ,
The proof is given in Appendix E.
3.2 Constructing the finite set of halfspaces
We now use the polynomial computed in Step 4 of Algorithm 2 to construct a finite class of halfspaces. On the event in Lemma 3.4, this polynomial satisfies the squared-loss condition (Equation (8)) of Lemma 3.2 with accuracy . We therefore apply Lemma 3.2 in Step 5 to construct . The full algorithm and proof are given in Appendix E. The algorithm follows the subspace and discretization construction of Diakonikolas et al. (2021a). Specifically, we compute
and take to be the span of its eigenvectors with eigenvalues at least . They show that the resulting subspace has dimension . Discretizing unit normal vectors in gives a finite class of halfspaces satisfying . All these operations use only and the known Gaussian marginal, so Algorithm 2 preserves DP by post-processing (Lemma B.3).
Lemma 3.4 guarantees the polynomial has small excess squared loss for the clipped labels . Lemma 3.5 next translates this guarantee into classification error for the original labels.
Lemma 3.5. Suppose that for a sufficiently large universal constant and is the constant in Lemma 3.2. Let and be constructed by Algorithm 2. If satisfies Equation (10),
Proof. On the event in the lemma, Lemma 3.2 gives, for every halfspace , an satisfying . Since
it remains to bound the last term. As outside the clipping event, Lemma C.2 gives when and .
Thus, contains a halfspace with error at most .
3.3 Selecting the best halfspace
Finally, Algorithm 2 selects a halfspace from using the exponential mechanism, with scores equal to the negative empirical errors on . These errors are measured against the original labels . Conditional on the released polynomial, is fixed and independent of . By Lemma B.5, this selection adds at most error with probability at least , provided
Combining this with Lemma 3.4 and taking sufficiently small gives error at most , with probability at least . The private regression step uses , while the exponential mechanism uses the disjoint block , each of size . Therefore, post-processing and parallel composition give -privacy for Algorithm 2.
Proof Sketch of Theorem 3.1. Algorithm 2 is the proper private learner achieving the guarantee in Theorem 3.1. Its output belongs to , so it is proper. Lemma 3.4 guarantees that Algorithm 2 outputs a polynomial satisfying Equation (8) in Lemma 3.2 with accuracy , with probability at least . Thus, Step 5 constructs from a subspace of dimension . Lemma 3.5 ensures that it contains a halfspace with error at most . When the sample size satisfies Equation (11), the exponential mechanism adds at most error with probability at least by Lemma B.5; a union bound and sufficiently small give the claimed accuracy. Adding the validation sample cost to the sample cost in Lemma 3.4 gives the stated sample complexity.
For privacy, note that Step 4 is -DP by Lemma 3.4, Step 5 is post-processing, and Step 6 is -DP on by exponential mechanism, conditioned on the released polynomial. Since and are disjoint, parallel composition makes the entire algorithm -DP.
4 Private Proper Semi-Agnostic Learning
In this section, we provide a DP algorithm for proper semi-agnostic learning of halfspaces whose sample complexity is polynomial in and , rather than exponential in as in Theorems 2.1 and 3.1. The difference between semi-agnostic and agnostic error guarantee is that the former allows a universal constant factor multiplying OPT. We use a privatised version of the non-private gradient descent (on a non-convex function) algorithm of Diakonikolas et al. (2022) as a subroutine. Roughly speaking, given an upper bound , this private subroutine (Algorithm 3) returns a halfspace with error . Then, our main algorithm (Algorithm 4) searches over a small set of candidate values of and selects a hypothesis using the exponential mechanism. We state our main result below and defer the privacy proof and technical details of the accuracy analysis to Appendix F.
Theorem 4.1 (DP semi-agnostic proper learner). Let . Let be any distribution on with marginal . Then Algorithm 4 is -DP and, given
i.i.d. samples from , where , it returns a halfspace satisfying with probability at least , where is a universal constant. The algorithm runs in time poly.
We make the above assumption on (Appendix F.2) for ease of exposition. It can be removed by setting the clipping parameter in Algorithm 3 to a tighter bound of , thus simply introducing more polylog terms in the sample complexity that we already omit in our presentation.
4.1 The Algorithm
We first describe the subroutine in Algorithm 3, which takes a known upper bound and performs gradient updates using a ramp loss. For and , define
Algorithm 3 follows Algorithms 1 and 2 from Diakonikolas et al. (2022), with noise added to the computations that access the dataset. The algorithm needs to privately estimate two quantities from the dataset before running gradient descent: the threshold parameter and the initial weight vector . Diakonikolas et al. (2022) first estimate the threshold from the average of the labels in , using the inverse Gaussian CDF. We privatise this average by adding Laplace noise, obtaining the threshold estimate in Algorithm 3. Next, we compute the initial weight vector by adding Gaussian noise to the average of over in Algorithm 3. The algorithm then keeps fixed, and performs gradient descent using the ramp function in Equation (12) and the private threshold , with a fresh block in each iteration. Algorithm 3 adds Gaussian noise to each empirical gradient before performing the gradient update.
With these modifications, Algorithm 3 privately returns a hypothesis with population classification error whenever , as shown in Proposition 4.2. Since OPT is unknown, Algorithm 4 tries a geometric grid of candidate values . For each , it runs Algorithm 3 on a separate subset of the data to obtain a hypothesis . The grid is chosen such that at least one of these hypotheses has error with high probability. The algorithm then uses the exponential mechanism on a separate validation set to select a hypothesis whose empirical classification error is close to the smallest among these candidates.
Algorithm 3 DP Semi-Agnostic Subroutine DPSAS
Require: Dataset of labelled examples, privacy parameters , and error parameter .
Partition Dataset and Clip for DP
1: and .
2: Partition into , each of size .
3: and clip each feature vector in to have norm at most .
Privately computing threshold .
4: for a universal constant and ,
where .
5: .
Privately computing initial weight .
6: ,
where and .
7: if , otherwise uniformly at random.
Run DP online gradient descent.
8: and .
9: for to do
10: , , and .
11: .
12: and ,
where .
13: end for
14: Return .
4.2 Accuracy
A major component for proving the utility for Algorithm 4 is proving the accuracy guarantees for Algorithm 3. Note that by construction, for all . In the presentation for the rest of Section 4.2, we will omit the subscript from to refer to the parameter in Algorithm 3. We write for the number of examples in each of the disjoint blocks used by the algorithm; the total sample size for one run is .
Proposition 4.2. Let and . Let be any distribution on with marginal and . Then Algorithm 3 is -DP and, given
i.i.d. samples from in each of its blocks, where for the total sample size , returns a halfspace satisfying with probability at least , where is a universal constant.
We follow the utility analysis of Diakonikolas et al. (2022), with modifications to account for the noise added for privacy. Their analysis starts with a weight vector that makes an angle less than with the optimal halfspace . In each iteration, the gradient update reduces this angle until the weight vector is sufficiently close to to give the desired error guarantee. We first analyse these updates assuming that our private initialization satisfies this starting condition and that replacing the optimal threshold by our private estimate preserves a small classification and then prove it in Claims 4.5 and 4.6. They first prove population-level results, where they show that applying population-level gradients will slowly lead us to , and then use concentration bounds to show that the empirical gradients satisfy the estimates needed for convergence with high probability. We modify these empirical estimates to account for the additional noise added for privacy.
The first result describes the structure of the noisy gradient and the updated weight vector. Its proof is given in Appendix F.
Claim 4.3 (Modification of Claim C.2 from Diakonikolas et al. (2022)). For any unit vector , the DP gradient rule from Algorithm 3 with loss and stepsize corresponds to the update:
such that , where and .
Next, we prove the DP analogue of Lemma C.12 from Diakonikolas et al. (2022) and show that the original additive error guarantees are not affected by the added noise for DP. We keep the notation consistent with theirs, and define and . Our GD algorithm outputs , where is the Gaussian noise (as in Claim 4.3).
Lemma 4.4 (Modification of Lemma C.12 from Diakonikolas et al. (2022)). Let . Assuming that
we have with probability at least that for any unit vector , such that , the following hold:
and
Proof. The proof remains the same, except for accounting for the error due to Gaussian noise. This lemma is applied on independent dataset in each iteration . We use the notation in this case as a shorthand for , since we are omitting the subscript everywhere. For the first part, Diakonikolas et al. (2022) show the first line of the following.
Our private sample complexity allows with probability at least (via concentration of high-dimensional Gaussians). Therefore, this direction of the proof follows by following the remaining steps of the proof from Diakonikolas et al. (2022).
We justify the norm bound separately. Let and , so that . Also, define the population and empirical masses of the band by and , respectively. If , the claim is immediate. Otherwise, define . On the same concentration event on used above, and the argument in Diakonikolas et al. (2022), writing , their argument gives, for every unit vector ,
If , the desired bound is immediate. Otherwise, take . If , then
If , then, since ,
and hence . Thus, in either case . The bound implies
as claimed.
Now, writing , we get using Lemma C.3 from Diakonikolas et al. (2022). They then condition on the event on which Lemma C.12 holds, and apply the directional result of Lemma C.12 to . Hence, the only direction needed in their argument satisfies the positivity condition required by our restricted statement. This lower bound on is then converted into a lower bound on , and, together with the norm bound from Lemma C.12, is used to verify the hypotheses of Corollary C.8 and get contraction of the angle between the iterate and .
Next, we show that the DP initialization in our algorithm satisfies the constraints that are needed in the proof of Theorem 1.2 from (Diakonikolas et al., 2022). They require that the dot product of the true weight with our initialization be strictly more than 0.
Claim 4.5. Suppose . Then, with probability at least , if
the private initializer satisfies .
We only invoke Claim 4.5 in the above non-trivial regime. In the complementary case , the argument of Diakonikolas et al. (2022) already implies that using the threshold with any unit normal vector yields classification error . Hence, no positive-correlation initialization guarantee is needed in this case. Finally, we bound the error on our noisy empirical threshold.
Claim 4.6 (Modification of Claim C.9 from (Diakonikolas et al., 2022)). Suppose , and is a unit vector and is a threshold, such that . Suppose for is the DP estimate of the threshold output by Algorithm 3. If
then with probability at least ,
Proof. Diakonikolas et al. (2022) show that satisfying in the proof of Claim C.9 is enough, which is what we need, as well. Thus, suffices for us, and the rest of the argument follows. We additionally clip the argument of to , where for a sufficiently small universal constant .
Let and . Since is sampled from Laplace distribution with parameter , by the concentration of Laplace distribution, with probability at least . For this to be upper bounded by , having suffices. For any . Hence, the clipping introduces at most an additional error. In particular, taking , the above concentration guarantee implies . Since , the remainder of the proof of Claim C.9 follows as before.
4.3 Putting It All Together
Proof of Proposition 4.2. As mentioned earlier, our modifications are needed only for dataset-level results. Claims C.2 and C.9, along with Lemma C.12, are the only ones that needed modifications. Note that the technical results in Appendices B and C from Diakonikolas et al. (2022) still hold when we are using independent samples for threshold estimation, initialization, and each iteration of gradient descent, so they transfer to our private case, as well. We have shown via Claims 4.3 and 4.6, and Lemma 4.4, respectively, that at minimal cost in sample complexity, those results hold. Additionally, they prove that their initial weight vector is not too far in terms of angle from . We prove in Claim 4.5 that the same holds for our noisy initialization . With these necessary modifications, our proof of accuracy is complete.
The grid in Algorithm 4 starts at , where is a universal constant, and uses for . The dataset is partitioned into a validation set and subsets . For each , the subroutine is run on with parameter to obtain .
Proof of Theorem 4.1. Proposition F.1 provides the privacy guarantees. Now, we complete the proof of accuracy. First, note that the difference between the final error guarantee required to be in , but in Algorithm 4, we work with 's. The idea is that for all . Now, either OPT , or there must be a , such that . We claim that in either case, there exists at least one , for which has error .
When OPT < , then Algorithm 3 will return , such that the error of is at most with probability at least , where (Proposition 4.2). This satisfies the semi-agnostic learning guarantee even if OPT is much smaller than because .
On the other hand, suppose there exists , such that . Then with probability at least , for all , Algorithm 3 will return hypotheses , respectively, such that the total error is . Thus for , OPT. This means that should satisfy the semi-agnostic error guarantee with no additional additive error.
Combining the two together, with probability at least , there must exist , such that the semi-agnostic error of is at most . Now, we just need to show that the final hypothesis returned by Algorithm 4 is accurate. For that, we know that with probability at least , for all , the population error must be close to the empirical error on using Hoeffding's inequality; because of our sample complexity,
With probability at least , the exponential mechanism returns an , whose empirical error is at most in addition to the empirical optimal among all 's. From these two additional error sources, we get that has a population error of at most .
Finally, we bound the running time. Each run of Algorithm 3 uses every sample in its data a constant number of times (for clipping, the estimates of and , or one gradient step), at cost per use. Since the runs use disjoint data, all runs together take time. Scoring the candidates on takes time. Since , the total running time is .
5 Conclusion and Open Problems
We provide the first computationally efficient DP agnostic learners for halfspaces, where privacy comes for free in terms of sample complexity, i.e., the sample complexity overhead due to privacy matches that of the non-private learners. Specifically, we study three settings: improper agnostic, proper agnostic, and semi-agnostic. Our techniques are based on those of the non-private work, albeit with additional steps and analyses to incorporate clipping and noise injection to provide DP guarantees.
One avenue for improvement is in the improper agnostic setting, where we have to explicitly compute the orthonormal basis for each family of distributions when the marginals are known, unlike Kalai et al. (2008), who work with the standard polynomial basis for all families of distributions. The only parameter they need to know for their kernel is the degree of the polynomial. An interesting future direction is to find more versatile polynomial bases that admit bounded coefficients for a large family of distributions, or alternatively to learn such a basis privately from the data, removing the need to know the marginal in advance. Another direction is to design efficient DP algorithms for agnostic learning of concept classes beyond halfspaces. Finally, one could explore lower bounds in DP agnostic learning to determine the necessary sample complexity overhead for these problems.
Acknowledgements and AI Disclosure
The authors acknowledge the Novo Nordisk Foundation for support via the Startup grant (NNF24OC0 087820); AS additionally acknowledges support from VILLUM FONDEN via the Young Investigator program (VIL72069).
The main ideas underlying this work were developed by the authors. AI tools were used to help sharpen the parameter dependence of technical lemmas. The authors take full responsibility for the correctness of the results and the content of the final manuscript.
References
Noga Alon, Roi Livni, Maryanthe Malliaris, and Shay Moran. Private PAC learning implies finite Littlestone dimension. In ACM Symposium on Theory of Computing (STOC), 2019.
Noga Alon, Amos Beimel, Shay Moran, and Uri Stemmer. Closure properties for private classification and online prediction. In Conference on Learning Theory (COLT), 2020.
George E Andrews, Richard Askey, and Ranjan Roy. Special functions. 1999.
Pranjal Awasthi, Maria Florina Balcan, and Philip M Long. The power of localization for efficiently learning linear separators with noise. Journal of the ACM (JACM), 2017.
Raef Bassily, Mehryar Mohri, and Ananda Theertha Suresh. Differentially private learning with margin guarantees. In Advances in Neural Information Processing Systems (NeurIPS), 2022.
Amos Beimel, Shay Moran, Kobbi Nissim, and Uri Stemmer. Private center points and learning of halfspaces. In Conference on Learning Theory (COLT), 2019.
Mark Bun, Kobbi Nissim, Uri Stemmer, and Salil Vadhan. Differentially private release and learning of threshold functions. In IEEE Symposium on Foundations of Computer Science (FOCS), 2015.
Mark Bun, Roi Livni, and Shay Moran. An equivalence between private classification and online prediction. In IEEE Symposium on Foundations of Computer Science (FOCS), 2020.
Amit Daniely. A PTAS for agnostically learning halfspaces. In Conference on Learning Theory (COLT), 2015.
Amit Daniely. Complexity theoretic limitations on learning halfspaces. In ACM Symposium on Theory of Computing (STOC), 2016.
Ilias Diakonikolas, Daniel M Kane, and Jelani Nelson. Bounded independence fools degree-2 threshold functions. In IEEE Symposium on Foundations of Computer Science (FOCS), 2010. URL https://arxiv.org/abs/0911.3389.
Ilias Diakonikolas, Daniel M Kane, and Alistair Stewart. Learning geometric concepts with nasty noise. In ACM Symposium on Theory of Computing (STOC), 2018.
Ilias Diakonikolas, Daniel Kane, and Nikos Zarifis. Near-optimal SQ lower bounds for agnostically learning halfspaces and ReLUs under Gaussian marginals. In Advances in Neural Information Processing Systems (NeurIPS), 2020a.
Ilias Diakonikolas, Vasilis Kontonis, Christos Tzamos, and Nikos Zarifis. Non-convex SGD learns halfspaces with adversarial label noise. In Advances in Neural Information Processing Systems (NeurIPS), 2020b.
Ilias Diakonikolas, Daniel M. Kane, Vasilis Kontonis, Christos Tzamos, and Nikos Zarifis. Agnostic proper learning of halfspaces under Gaussian marginals. In Conference on Learning Theory (COLT), 2021a. URL https://proceedings.mlr.press/v134/diakonikolas21b.html.
Ilias Diakonikolas, Daniel M. Kane, Thanasis Pittas, and Nikos Zarifis. The optimality of polynomial regression for agnostic learning under Gaussian marginals in the SQ model. In Conference on Learning Theory (COLT), 2021b.
Ilias Diakonikolas, Vasilis Kontonis, Christos Tzamos, and Nikos Zarifis. Learning general halfspaces with adversarial label noise via online gradient descent. In International Conference on Machine Learning (ICML), 2022. URL https://proceedings.mlr.press/v162/diakonikolas22b.html.
Ilias Diakonikolas, Daniel Kane, and Lisheng Ren. Near-optimal cryptographic hardness of agnostically learning halfspaces and ReLU regression under Gaussian marginals. In International Conference on Machine Learning (ICML), 2023.
Charles F. Dunkl and Yuan Xu. Orthogonal Polynomials of Several Variables. 2014.
Cynthia Dwork and Aaron Roth. The algorithmic foundations of differential privacy. Foundations and Trends in Theoretical Computer Science, 2014.
Cynthia Dwork, Frank McSherry, Kobbi Nissim, and Adam Smith. Calibrating noise to sensitivity in private data analysis. In Theory of Cryptography Conference (TCC), 2006.
Vitaly Feldman, Parikshit Gopalan, Subhash Khot, and Ashok Kumar Ponnuswami. New results for learning noisy parities and halfspaces. In IEEE Symposium on Foundations of Computer Science (FOCS), 2006.
Spencer Frei, Yuan Cao, and Quanquan Gu. Agnostic learning of halfspaces with gradient descent via soft margins. In International Conference on Machine Learning (ICML), 2021.
G Freud, A Giroux, and QI Rahman. Sur l'approximation polynomiale avec poids . Canadian Journal of Mathematics, 1978.
Surbhi Goel, Aravind Gollakota, and Adam Klivans. Statistical-query lower bounds via functional gradients. In Advances in Neural Information Processing Systems (NeurIPS), 2020.
Venkatesan Guruswami and Prasad Raghavendra. Hardness of learning halfspaces with noise. SIAM Journal on Computing, 2009.
Wassily Hoeffding. Probability inequalities for sums of bounded random variables. Journal of the American statistical association, 1963.
Ziwei Ji, Kwangjun Ahn, Pranjal Awasthi, Satyen Kale, and Stefani Karp. Agnostic learnability of halfspaces via logistic loss. In International Conference on Machine Learning (ICML), 2022.
Adam Tauman Kalai, Adam R. Klivans, Yishay Mansour, and Rocco A. Servedio. Agnostically learning halfspaces. SIAM Journal on Computing, 2008. URL https://doi.org/10.1137/060649057.
Gautam Kamath, Jerry Li, Vikrant Singhal, and Jonathan Ullman. Privately learning high-dimensional distributions. In Conference on Learning Theory (COLT), 2019.
Gautam Kamath, Argyris Mouzakis, and Vikrant Singhal. New lower bounds for private estimation and a generalized fingerprinting lemma. In Advances in Neural Information Processing Systems (NeurIPS), 2022.
Haim Kaplan, Yishay Mansour, Uri Stemmer, and Eliad Tsfadia. Private learning of halfspaces: Simplifying the construction and reducing the sample complexity. In Advances in Neural Information Processing Systems (NeurIPS), 2020.
Vishesh Karwa and Salil Vadhan. Finite sample differentially private confidence intervals. In Conference on Innovations in Theoretical Computer Science (ITCS), 2018.
Shiva Prasad Kasiviswanathan, Homin K. Lee, Kobbi Nissim, Sofya Raskhodnikova, and Adam Smith. What can we learn privately? In IEEE Symposium on Foundations of Computer Science (FOCS), 2008.
Michael Kearns. Efficient noise-tolerant learning from statistical queries. Journal of the ACM (JACM), 1998.
Janardhan Kulkarni, Yin Tat Lee, and Daogao Liu. Private non-smooth ERM and SCO in sub-quadratic steps. In Advances in Neural Information Processing Systems (NeurIPS), 2021.
Bo Li, Wei Wang, and Peng Ye. Private realizable-to-agnostic transformation with near-optimal sample complexity. In Conference on Learning Theory (COLT), 2025.
Nathan Linial, Yishay Mansour, and Noam Nisan. Constant depth circuits, Fourier transform, and learnability. Journal of the ACM (JACM), 1993.
Nick Littlestone. Learning quickly when irrelevant attributes abound: A new linear-threshold algorithm. Machine learning, 1988.
Doron S Lubinsky. A survey of weighted approximation for exponential weights. arXiv preprint math/0701099, 2007.
Frank McSherry and Kunal Talwar. Mechanism design via differential privacy. In IEEE Symposium on Foundations of Computer Science (FOCS), 2007. URL https://doi.org/10.1109/FOCS.2007.66.
HN Mhaskar and EB Saff. Extremal problems for polynomials with exponential weights. Transactions of the American Mathematical Society, 1984.
Huy Lê Nguyễn, Jonathan Ullman, and Lydia Zakynthinou. Efficient private algorithms for learning large-margin halfspaces. In International Conference on Algorithmic Learning Theory (ALT). PMLR, 2020.
Ryan O'Donnell. Analysis of Boolean Functions. 2014.
Lucas Pesenti, Lucas Slot, and Manuel Wiedmer. Agnostic learning in (almost) optimal time via Gaussian surface area. arXiv preprint arXiv:2603.06027, 2026.
Shai Shalev-Shwartz and Shai Ben-David. Understanding machine learning: From theory to algorithms. 2014.
Shai Shalev-Shwartz, Ohad Shamir, Nathan Srebro, and Karthik Sridharan. Learnability, stability and uniform convergence. The Journal of Machine Learning Research, 2010.
Stefan Tiegel. Hardness of agnostically learning halfspaces from worst-case lattice problems. In Conference on Learning Theory (COLT), 2023. URL https://proceedings.mlr.press/v195/tiegel23a.html.
A Other Related Work
Agnostic learning under structured marginals. Without distributional assumptions, agnostically learning halfspaces is computationally hard, even for weak learning (Guruswami and Raghavendra, 2009; Feldman et al., 2006; Daniely, 2016; Tiegel, 2023). Building on the low-degree Fourier approach of Linial et al. (1993), Kalai et al. (2008) use polynomial regression to obtain improper agnostic learners for halfspaces with error OPT + under structured marginals, including Gaussian and log-concave distributions. The complexity of this approach is governed by the degree of polynomials needed to approximate halfspaces in . Under Gaussian marginals, Diakonikolas et al. (2010) improved the runtime of Kalai et al. (2008) from to by establishing sharper polynomial approximation bounds. This is essentially optimal: statistical-query algorithms require time (Goel et al., 2020; Diakonikolas et al., 2020a, 2021b), and a nearly matching lower bound holds for all polynomial-time algorithms under the subexponential hardness of Learning with Errors (Diakonikolas et al., 2023). However, this approach is improper, as the resulting classifier need not be a halfspace. Diakonikolas et al. (2021a) addressed this limitation by using polynomial regression to identify a subspace containing the normal vector of a near-optimal halfspace; this yields a proper learner with error OPT + and runtime .
Semi-agnostic learning. Motivated by these computational barriers, a related line of work improves computational efficiency by relaxing the agnostic error guarantee. For homogeneous halfspaces, Awasthi et al. (2017) developed a localization-based algorithm achieving error under isotropic log-concave marginals. Combining localization with polynomial regression, Daniely (2015) obtains an improper approximation scheme under the uniform spherical marginal, achieving error OPT + in time polynomial in and for every fixed ; Diakonikolas et al. (2021a) give a proper analogue under Gaussian marginals. Diakonikolas et al. (2020b) showed that non-convex SGD achieves error for homogeneous halfspaces under a broad family of marginals, including isotropic log-concave distributions. For general halfspaces under Gaussian marginals, Diakonikolas et al. (2018) obtained constant-factor guarantees, even in a stronger contamination model allowing corruption of both examples and labels, and Diakonikolas et al. (2022) developed the sample-efficient online gradient descent algorithm on which our private semi-agnostic learner builds. Complementary work studies convex surrogates for homogeneous halfspaces. Under well-behaved marginals, including isotropic log-concave distributions, Frei et al. (2021) obtain error using gradient methods on convex losses, while Ji et al. (2022) show that logistic regression alone cannot improve on this and obtain by adding a hinge-loss refinement step.
Private learning. Distribution-free private learning of halfspaces over infinite domains is impossible: already thresholds over are not privately learnable (Bun et al., 2015), and private learnability is characterized by finite Littlestone dimension (Littlestone, 1988; Alon et al., 2019; Bun et al., 2020). Over finite domains , Beimel et al. (2019) (improved by Kaplan et al. (2020)) give private agnostic learners whose sample complexity grows with . Generic private realizable-to-agnostic transformations (Alon et al., 2020; Li et al., 2025) are statistically efficient but not computationally efficient in general. Efficient private PAC learners exist under margin assumptions (Nguyên et al., 2020; Bassily et al., 2022), with guarantees stated for margin-based losses rather than OPT for the 0-1 loss.
B Auxiliary Results
B.1 Concentration Inequalities
Lemma B.1 (Vector Bernstein Inequality). Let be independent, mean-zero random vectors in . Suppose that almost surely for all , and let . Then, for every , with probability at least ,
B.2 Differential Privacy Tools
Definition B.2 (Differential privacy; Dwork et al., 2006). Let and . A randomized algorithm is -differentially private if, for every pair of datasets differing in a single example and every measurable set ,
Lemma B.3 (Post-Processing of DP; Dwork and Roth, 2014). If is -DP, and is any randomized function, then the algorithm is -DP.
Lemma B.4 (Private convex ERM; Kulkarni et al., 2021, Theorem 1.1). Let be a public, nonempty, compact convex set of Euclidean diameter , and let be a public convex -Lipschitz loss for every . For , , and , there exists an -DP algorithm under replacement adjacency such that, for every , its output satisfies
where , and the expectation is over the algorithm's randomness. The algorithm performs subgradient evaluations and Euclidean projections onto .
Proof. Compared to Kulkarni et al. (2021, Theorem 1.1), we use as an upper bound on the initialization distance and assume convexity and -Lipschitzness on all of , rather than only on the neighborhood required in the original statement. Their complexity guarantee implies subgradient evaluations in the stated parameter range, with at most as many Euclidean projections, since each iteration uses one projection and at least one subgradient evaluation.
Lemma B.5 (Validation via the exponential mechanism). Let , and let be classifiers independent of . For , select with probability proportional to . Conditional on the candidates, selection is -differentially private under replacement. For , with probability at least ,
Proof. Condition on the candidates. Hoeffding's inequality (Hoeffding, 1963) and a union bound give the first slack term, accounting for the deviations of validation errors from population errors for both the selected classifier and the best candidate. The score has sensitivity one, so the exponential mechanism ensures privacy and gives the second slack term, accounting for suboptimal selection based on empirical errors (McSherry and Talwar, 2007). Allocate failure probability to each bound.
B.3 Regression
Fact B.6 (Random thresholding; Kalai et al., 2008, Proof of Theorem 5). Let . For every and , we have .
Lemma B.7 (Uniform deviation for regression). Let be a fixed feature map such that . Let , and let be its empirical counterpart on . Then, for every ,
Proof. Let be i.i.d. Rademacher random variables, independent of . Symmetrization (Shalev-Shwartz and Ben-David, 2014, Lemma 26.2) and contraction for the 1-Lipschitz maps (Shalev-Shwartz and Ben-David, 2014, Lemma 26.9) give
By Jensen’s inequality, and since the cross terms vanish in expectation, the right-hand side is at most .
B.4 Gaussian Marginals
For a probability measure on and , we write and . The inner product on is .
Lemma B.8 (Hermite basis; O'Donnell, 2014, Proposition 11.33). Let be the normalized univariate Hermite polynomials, defined by
For each multi-index , define and . Then is a complete orthonormal basis of . In particular, is an orthonormal basis for the polynomials of total degree at most , with dimension .
Lemma B.9 (Mehler’s formula; Andrews et al., 1999, Eq. 6.1.13). Let be the multivariate Hermite polynomials, orthonormal in . For each multi-index , write . For every and ,
Lemma B.10 (Unit-norm polynomial approximation of halfspaces under Gaussian measure). Let , and let be the orthonormal Hermite basis of . There exists a universal constant such that for every and every halfspace , there is a polynomial of degree with and .
Proof. Write , where and . Let be the one-dimensional smoothing kernel of Diakonikolas et al. (2010, Section 4), and define .
By Pesenti et al. (2026, Section 4.2), for every , there exist and an integer , with independent of , such that satisfies
where is the -orthogonal projection onto polynomials of degree at most .
Since (Diakonikolas et al., 2010, Lemma 4.4), we have
Hence .
Set . Its degree is at most , so for some coefficient vector (Lemma B.8). Since , we have for . Thus, the approximation error and norm of under equal those of under . Finally, orthonormality yields .
Fact B.11 (Euclidean covers; Diakonikolas et al., 2021a, Fact 21). For every and , the unit sphere in has an explicit -cover in of size at most , where is a universal constant.
Fact B.12 (Gaussian halfspace discretization; Diakonikolas et al., 2021a, Fact 22). Let , let be unit vectors, and let . Then and . Moreover, if , then .
B.5 Log-Concave Marginals
A probability measure is log-concave if its density is of the form , where V is convex. Log-concavity is preserved under linear projections, and log-concave distributions have finite moments of all orders. We use the following quantitative density bound for standardized one-dimensional log-concave distributions.
Fact B.13 (Bound on the density of log-concave distributions; Kalai et al., 2008, Lemma 6). Let be a log-concave distribution on with mean zero and variance one. Then its density satisfies for all .
The next two results concern weighted polynomial approximation on with the exponential weight function. They are not specific to log-concave measures. We use them, together with Fact B.13, in the proof of Lemma D.3. Let denote the norm with respect to the Lebesgue measure, and let .
Lemma B.14 (Weighted Nikolskii inequality; Lubinsky, 2007, §9). There is a universal constant such that, for every and every univariate polynomial of degree at most ,
Lemma B.15 (Weighted Jackson estimate; Freud et al., 1978, see also Lubinsky, 2007, §5). Let . There exists a universal constant such that, for every and integer , there is a polynomial of degree at most satisfying
Proof. Set . By Freud et al. (1978, Theorem 2.2), taking , there exists a polynomial of degree at most satisfying
To bound the first term on the right hand side, first observe that . Using the fundamental theorem of calculus, we obtain . Next, and differ only when lies between and . On this interval, their difference has absolute value 2. Since , . Finally, adding and subtracting and applying the triangle inequality gives
For the remaining terms, gives and . Substituting these estimates yields . All constants are independent of and .
C Proofs for Improper Learning with Gaussian Marginals
In this section, we prove Theorem 2.1. We first establish the privacy guarantee of Algorithm 1.
Proposition C.1. Algorithm 1 satisfies -DP under replacement of one labeled example.
Proof. The feature map, the partition into blocks, and the algorithm parameters are data-independent. For each example , the loss is convex and -Lipschitz, since . As the optimization domain is the public unit ball, Lemma B.4 implies that each regression run is -DP with respect to its training block.
All blocks are disjoint, and running the DP gradient descent algorithm with the same privacy parameters independently on each block guarantees -DP by the guarantees of Lemma B.4 and parallel composition. Our output space being defined for the remainder of the computations via 's does not violate DP because of post-processing (Lemma B.3). Finally, applying the exponential mechanism (Lemma B.5) on a disjoint validation block of data satisfies -DP. Therefore, by parallel composition, we obtain -DP.
Next, we establish a tail bound for the Hermite feature norm, which controls the bias introduced by clipping.
Lemma C.2 (Hermite feature norm tail bound). Let be integers and . Let enumerate the multivariate Hermite polynomials of degree at most , orthonormal in . Define . For every satisfying and ,
Proof. Write . Orthonormality gives . We claim that
Assuming this claim, Chebyshev's inequality gives
It remains to establish (13). For every integer , define . In particular, . To compute the second moment of , we use the generating function . Mehler's formula (restated in Lemma B.9) gives
Since , its moment-generating function gives, for sufficiently small ,
Expanding the last factor using the binomial series and comparing coefficients of yields
where , with . We therefore arrive at
where the first inequality follows from , together with and . Since , (13) follows.
We now turn to the proof of Theorem 2.1. We use Algorithm 1 with the degree-p Hermite feature map . Fix a universal constant and a sufficiently large universal constant , depending only on . Set
Since , choosing ensures that implies . Thus Lemma C.2 applies at level . Let be the smallest integer satisfying
and set
Proof of Theorem 2.1. Proposition C.1 establishes privacy. It remains to establish the accuracy, sample complexity, and running time bounds. Write , and recall the population regression loss , and its minimum . Additionally, for the training block , write for the empirical regression loss.
We first bound the expected excess regression loss of a single training run. Orthonormality and clipping give and . The loss is convex and -Lipschitz on all of , and the optimization domain is the public unit ball, of diameter 2. Fix a population minimizer , so that . Adding and subtracting and give
(15)
The inequality uses . Since is fixed and the examples in are sampled from , . Thus the final term in (15) has mean zero. Taking expectations over and the randomness of the private optimizer, Lemmas B.4 and B.7 therefore give
where the last inequality follows from the choice of in (14b).
We then use the standard confidence-amplification argument based on independent repetition; see, e.g., Shalev-Shwartz et al. (2010, proof of Theorem 26). By (16) and Markov's inequality, . Since the training runs are independent, . Thus, with probability at least ,
Next, we argue about the correctness of the choice of our threshold, which requires our grid over to be fine enough that the bias due to discretization is small, but not so fine that we blow up in terms of our sample complexity and running time when applying the exponential mechanism. If we select a threshold uniformly at random from the continuous interval , then Fact B.6 bounds the expected classification error under a uniform threshold by half the absolute loss. Then the expected 0-1 loss preserves our agnostic learning error requirements. However, rounding to the midpoint of its grid interval yields a threshold that is uniform over . At a fixed , rounding changes the prediction only if the score lies between and the midpoint is rounded to, which happens with probability at most . Hence, the expectation of the population error of over the random sampling from the discretized grid is . Since , conditioned on the event in (17) and taking the minimum over all 's, we have
Let denote the classifier selected by the exponential mechanism on . Conditional on the training outputs, Lemma B.5, with , , and as in (14c), gives with probability at least . Thus, with probability at least ,
which comes due to sampling and the noise due to the exponential mechanism.
We next compare with the error of the best halfspace. Fix . By Lemma B.10, and the choice of the degree in (14a), there is a polynomial with and . Write , so that . Since and ,
Taking expectations over a population example yields
Moreover, since , Lemma C.2, applied at level , gives . Since , we conclude that . Taking the infimum over gives
Combining (19) and (21), we obtain the desired
where the last inequality uses .
The choices in (14b) and (14c) satisfy
where the bound on uses . Since and , this yields the stated sample bound on .
Finally, we analyse the running time. Computing the clipped Hermite features requires arithmetic operations per example. Given these features, subgradient evaluation and projection onto the Euclidean unit ball each take time, so Lemma B.4 gives a total cost of for the private ERM runs. Evaluating the candidate classifiers on the validation sample requires operations. Thus, the overall running time is
since and .
D Private Improper Agnostic Learning: Log-Concave Marginals
We extend the learner of Section 2 to known, full-dimensional log-concave marginals. The regression, confidence amplification, thresholding, and private validation steps are unchanged. We replace the Hermite features by a polynomial basis that is orthonormal under the marginal. The approximation guarantee in Lemma D.3 allows us to restrict regression to a coefficient ball of constant radius. We use the known marginal to choose a clipping threshold that controls the additional regression loss while keeping the feature norms bounded.
Theorem D.1 (DP improper agnostic learner for log-concave marginals). Let and . Set for a sufficiently large universal constant , let , and let be as in (22). Let be any distribution on with a known, full-dimensional log-concave marginal . Then the modification of Algorithm 1 described in Appendix D.1 is -DP and, given
i.i.d. samples from , returns a classifier satisfying with probability at least . The algorithm runs in time , provided that constructing the orthonormal feature map, evaluating it at an input, and computing from public information each take time .
As we show in Remark 3, is an admissible clipping threshold. Consequently, the sample bound is at most .
D.1 The Algorithm
Let be a known, full-dimensional log-concave distribution on . We modify Algorithm 1 by replacing the Hermite features with a polynomial basis orthonormal under , choosing a clipping threshold adapted to , and changing the optimization domain. We increase the polynomial degree to achieve the required approximation accuracy. We keep , and as in (14a) and (14c), and replace the block size by (27). The private optimization procedure, independent repetitions, thresholding, and private validation remain unchanged. We discuss the changes to Algorithm 1 in greater detail in the remainder of this section.
First, for the existence of a polynomial with good approximating guarantees, we increase the degree for a sufficiently large universal constant . For the optimization domain, we replace the unit coefficient ball in Algorithm 1 with , where is the universal constant in Lemma D.3.
Next, we recall how to construct an orthonormal basis for the polynomials of degree at most in . Let be the vector of monomials of degree at most . Following the standard moment-matrix orthonormalization (Dunkl and Xu, 2014), define the population Gram matrix and set . The entries of are the moments of through degree . Log-concavity ensures that all moments are finite, while full dimensionality guarantees that is positive definite. Since is invertible, the coordinates of span the polynomials of degree at most . Moreover, , so they form an orthonormal basis of this polynomial space in . In particular, and . This construction based on the moment-matrix provides a general way to obtain the required orthonormal basis. When an explicit basis is available, it may be used directly without forming ,
The full-dimensionality assumption is without loss of generality since the marginal is known.
provided its construction and evaluation satisfy the computational assumption in Theorem D.1. For example, the normalized Hermite basis for the standard Gaussian marginal can be constructed and evaluated in poly() arithmetic operations.
Finally, we discuss clipping. As in the Gaussian case, we radially clip the feature vectors to obtain a uniform bound on their norms: . Since is known, we can choose the clipping threshold directly from the marginal. For a sufficiently small universal constant , set
where . The argument for (7) uses only orthonormality and therefore also applies to the present feature map. Since , the choice is admissible, and hence . Depending on the marginal and the parameter regime, marginal-dependent choices may yield a smaller threshold. For example, if and , Lemma C.2 shows that , so the privacy term improves to .
D.2 Analysis
In this section, we prove Theorem D.1. We first establish privacy.
Proposition D.2. The learner in Theorem D.1 satisfies -DP under replacement of one labeled example.
Proof. The feature map, clipping threshold, coefficient ball, and sample partition are public. Since , the loss is convex and -Lipschitz in on all of . Thus, each regression run is -DP by Lemma B.4. The neighboring-dataset argument in the proof of Proposition C.1 then applies unchanged, establishing -DP for the full learner.
We next prove the bounded-norm polynomial approximation guarantee. The key ingredient is the exponential density bound for one-dimensional log-concave distributions (Fact B.13), which allows us to transfer weighted polynomial approximation bounds to the and norms under the marginal. The result extends to arbitrary halfspaces by considering their one-dimensional projections.
Lemma D.3 (Bounded-norm polynomial approximation of halfspaces under log-concave measures). There exist universal constants such that the following holds. Let be a log-concave probability measure on . For every integer and halfspace , there is a polynomial of degree at most satisfying and . In particular, taking gives .
Proof. Consider a log-concave probability measure on with mean zero and variance one, and set . We will first prove that there exists a polynomial of degree at most satisfying
Assuming the above is true, we next extend it to . Write the halfspace . For , consider the mean and variance .^3 Let denote the distribution of the normalized random variable . Then is log-concave, with
Lemma C.2 is stated for Hermite features, but any two orthonormal bases of the degree- polynomials in differ by an orthogonal matrix, so is the same for both.
If b = 0, take .
mean zero and variance one. Apply Equation (23) to and set . Since and , this preserves the degree of the polynomial and yields and . Since , using the triangle inequality on gives
It remains to prove Equation (23). Let Then using Kalai et al. (2008, Lemma 6) (restated in Fact B.13), the density satisfies
Note that is the product of a sign function and an exponentially decaying weight, so . Then, the approximation theorem of Freud et al. (1978) (restated in Lemma B.15) gives a polynomial of degree at most satisfying
We now bound the error:
(26)
Here the first inequality follows from Hölder’s inequality and the second uses Equation (25) and triangle inequality. The third inequality follows from Mhaskar and Saff (1984, Theorem 3.1) (restated in Lemma B.14) and observing that . Now using and we can transfer Equations (25) and (26) to a norm with respect to measure induced by , to get Equation (23). This completes the proof.
We now turn to the proof of Theorem D.1. Fix as in (22). The block-size condition differs from the Gaussian case only through the radius and the threshold : let be the smallest integer satisfying
Proof of Theorem D.1. Proposition D.2 provides the privacy guarantee. We now prove the accuracy and running time bounds. Write and . The minimum exists since the domain is compact and the clipped loss is continuous in .
We first compare with the error of the best halfspace. Fix . By Lemma D.3, our choice of gives a polynomial such that and . Let . Since , (22) gives . Substituting this into (20) gives . Since , taking the infimum over yields
Next, we bound the expected excess regression loss of a single training run. The loss is convex and T-Lipschitz on all of , the optimization domain has diameter , and . Applying the decomposition in (15), we obtain
where the second inequality follows from Lemmas B.4 and B.7, and the last from (27).
Since the training runs are independent and the thresholding and validation steps use the same choices of , , and , the argument leading to (19) applies with . Consequently, using (28), with probability at least .
It remains to bound the sample size and running time. Since is a universal constant, (27) gives
independent of , and . The validation size is absorbed by this bound. Indeed, , and every point satisfies because the constant polynomial has unit norm. Hence, the expectation in (22) is at least , so . This proves the stated bound on . Since by (7), the bound is always at most .
Finally, we bound the running time, measured in arithmetic operations. By the computational hypothesis in Theorem D.1, computing and T takes operations. For each example, evaluating takes operations for the monomials and for the matrix-vector product, and clipping takes more. The remaining steps are those of Algorithm 1 with the unit ball replaced by . Projection onto this ball still takes operations, so, as in the proof of Theorem 2.1, the private ERM runs and the validation step take and operations, respectively. Since , the total is
where the last equality uses and .
E Proofs for Proper Learning with Gaussian Marginals
Proof of Lemma 3.2. We follow the subspace construction in the proof of Diakonikolas et al. (2021a, Proposition 5). Write . Let be the orthogonal projection of onto . The squared-loss identity gives . Since , we also have and . Consequently, for every ,
Set , and let be the span of its eigenvectors with eigenvalues at least . The Hermite derivative identity and trace estimate in Diakonikolas et al. (2021a, Fact 19 and the proof of Lemma 6) give . It follows that
Fix a halfspace and write for its orthogonal decomposition with respect to . If , then already has its normal in . Otherwise, set , and define
Under , this is conditional expectation given the projection onto . Thus, is an orthogonal projection in , a contraction in , and preserves . Applying Diakonikolas et al. (2021a, Claim 10) directly gives
By Lemma B.10, taking sufficiently large gives with and . Set . Then , , and
Since and , we obtain
where the last inequality uses Equations (29) and (30). Now,
This is a mixture of halfspaces with unit normals in , or constant classifiers if . Hence one such classifier satisfies . When , take .
For the finite class, use the covering and discretization bounds of Diakonikolas et al. (2021a, Fact 21 and Fact 22 with its proof), restated in Facts B.11 and B.12. Normalize the nonzero centers of an -net of the unit ball of V to obtain an -net V of its unit sphere. Set
for a sufficiently large universal constant . Define
When , omit the first set. The two additional halfspaces approximate the constant classifiers. The discretization bound gives an satisfying , including when is constant or has threshold outside . Thus,
Finally, the covering bound gives
The construction uses only q and .
Proof of Lemma 3.4. Let
Each summand has norm at most , so has replacement sensitivity . The noise scale in Algorithm 2 therefore makes ()-DP by standard Gaussian mechanism (Dwork and Roth, 2014). Projection and construction of are post-processing and preserve privacy.
Write and . The centered summands have norm at most and second moment at most . By Lemma B.1, with probability at least ,
Gaussian concentration gives, with probability at least , . Orthonormality and imply . Projection onto the unit ball therefore cannot increase distance to . Using , with probability at least we obtain
For a sufficiently large universal constant , the condition
makes this at most . By Equation (9),
Finally, projection and orthonormality give on every run.
Proof of Theorem 3.1. Round up to an even integer. If one observation in changes, the private polynomial release is followed only by post-processing with fixed. If one observation in changes, the distribution of is unchanged, and conditional on , selection is -DP. Thus, the complete algorithm is -DP.
Since , choosing ensures . Thus, the dimension condition needed in Lemma 3.5 follows from the theorem's assumption. The first two terms in the sample bound imply Equation (31) and hence the event in Lemma 3.4 with probability at least . On this event, Lemma 3.5 gives
Condition on any such released polynomial and write . Applying Lemma B.5 to the observations in gives, with probability at least ,
Since , the last two terms in the theorem's sample bound control the dependence on . The first two terms also control the remaining confidence terms, since . With sufficiently large constants in the sample bound, the selection error is at most .
A union bound therefore gives, with probability at least ,
where the last inequality follows by taking sufficiently small. Every member of is a halfspace, so the learner is proper.
Finally, we analyse the running time. Computing the clipped Hermite features of the samples in takes time, and the noisy average and its projection take more. Since , the matrix can be computed exactly from the coefficients of in time, and its eigendecomposition takes time. By Lemma 3.2, ; each member can be listed in poly time and evaluated on in time. Thus, the exponential mechanism takes time overall. Since and , the total running time is poly.
F Missing Details for Semi-Agnostic Learning
Algorithm 4 DP Semi-Agnostic Halfspace Learner
Require: Dataset , privacy parameters , accuracy parameter , error probability .
Partition dataset for multiple runs and set parameters.
1: Set for universal constant .
2: Let , such that . Set .
3: Partition into equal parts .
4: Set , and for and universal constant .
Run Algorithm 3 on each partition with appropriate parameters.
5: for to do
6: Set .
7: end for
Run all 's on and pick the best one using exponential mechanism.
8: Let
9: Define the score function .
10: Set .
11: Set .
12: Return .
F.1 Privacy
We first prove the privacy guarantees of Algorithm 4.
Proposition F.1. Algorithm 4 satisfies -DP.
Proof. We show that all different steps of Algorithm 4 that involve referencing the data using Algorithm 3 and the exponential mechanism satisfy DP, and then we apply parallel composition. However, for that, we first need to prove the privacy guarantees of Algorithm 3 by combination of using privacy guarantees of the standard DP mechanisms and parallel composition.
In Algorithm 3, when computing the threshold , the sensitivity of (the average of all the labels) has sensitivity because the labels can be either -1 or 1. Therefore, adding Laplace noise scaled to satisfies -DP.
For computing the initial weight vector , we compute the noisy average of over the entire dataset . Since we clip all the data points to within in norm, and is either -1 or 1, the sensitivity of this average is . Thus, adding Gaussian noise to this average scaled to satisfies -DP.
Next, in each iteration of the gradient descent procedure, we add Gaussian noise to the average gradient vector. From Claim 4.3, we see that the average gradient is of the form
Therefore, the sensitivity of this average gradient is at most
This implies that adding Gaussian noise to the average scaled to satisfies -DP in each iteration. However, in each iteration, a disjoint dataset gets used, so no data point gets used twice for any DP operation. Hence, by parallel composition, we get -DP for this part, as well.
Finally, applying parallel composition over the three steps again, we obtain -DP for Algorithm 3.
The guarantees of the exponential mechanism in Algorithm 4 imply -DP because the sensitivity of the mean of 0-1 random variables is . Since all the DP steps in Algorithm 4 are taken on disjoint and separate datasets, we obtain the required DP guarantee using parallel composition.
F.2 Relevant Assumptions and Regularity Conditions
For simplicity, we assume that the ambient dimension d is large enough. This assumption can be removed by using the exact expressions for concentration inequalities for high-dimensional Gaussians.
Assumption F.2 (Assumption on ambient dimension). We assume the following bound on the ambient dimension in terms of the error probability and number of samples : .
We do this for ease of notation, but we can make our calculations exact with a few extra lower order terms by not making this assumption.
Next, we state the Laurent-Massart inequality for concentration of high-dimensional Gaussians.
Lemma F.3 (Laurent-Massart inequality). Let be -dimensional, and for . Then the following holds for all .
Using the above, we have the following deterministic regularity condition that we would assume throughout the proof.
Lemma F.4 (Concentration of high-dimensional Gaussians). Let be i.i.d. samples from a -dimensional Gaussian . Then for , the following holds with probability at least .
Proof. The proof follows by simply applying Assumption F.2, Lemma F.3, and the union bound over all samples.
In Algorithm 3, we set the clipping parameter to ensure that all data points lie completely within the ball of radius around the origin, and no point gets actually clipped with high probability.
F.3 Missing Proofs from Section 4
Proof of Claim 4.3. The proof of this claim is the same as that of Claim C.2 from (Diakonikolas et al., 2022), except that the noisy gradient term has Gaussian noise added in the subspace orthogonal to (which is a known DP quantity) because the weight vectors get ultimately projected onto the unit ball and the GD algorithm will not move in the direction of . Therefore, by Pythagoras' theorem, term will still have norm at least 1 as the gradient and the noise belong to the same subspace that is orthogonal to .
Proof of Claim 4.5. In our algorithm , where , , and is as defined by Diakonikolas et al. (2022) in Algorithm 2. We know from the proof of Theorem 1.2 in (Diakonikolas et al., 2022) that . Therefore, it is sufficient to bound because . Note that for any fixed unit vector , . Applying concentration inequality for 1-D Gaussians, we get that with probability at least , by plugging in our bound on the sample complexity.