The Hessian Screening Rule
Abstract
Predictor screening rules, which discard predictors before ﬁtting a model, have had considerable impact on the speed with which sparse regression problems, such as the lasso, can be solved.
In this paper we present a new screening rule for solving the lasso path: the Hessian Screening Rule.
The rule uses second-order information from the model to provide both effective screening, particularly in the case of high correlation, as well as accurate warm starts.
The proposed rule outperforms all alternatives we study on simulated data sets with both low and high correlation for (cid:96) 1 -regularized least-squares (the lasso) and logistic regression.
It also performs best in general on the real data sets that we examine
Introduction
High-dimensional data, where the number of features ( p ) exceeds the number of observations ( n ), poses a challenge for many classical statistical models.
A common remedy for this issue is to regularize the model by penalizing the regression coefﬁcients such that the solution becomes sparse.
A popular choice of such a penalization is the (cid:96) 1 -norm, which, when the objective is least-squares, leads to the well-known lasso [1].
More speciﬁcally, we will focus on the following convex optimization problem:
[Equation]
(1) where f ( β ; X ) is smooth and convex.
We let ˆ β be the solution vector for this problem and, abusing notation, equivalently let ˆ β : R (cid:55)→ R p be a function that returns this vector for a given λ .
Our focus lies in solving (1) along a regularization path λ 1 , λ 2 . . .
, λ m with λ 1 ≥ λ 2 ≥ · · · ≥ λ m .
We start the path at λ max , which corresponds to the null (all-sparse) model 1 , and ﬁnish at some fraction of λ max for which the model is either almost saturated (in the p ≥ n setting), or for which the solution approaches the ordinary least-squares estimate.
The motivation for this focus is that the optimal λ is typically unknown and must be estimated through model tuning, such as cross-validation.
This involves repeated reﬁtting of the model to new batches of data, which is computationally demanding.
Fortunately, the introduction of so-called screening rules has improved this situation remarkably.
Screening rules use tests that screen and possibly discard predictors from the model before it is ﬁt, which effectively reduces the dimensions of the problem and leads to improvements in performance and memory usage.
There are, generally speaking, two types of screening rules: safe and heuristic rules.
Safe rules guarantee that discarded predictors are inactive at the optimum—heuristic rules do not and may therefore cause violations: discarding active predictors.
The possibility of violations mean that heuristic methods need to validate the solution through checks of the Karush–Kuhn–Tucker (KKT) optimality conditions after optimization has concluded and, whenever there are violations, rerun optimization, which can be costly particularly because the KKT checks themselves are expensive.
This means that the distinction between safe and heuristic rules only matters in regards to algorithmic details—all heuristic methods that we study here use KKT checks to catch these violations, which means that these methods are in fact also safe.
Screening rules can moreover also be classiﬁed as basic , sequential , or dynamic .
Basic rules screen predictors based only on information available from the null model.
Sequential rules use information from the previous step(s) on the regularization path to screen predictors for the next step.
Finally, dynamic rules screen predictors during optimization, reducing the set of screened predictors repeatedly throughout optimization.
Notable examples of safe rules include the basic SAFE rule [2], the sphere tests [3], the R-region test [4], Slores [5], Gap Safe [6, 7], and Dynamic Sasvi [8].
There is also a group of dual polytope projection rules, most prominently Enhanced Dual Polytope Projection (EDPP) [9].
As noted by Fercoq, Gramfort, and Salmon [6], however, the sequential version of EDPP relies on exact knowledge of the optimal solution at the previous step along the path to be safe in practice, which is only available for λ max .
Among the heuristic rules, we have the Strong Rule [10], SIS [11], and
ExSIS [12].
But the latter two of these are not sequential rules and solve a potentially reduced form of the problem in (1)—we will not discuss them further here.
In addition to these two types of rules, there has also recently been attempts to combine safe and heuristic rules into so-called hybrid rules [13].
There are various methods for employing these rules in practice.
Of particular interest are so-called working set strategies, which use a subset of the screened set during optimization, iteratively updating the set based on some criterion.
Tibshirani et al.
[10] introduced the ﬁrst working set strategy, which we in this paper will refer to simply as the working set strategy .
It uses the set of predictors that have ever been active as an initial working set.
After convergence on this set, it checks the KKT optimality conditions on the set of predictors selected by the strong rule, and then adds predictors that violate the conditions to the working set.
This procedure is then repeated until there are no violations, at which point the optimality conditions are checked for the entire set, possibly triggering additional iterations of the procedure.
Blitz [14] and Celer [15] are two other methods that use both Gap Safe screening and working sets.
Instead of choosing previously active predictors as a working set, however, both
Blitz and Celer assign priorities to each feature based on how close each feature is of violating the
Gap Safe check and construct the working set based on this prioritization.
In addition to this, Celer uses dual point acceleration to improve Gap Safe screening and speed up convergence.
Both Blitz and Celer are heuristic methods.
One problem with current screening rules is that they often become conservative—including large numbers of predictors into the screened set—when dealing with predictors that are strongly correlated.
Tibshirani et al.
[10], for instance, demonstrated this to be the case with the strong rule, which was the motivation behind the working set strategy.
(See Appendix F.4 for additional experiments verifying this).
Yet because the computational complexity of the KKT checks in the working set strategy still depends on the strong rule, the effectiveness of the rule may nevertheless be hampered in this situation.
A possible and—as we will soon show—powerful solution to this problem is to make use of the second-order information available from (1), and in this paper we present a novel screening rule based on this idea.
Methods using second-order information (the Hessian) are often computationally infeasible for high-dimensional problems.
We utilize two properties of the problem to remedy this issue: ﬁrst, we need only to compute the Hessian for the active set, which is often much smaller than the full set of predictors.
Second, we avoid constructing the Hessian (and it’s inverse) from scratch for each λ along the path, instead updating it sequentially by means of the Schur complement.
The availability of the Hessian also enables us to improve the warm starts (the initial coefﬁcient estimate at the start of each optimization run) used when ﬁtting the regularization path, which plays a key role in our method.
We present our main results in Section 3, beginning with a reformulation of the strong rule and working set strategy before we arrive at the screening rule that represents the main result of this paper.
In Section 4, we present numerical experiments on simulated and real data to showcase the effectiveness of the screening rule, demonstrating that the rule is effective both when p (cid:29) n and n (cid:29) p , out-performing the other alternatives that we study.
Finally, in Section 5 we wrap up with a discussion on these results, indicating possible ways in which they may be extended.
Preliminaries
We use lower-case letters to denote scalars and vectors and upper-case letters for matrices.
We useand 1 to denote vectors with elements all equal to 0 or 1 respectively, with dimensions inferred from context.
Furthermore, we let sign be the standard signum function with domain {− 1 , 0 , 1 } , allowing it to be overloaded for vectors.
Let c ( λ ) :
=
−∇ β f (cid:0) ˆ β ( λ ); X (cid:1) be the negative gradient, or so-called correlation , and denote A
λ
= { i : | c ( λ ) i | > λ } as the active set at λ : the support set of the non-zero regression coefﬁcients corresponding to ˆ β
λ ) .
In the interest of brevity, we will let A :
= A λ .
We will consider β a solution to (1) if it satisﬁes the stationary criterion
[Equation]
Here ∂ is the subdifferential of (cid:107) β (cid:107) 1 , deﬁned as
[Equation]
{ sign
[Equation]
ˆ
[Equation]
) } if ˆ
[Equation]
[ − 1 , 1] otherwise.
This means that there must be a ˜ ∂ ∈ ∂ for a given λ such that
[Equation]
Main Results
In this section we derive the main result of this paper: the Hessian screening rule.
First, however, we now introduce a non-standard perspective on screening rules.
In this approach, we note that (2) suggests a simple and general formulation for a screening rule, namely: we substitute the gradient vector in the optimality condition of a (cid:96) 1 -regularized problem with an estimate.
More precisely, we discard the j th predictor for the problem at a given λ if the magnitude of the j th component of the gradient vector estimate is smaller than this λ , that is
[Equation]
In the following sections, we review the strong rule and working set method for this problem from this perspective, that is, by viewing both methods as gradient approximations.
We start with the case of the standard lasso ( (cid:96) 1 -regularized least-squares), where we have f ( β ; X ) =
12 (cid:107)
Xβ − y (cid:107) 22 .
3.1 The Strong Rule
The sequential strong rule for (cid:96) 1 -penalized least-squares regression [10] discards the j th predictor at λ =
λ k
+
if
[Equation]
This is equivalent to checking that
[Equation]
satisﬁes (4).
The strong rule gradient approximation (5) is also known as the unit bound , since it assumes the gradient of the correlation vector to be bounded by one.
3.2 The Working Set Method
A simple but remarkably effective alternative to direct use of the strong rule is the working set heuristic [10].
It begins by estimating β at the ( k + 1) th step using only the coefﬁcients that have been previously active at any point along the path, i.e. A 1: k
= ∪ k i =1 A i .
The working set method can be viewed as a gradient estimate in the sense that
[Equation]
where ˜ β ( λ, A )
=
arg min β
|| y −
X
A β
||
+ λ | β | .
3.3 The Hessian Screening Rule
We have shown that both the strong screening rule and the working set strategy can be expressed as estimates of the correlation (negative gradient) for the next step of the regularization path.
As we have discussed previously, however, basing this estimate on the strong rule can lead to conservative approximations.
Fortunately, it turns out that we can produce a better estimate by utilizing secondorder information.
We start by noting that (3), in the case of the standard lasso, can be formulated as
[Equation]
and consequently that
[Equation]
Note that, for an interval [ λ l , λ u ] in which the active set is unchanged, that is, A λ
= A for all λ ∈ [ λ u , λ k ] , then ˆ β ( λ ) is a continuous linear function in λ (Theorem 3.1) 2 .
Theorem 3.1.
Let ˆ β ( λ ) be the solution of (1) where f ( β ; X )
= 12 (cid:107)
Xβ − y (cid:107) 22 .
Deﬁne
[Equation]
and ˆ β λ ∗ ( λ ) A cλ ∗ = 0 .
If it for λ ∈ [ λ 0 , λ ∗ ] holds that (i) sign (cid:0) ˆ β
[Equation]
λ
[Equation]
= sign
[Equation]
(cid:1) and (ii) max |∇ f (ˆ β λ ∗ ( λ ))
A λ ∗ | < λ, then ˆ β ( λ ) =
ˆ β λ ∗ ( λ ) for λ ∈ [ λ 0 , λ ∗ ] .
See Appendix A for a full proof.
Using Theorem 3.1, we have the following second-order approximation of c ( λ k +1 ) :
[Equation]
Remark 3.2 .
If no changes in the active set occur in [ λ k +1 , λ k ] , (6) is in fact an exact expression for the correlation at the next step, that is, ˆ c H ( λ k +1 )
=
c ( λ k +1 ) .
One problem with using the gradient estimate in (6) is that it is expensive to compute due to the inner products involving the full design matrix.
To deal with this, we use the following modiﬁcation, in which we restrict the computation of these inner products to the set indexed by the strong rule, assuming that predictors outside this set remain inactive:
[Equation]
if
[Equation]
˜
[Equation]
and j
[Equation]
∈
A λ k
[Equation]
else .
For high-dimensional problems, this modiﬁcation leads to large computational gains and seldom proves inaccurate, given that the strong rule only rarely causes violations [10].
Lastly, we make one more adjustment to the rule, which is to add a proportion of the unit bound (used in the strong rule) to the gradient estimate:
[Equation]
) sign( c ( λ k ) j ) , where γ ∈ R + .
Without this adjustment there would be no upwards bias on the estimate, which would cause more violations than would be desirable.
In our experiments, we have used γ = 0 .
01 , which has worked well for most problems we have encountered.
This ﬁnally leads us to the Hessian screening rule : discard the j th predictor at λ k +1 if | ˇ c H ( λ k +1 )
j | <
λ
k
+1 .
We make one more modiﬁcation in our implementation of the Hessian Screening Rule, which is to use the union of the ever-active predictors and those screened by the screening rule as our ﬁnal set of screened predictors.
We note that this is a marginal improvement to the rule, since violations of the rule are already quite infrequent.
But it is included nonetheless, given that it comes at no cost and occasionally prevents violations.
As an example of how the Hessian Screening Rule performs, we examine the screening performance of several different strategies.
We ﬁt a full regularization path to a design with n = 200 , p = 20 000 , and pairwise correlation between predictors of ρ .
(See Section 4 and Appendix F.4 for more information on the setup.)
We compute the average number of screened predictors across iterations of the coordinate descent solver.
The results are displayed in Figure 1 and demonstrate that our method gracefully handles high correlation among predictors, offering a screened set that is many times smaller than those produced by the other screening strategies.
In Appendix F.4 we extend these results to (cid:96) 1 -regularized logistic regression as well and report the frequency of violations.
[Figure]
Recall that the Strong rule bounds its gradient of the correlation vector estimate at one.
For the
Hessian rule, there is no such bound.
This means that it is theoretically possible for the Hessian rule to include more predictors than the Strong rule 3 .
In fact, it is even possible to design special cases where the Hessian rule could be more conservative than the Strong rule.
In practice, however, we have not encountered any situation in which this is the case.
3.3.1 Updating the Hessian
A potential drawback to using the Hessian screening rule is the computational costs of computing the
Hessian and its inverse.
Let A k be the active set at step k on the lasso path.
In order to use the Hessian screening rule we need H − 1 k
=
( X T A k X
A k ) − 1 .
Computing ( X T
A k X A k ) − 1 directly, however, has numerical complexity O (
|A k | 3 + |A k | 2 n ) .
But if we have stored ( H − 1 k − 1 , H k − 1 ) previously, we can utilize it to compute ( H − 1 k , H k ) more efﬁciently via the so-called sweep operator [17].
We outline this technique in Algorithm 1 (Appendix B).
The algorithm has a reduction step and an augmentation step; in the reduction step, we reduce the Hessian and its inverse to remove the presence of any predictors that are no longer active.
In the augmentation step, we update the Hessian and its inverse to account for predictors that have just become active.
The complexity of the steps depends on the size of the sets C =
A k − 1 \
A k , D =
A k \
A k − 1 , and E =
A k ∩ A k −
The complexity of the reduction step is O ( |C| 3 + |C| 2 |E| + |C||E| 2 ) and the complexity of the augmentation step is O ( |D| 2 n + n |D||E| + |D| 2 |E| + |D| 3 ) since n ≥ max( |E| , |D| ) .
An iteration of Algorithm 1 therefore has complexity O ( |D| 2 n + n |D||E| + |C| 3 + |C||E| 2 ) .
In most applications, the computationally dominant term will be n |D||E| (since, typically, n > |E| >
D > C ) which could be compared to evaluating the gradient for β A k , which is n ( |D| + |E| )
when β
A ck = 0 .
Note that we have so far assumed that the inverse of the Hessian exists, but this need not be the case.
To deal with this issue we precondition the Hessian.
See Appendix C for details.
3.3.2 Warm Starts
The availability of the Hessian and its inverse offers a coefﬁcient warm start that is more accurate than the standard, naive, approach of using the estimate from the previous step.
With the Hessian screening rule, we use the following warm start.
[Equation]
where H − 1 A k is the Hessian matrix for the differentiable part of the objective.
Our warm start is equivalent to the one used in Park and Hastie [18], but is here made much more efﬁcient due due to the efﬁcient updates of the Hessian and its inverse that we use.
Remark 3.3 .
The warm start given by (7) is the exact solution at λ k if the active set remains constant in [ λ k +1 , λ k ] .
As a ﬁrst demonstration of the value of this warm start, we look at two data sets: YearPredicitionMSD and colon-cancer .
We ﬁt a full regularization path using the setup as outlined in Section 4, with or without Hessian warm starts.
For YearPredictionMSD we use the standard lasso, and for colon-cancer (cid:96) 1 -regularized logistic regression.
The Hessian warm starts offer sizable reductions in the number of passes of the solver (Figure 2), for many steps requiring only a single pass to reach convergence.
On inspection, this is not a surprising ﬁnd.
There are no changes in the active set for many of these steps, which means that the warm start is almost exact—“almost” due to the use of a preconditioner for the Hessian (see Appendix C).
[Figure]
3.3.3 General Loss Functions
We now venture beyond the standard lasso and consider loss functions of the form
[Equation] [Equation]
where f i is convex and twice differentiable.
This, for instance, includes logistic, multinomial, and
Poisson loss functions.
For the strong rule and working set strategy, this extension does not make much of a difference.
With the Hessian screening rule, however, the situation is different.
To see this, we start by noting that our method involving the Hessian is really a quadratic Taylor approximation of (1) around a speciﬁc point β 0 .
For loss functions of the type (8), this approximation is equal to
[Equation]
where D ( w ( β 0 )) is a diagonal matrix with diagonal entries w ( β 0 )
where w ( β 0 ) i =
f (cid:48)(cid:48)
( x Ti β 0 ) and ˜ y
( z ) i =
f (cid:48)
i ( z ) (cid:14) f
(cid:48)(cid:48)
i ( z ) − x Ti β 0 , whilst C ( β 0 ) is a constant with respect to β .
Suppose that we are on the lasso path at λ k and want to approximate c ( λ k +1 ) .
In this case, we simply replace f ( β ; X ) in (1) with Q ( β, ˆ β ( λ k )) , which leads to the following gradient approximation:
[Equation]
where w = w (cid:0) ˆ β ( λ k ) (cid:1) .
Unfortunately, we cannot use Algorithm 1 to update X T A k D ( w ) X
A k .
This means that we are forced to either update the Hessian directly at each step, which can be computationally demanding when |A k | is large and inefﬁcient when X is very sparse, or to approximate
D ( w ) with an upper bound.
In logistic regression, for instance, we can use 1 / 4 as such a bound, which also means that we once again can use Algorithm 1.
In our experiments, we have employed the following heuristic to decide whether to use an upper bound or compute the full Hessian in these cases: we use full updates at each step if sparsity( X ) n/ max { n, p } <
10 − 3 and the upper bound otherwise.
3.3.4 Reducing the Impact of KKT Checks
The Hessian Screening Rule is heuristic, which means there may be violations.
This necessitates that we verify the KKT conditions after having reached convergence for the screened set of predictors, and add predictors back into the working set for which these checks fail.
When the screened set is small relative to p , the cost of optimization is often in large part consumed by these checks.
Running these checks for the full set of predictors always needs to be done once, but if there are violations during this step, then we need repeat this check, which is best avoided.
Here we describe two methods to tackle this issue.
We employ a procedure equivalent to the one used in Tibshirani et al.
[10] for the working set strategy: we ﬁrst check the KKT conditions for the set of predictors singled out by the strong rule and then, if there are no violations in that set, check the full set of predictors for violations.
This works well because the strong rule is conservative—violations are rare—which means that we seldom need to run the KKT checks for the entire set more than once.
If we, in spite of the augmentation of the rule, run into violations when checking the full set of predictors, that is, when the strong rule fails to capture the active set, then we can still avoid repeating the full KKT check by relying on Gap Safe screening: after having run the KKT checks and have failed to converge, we screen the set of predictors using the Gap Safe rule.
Because this is a safe rule, we can be sure that the predictors we discard will be inactive, which means that we will not need to include them in our upcoming KKT checks.
Because Gap Safe screening and the KKT checks rely on exactly the same quantity—the correlation vector–we can do so at marginal extra cost.
To see how this works, we now brieﬂy introduce Gap Safe screening.
For details, please see Fercoq, Gramfort, and Salmon [6].
For the ordinary lasso ( (cid:96) 1 -regularized least squares), the primal (1) is P ( β ) =
12 (cid:107) y − Xβ (cid:107) 22 + λ (cid:107) β (cid:107)and the corresponding dual is
[Equation]
subject to (cid:107) X T θ (cid:107) ∞ ≤ 1 .
The duality gap is then G ( β, θ ) =
P ( β ) − D ( θ ) and the relation between the primal and dual problems is given by y
= λ
ˆ θ + X ˆ β , where ˆ θ is the maximizer to the dual problem (9).
In order to use Gap Safe screening, we need a feasible dual point, which can be obtained via dual point scaling, taking θ =
( y − Xβ )
(cid:14) max (cid:0) λ, (cid:107) X T ( y − Xβ )
(cid:107) ∞ (cid:1) .
The Gap Safe screening rule then discards the j th feature if | x Tj θ | < 1 − (cid:107) x j (cid:107) 2 (cid:112) 2 G ( β, θ ) /λ 2 .
Since we have computed X T ( y − Xβ ) as part of the KKT checks, we can perform Gap Safe screening at an additional (and marginal) cost amounting to O ( n ) + O ( p ) .
Since this augmentation beneﬁts the working set strategy too, we adopt it in our implementation of this method as well.
To avoid ambiguity, we call this version working+.
Note that this makes the working set strategy quite similar to Blitz.
In Appendix F.8 we show the beneﬁt of adding this type of screening.
3.3.5 Final Algorithm
The Hessian screening method is presented in full in Algorithm 2 (Appendix B).
Lemma 3.4.
Let β ∈ R p ×
m be the output of Algorithm 2 for a path of length m and convergence threshold ε > 0 .
For each step k along the path and corresponding solution β ( k ) ∈ R p , there is a dual-feasible point θ ( k ) such that G ( β ( k ) , θ ( k ) ) < ζε.
Proof.
First note that Gap safe screening [7, Theorem 6] ensures that G ⊇ A k .
Next, note that the algorithm guarantees that the working set, W , grows with each iteration until | x Tj r | < λ k for all j ∈ G \ W , at which point
[Equation]
At this iteration, convergence at line 2, for the subproblem ( X W , y ) , guarantees convergence for the full problem, ( X, y ) , since
[Equation]
is dual-feasible for the full problem.
3.3.6 Extensions
Approximate Homotopy
In addition to improved screening and warm starts, the Hessian also allows us to construct the regularization path adaptively via approximate homotopy [19].
In brief, the
Hessian screening rule allows us to choose the next λ along the path adaptively, in effect distributing the grid of λ s to better approach the exact (homotopy) solution for the lasso, avoiding the otherwise heuristic choice, which can be inappropriate for some data sets.
Elastic Net Our method can be extended to the elastic net [20], which corresponds to adding a quadratic penalty φ (cid:107) β (cid:107) 22 / 2 to (1).
The Hessian now takes the form X T A X A
+ φI .
Loosely speaking, the addition of this term makes the problem “more“ quadratic, which in turn improves both the accuracy and stability of the screening and warm starts we use in our method.
As far as we know, however, there is unfortunately no way to update the inverse of the Hessian efﬁciently in the case of the elastic net.
More research in this area would be welcome.
Experiments
Throughout the following experiments, we scale and center predictors with the mean and uncorrected sample standard deviation respectively.
For the lasso, we also center the response vector, y , with the mean.
To construct the regularization path, we adopt the default settings from glmnet : we use a log-spaced path of 100 λ values from λ max to ξλ max , where ξ = 10 − 2 if p > n and 10 − 4 otherwise.
We stop the path whenever the deviance ratio, 1 − dev / dev null , reaches 0.999 or the fractional decrease in deviance is less than 10 − 5 .
Finally, we also stop the path whenever the number of coefﬁcients ever to be active predictors exceeds p .
We compare our method against working+ (the modiﬁed version of the working set strategy from
Tibshirani et al.
[10]), Celer [15], and Blitz [14].
We initially also ran our comparisons against
EDPP [9], the Gap Safe rule [6], and Dynamic Sasvi [8] too, yet these methods performed so poorly that we omit the results in the main part of this work.
The interested reader may nevertheless consult
Appendix F.6 where results from simulated data has been included for these methods too.
We use cyclical coordinate descent with shufﬂing and consider the model to converge when the duality gap G ( β, θ ) ≤ εζ , where we take ζ to be (cid:107) y (cid:107) 22 when ﬁtting the ordinary lasso, and n logwhen ﬁtting (cid:96) 1 -regularized logistic regression.
Unless speciﬁed, we let ε = 10 − 4 .
These settings are standard settings and, for instance, resemble the defaults used in Celer.
For all of the experiments, we employ the line search algorithm used in Blitz 4 .
The code used in these experiments was, for every method, programmed in C++ using the Armadillo library [21, 22] and organized as an R package via Rcpp [23].
We used the renv package [24] to maintain dependencies.
The source code, including a Singularity [25] container and its recipe for reproducing the results, are available at https://github.com/jolars/HessianScreening .
Additional details of the computational setup are provided in Appendix D.
4.1 Simulated Data
Let X ∈ R n × p , β ∈ R p , and y ∈ R n be the predictor matrix, coefﬁcient vector, and response vector respectively.
We draw the rows of the predictor matrix independently and identically distributed from
N (0 , Σ) and generate the response from N ( Xβ, σ 2 I ) with σ 2 = β T Σ β/ SNR, where SNR is the signal-to-noise ratio.
We set s coefﬁcients, equally spaced throughout the coefﬁcient vector, to 1 and the rest to zero.
In our simulations, we consider two scenarios: a low-dimensional scenario and a high-dimensional scenario.
In the former, we set n = 10 000 , p = 100 , s = 5 , and the SNR to 1.
In the highdimensional scenario, we take n = 400 , p = 40 000 , s = 20 , and set the SNR to 2.
These SNR values are inspired by the discussion in Hastie, Tibshirani, and Tibshirani [26] and intend to cover the middle-ground in terms of signal strength.
We run our simulations for 20 iterations.
From Figure 3, it is clear that the Hessian screening rule performs best, taking the least time in every setting examined.
The difference is largest for the high-correlation context in the low-dimensional setting and otherwise roughly the same across levels of correlation.
The differences between the other methods are on average small, with the working+ strategy performing slightly better in the p > n scenario.
Celer and Blitz perform largely on par with one another, although Celer sees an improvement in a few of the experiments, for instance in logistic regression when p > n .
[Figure]
[Table] [Table]
=
[Table]
[Table] [Table]
( 𝜌 )
T i m e (r e l a ti v e )
[Figure]
4.2 Real Data
In this section, we conduct experiments on real data sets.
We run 20 iterations for the smaller data sets studied and three for the larger ones.
For information on the sources of these data sets, please see
Appendix E.
For more detailed results of these experiments, please see Appendix F.5.
Starting with the case of (cid:96) 1 -regularized least-squares regression, we observe that the Hessian screening rule performs best for all ﬁve data sets tested here (Table 1), in all but one instance taking less than half the time compared to the runner-up, which in each case is the working+ strategy.
The difference is particularly large for the YearPredictionMSD and e2006-tﬁdf data sets.
In the case of (cid:96) 1 -regularized logistic regression, the Hessian method again performs best for most of the examined data sets, for instance completing the regularization path for the madelon data set around ﬁve times faster than the working+ strategy.
The exception is the arcene data set, for which the working+ strategy performs best out of the four methods.
We have provided additional results related to the effectiveness of our method in Appendix F.
[Table]
Discussion
We have presented the Hessian Screening Rule: a new heuristic predictor screening rule for (cid:96) 1regularized generalized linear models.
We have shown that our screening rule offers large performance improvements over competing methods, both in simulated experiments but also in the majority of the real data sets that we study here.
The improved performance of the rule appears to come not only from improved effectiveness in screening, particularly in the high-correlation setting, but also from the much-improved warm starts, which enables our method to dominate in the n (cid:29) p setting.
Note that although we have focused on (cid:96) 1 -regularized least-squares and logistic regression here, our rule is applicable to any composite objective for which the differentiable part is twice-differentiable.
One limitation of our method is that it consumes more memory than its competitors owing to the storage of the Hessian and its inverse.
This cost may become prohibitive for cases when min { n, p } is large.
In these situations the next-best choice may instead be the working set strategy.
Note also that we, in this paper, focus entirely on the lasso path .
The Hessian Screening Rule is a sequential rule and may therefore not prove optimal when solving for a single λ , in which case a dynamic strategy such as Celer and Blitz likely performs better.
With respect to the relative performance of the working set strategy, Celer, and Blitz, we note that our results deviate somewhat from previous comparisons [15, 14].
We speculate that these differences might arise from the fact that we have used equivalent implementations for all of the methods and from the modiﬁcation that we have used for the working set strategy.
Many avenues remain to be explored in the context of Hessian-based screening rules and algorithms, such as developing more efﬁcient methods for updating of the Hessian matrix for non-least-squares objectives, such as logistic regression and using second-order information to further improve the optimization method used.
Other interesting directions also include adapting the rules to more complicated regularization problems, such as the fused lasso [27], SLOPE [28], SCAD [29], and
MCP [30].
Although the latter two of these are non-convex problems, they are locally convex for intervals of the regularization path [31], which enables the use of our method.
Adapting the method for use in batch stochastic gradient descent would also be an interesting topic for further study, for instance by using methods such as the ones outlined in Asar et al.
[32] to ensure that the Hessian remains positive deﬁnite.
Finally, we do not expect there to be any negative societal consequences of our work given that it is aimed solely at improving the performance of an optimization method.
Acknowledgments and Disclosure of Funding
We would like to thank Małgorzata Bogdan for valuable comments.
This work was funded by the Swedish Research Council through grant agreement no. 2020-05081 and no. 2018-01726.
The computations were enabled by resources provided by LUNARC.
The results shown here are in part based upon data generated by the TCGA Research Network: https://www.cancer.gov/tcga . Checklist
For all authors... (a) Do the main claims made in the abstract and introduction accurately reﬂect the paper’s contributions and scope?
[Yes] (b) Did you describe the limitations of your work?
[Yes] See Section(c)
Did you discuss any potential negative societal impacts of your work?
[Yes] See Section 5. (d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes] 2. If you are including theoretical results... (a) Did you state the full set of assumptions of all theoretical results?
[Yes] (b) Did you include complete proofs of all theoretical results?
[Yes] See the supplementary material.
If you ran experiments... (a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)?
[Yes] See Section 4.
(b) Did you specify all the training details (e
g., data splits, hyperparameters, how they were chosen)?
[Yes] See Section 4 as well as the supplementary details and the references to existing data sets for discussions on test and training splits.
(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)?
[Yes]
(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)?
[Yes] 4.
If you are using existing assets (e.g., code, data, models) or curating/releasing new assets... (a) If your work uses existing assets, did you cite the creators?
[Yes] See the supplement and Section 4.
(b) Did you mention the license of the assets?
[Yes] A LICENSE.md ﬁle has been included along with the code.
(c) Did you include any new assets either in the supplemental material or as a URL?
[Yes] See Section 4.
(d) Did you discuss whether and how consent was obtained from people whose data you’re using/curating?
[N/A] All data we used has been made available in the public domain.
(e) Did you discuss whether the data you are using/curating contains personally identiﬁable information or offensive content?
[Yes] To the best of our knowledge, it does not.
If you used crowdsourcing or conducted research with human subjects... (a) Did you include the full text of instructions given to participants and screenshots, if applicable?
[N/A] Not applicable to our work.
(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable?
[N/A] Not applicable to our work.
(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation?
[N/A] Not applicable to our work.
A Proofs A.1 Proof of Theorem
It sufﬁces to verify that the KKT conditions hold for ˆ β λ ∗ ( λ ) , i.e. that 0 is in the subdifferential.
By (ii) it follows that the indices A cλ ∗ in the subdifferential contain zero.
That leaves us only to show that ∇ f (cid:0) [Equation] ∇ f (cid:0)
[Equation]
which by (i) equals λ sign(ˆ β λ ∗ [Equation] λ [Equation]
[Equation]
B Algorithms C Singular or Ill-Conditioned Hessians
In this section, we discuss situations in which the Hessian is singular or ill-conditioned and propose remedies for these situations.
Inversion of the Hessian demands that the null space corresponding to the active predictors A λ contains only the zero vector, which typically holds when the columns of X are in general position, such as in the case of data simulated from continuous distributions.
It is not, however, generally the case with discrete-valued data, particularly not in when p (cid:29) n .
In Lemma C.1, we formalize this point.
Algorithm
This algorithm provides computationally efﬁcient updates for the inverse of
Note the slight abuse of notation here in that E is used both for X and Q .
It is implicitly understood that Q EE is the sub-matrix of Q that corresponds to the columns E of X .
[Equation]
C
[Equation]
= ∅ then
[Equation]
= E end if if D (cid:54) = ∅ then
[Equation]
end if
Return H ∗
Algorithm
Input: X ∈ R n × p , y ∈ R n , λ ∈
R m + : λ 1 = λ max , λ 1 > λ 2 > · · · > λ m } , ε >
Initalize: k ← 1 , β (0) ← 0 , ζ ← (cid:107) y (cid:107) 22 , W ← ∅ , A ← ∅ , S ← ∅ , G ← { 1 , 2 , . . .
, p } 1: while k ≤ m do 2: β ( k ) W ← (cid:8) β ∈ R |W| : G (cid:0) β, ( y − X W β ) / max( λ k , (cid:107) X T W ( y − X W β ) (cid:107) ∞ ) (cid:1) < ζε (cid:9) 3: β ( k ) W C ←4:
A ← { j : β j (cid:54) = 0 } 5: r ← y − X W β ( k ) W 6:
V ← { j ∈ S \ W : | x Tj r | ≥ λ k } (cid:46) Check for violations in Strong set 7: if V = ∅ then 8: θ ← r/ max (cid:0) λ k , (cid:107) X T G r (cid:107) ∞ (cid:1) (cid:46) Compute dual-feasible point 9: if G ( β ( k ) , θ ) <
εζ then 10:
Update H and H − 1 via Algorithm11:
W ← { j : | ˜ c
H ( λ k +1 )
| < λ k +1 } ∪ A (cid:46)
Hessian rule screening 12:
S ← { j : | ˜ c S ( λ k +1 ) | <
λ k +1 } (cid:46)
Strong rule screening 13:
Initialize β
( k +1)
A using (7) (cid:46) Hessian warm start 14:
G ← { 1 , 2 , . . . , p } (cid:46)
Reset Gap-Safe set 15: k ← k +(cid:46) Move to next step on path 16: else 17:
G ← (cid:110) j ∈ G : | x
Tj θ | ≥ 1 − (cid:107) x j (cid:107) 2 (cid:113) 2 G ( β ( k ) , θ ) /λ 2 k (cid:111)
(cid:46) Gap-Safe screening 18:
V ← { j ∈ G \ (cid:0) S ∪ W (cid:1) : | x Tj r | ≥ λ k } (cid:46) Check for violations in Gap-Safe set 19:
W ← W ∩ G 20:
S ← S ∩ G 21: end if 22: end if 23:
W ← W ∪ V (cid:46) Augment working set with violating predictors 24: end while 25: return β
Lemma C.1.
Suppose that we have e ∈ R p such that Xe = 0 .
Let ˆ β ( λ ) be the solution to the primal problem (1) and E
= { i : e i (cid:54) = 0 } ; then | ˆ β ( λ ) E | > 0 only if there exists a z ∈ R p where z E ∈ {− 1 , 1 } |E| such that z T e = 0 .
Proof.
(cid:80)
j ∈E x j e j = 0 by assumption.
Then, since ˆ β ( λ ) is the solution to the primal problem, it follows that x Tj ∇ f
( Xβ )
= sign( β j ) λ for all j ∈ E .
Hence (cid:88)
[Equation]
and z E C = 0 , z E = sign( β E ) .
In our opinion, the most salient feature of this result is that if all predictors in E except i are known to be active, then predictor i is active iff e i
=
(cid:80)
j
∈E\ i ±
e j .
If the columns of X are independent and normally distributed, this cannot occur and hence one will never see a null space in X A .
Yet if
X ij ∈ { 0 , 1 } , one should expect the null space to be non-empty frequently.
A simple instance of this occurs when the columns of X are duplicates, in which case | e | = 2 .
Duplicated predictors are fortunately easy to handle since they enter the model simultaneously.
And we have, in our program, implemented measures that deal efﬁciently with this issue by dropping them from the solution after ﬁtting and adjust ˆ β accordingly.
Dealing with the presence of rank-deﬁciencies due to the existence of linear combinations among the predictors is more challenging.
In the work for this paper, we developed a strategy to deal with this issue directly by identifying such linear combinations through spectral decompositions.
During our experiments, however, we discovered that this method often runs into numerical issues that require other modiﬁcations that invalidate its potential.
We have therefore opted for a different strategy.
To deal with singularities and ill-conditioned Hessian matrices, we instead use preconditioning.
At step k , we form the spectral decomposition
H A k = Q Λ Q T .
Then, if min i (cid:0) diag(Λ) (cid:1) <
α , we add a factor α to the diagonal of H A k .
Then we substitute ˆ H − 1 A k = Q T ( Iα + Λ) − 1 Q for the true Hessian inverse.
An analogous approach is taken when updating the Hessian incrementally as in Algorithm 1.
In our experiments, we have set α := n 10 − 4 .
D Computational Setup Details
The computer used to run had the following speciﬁcations:
CPU
Intel i7-10510U @ 1.80Ghz (4 cores) Memory 64 GB (3.2 GB/core)
OS Fedora
Compiler GNU GCC compiler v9.3.0, C++
BLAS/LAPACK OpenBLAS v0.3.
R version 4.1.
E Real Data Sets
All of the data sets except arcene , scheetz , and bc_tcga werew retrieved from https://www.csie.
ntu.edu.tw/~cjlin/libsvmtools/datasets/ [33, 34].
arcene was retrieved from https:// archive.ics.uci.edu/ml/datasets/Arcene [35, 36] and scheetz and bc_tcga from https: //myweb.uiowa.edu/pbreheny [37].
Their original sources have been listed in Table 2.
In each case where it is available we use the training partition of the data set and otherwise the full data set.
Dataset
[Table]
Guyon et al.
[35] and Dua and Graff [36]
[Table]
National Cancer Institute [38]
[Table]
Alon et al.
[Table]
West et al.
[Table]
Kogan et al.
[Table]
Kogan et al.
[Table]
Prokhorov [42]
[Table]
et al.
[Table]
Keerthi and DeCoste [43]
[Table]
Lewis et al.
[Table]
et al.
[Table]
Bertin-Mahieux et al.
[46] and Dua and Graff [36]
[Figure]
F Additional Results
In this section, we present additional results related to the performance of the Hessian Screening
Rule.
F.1 Path Length
Using the same setup as in Section 4 but with n = 200 , p = 20 000 for the high-dimensional setting, we again benchmark the time required to ﬁt a full regularization path using the different methods studied in this paper.
The results (Figure 4) show that the Hessian Screening Method out-performs the studied alternatives except for the low-dimensional situation and a path length of 10 λ s. The results demonstrate that our method pays a much smaller price for increased path resolution compared to the other methods but that the increased marginal costs of updating the Hessian may make the method less appealing in this case.
F.2 Convergence Tolerance
To better understand if and how the stopping threshold used in the solver affects the performance of the various methods we test, we conduct simulations where we vary the tolerance, keeping the remaining parameters constant.
We use the same situation as in the high-dimensional scenario (see
Section 4) but use n = 200 , p = 20 000 .
We run the experiment for tolerances 10 − 3 , 10 − 4 , 10 − 5 , and 10 − 6 .
The results (Figure 5) indicate that the choice of stopping threshold has some importance for convergence time but that the gap between our method and the alternatives tested never disappears.
[Figure]
F.3 The Beneﬁt of Augmenting Heuristic Methods with Gap Safe Screening
To study the effectiveness of augmenting the Hessian Screening and working methods with a gap-safe check, we conduct experiments using the high-dimensional setup in Section 4 but with n = 200 and p = 20 000 , either enabling this augmentation or disabling it.
We also vary the level of correlation, ρ .
Each combination is benchmarked across 20 iterations.
The results indicate that the addition of gap safe screening makes a deﬁnite, albeit modest, contribution to the performance of the methods, particularly in the case of the working strategy, which is to be expected given that the working strategy typically runs more KKT checks that the Hessian method does since it causes many more violations.
[Figure]
F.4 Effectiveness and Violations
To study the effectiveness of the screening rule, we conduct as experiment using the setup in
Section 4 (main paper) but with n = 200 and p = 20 000 .
We run 20 iterations and average the number of screened predictors as well as violations across the entire path.
Looking at the effectiveness of the screening rules, we see that the Hessian screening rule performs as desired for both (cid:96) 1 -regularized least-squares and logistic regression (Figure 7), leading to a screened set that lies very close to the true size.
In particular, the rule works much better than all alternatives in the case of high correlation, 𝜌 =𝜌 = 0 .𝜌
= 0 .
[Figure]
P r e d i c t
o r s
[Figure]
In Table 3, we show the average numbers of screened (included) predictors and violations for the heuristic screening rules across the path.
We note, ﬁrst, that EDPP never lead to any violations and that the Strong rule only did so once throughout the experiments.
The Hessian rule, on the other hand, leads to more violations, particularly when there is high correlation.
On the other hand, the Hessian screening rule successfully discards many more predictors than the other two rules do.
And because the Hessian method always checks for violations in the strong rule set ﬁrst, which is demonstrably conservative, these violations are of little importance in practice.
F.5 Detailed Results on Real Data
In Table 4 we show Table 1 with additional detail, including conﬁdence intervals and higher ﬁgure resolutions.
Please see Section 4 for commentary on these results, where they have been covered in full.
F.6 Additional Results on Simulated Data
In Figure 8, we show results for the ordinary least-squares lasso for the Sasvi, Gap Safe, and EDPP methods, which were not included in the main paper.
[Table]
[Figure]
F.7 Gamma
In this section we present the results of experiments targeting γ , the parameter for the Hessian rule that controls how much of the unit bound (used in the Strong Rule) that is included in the correlation vector estimate from the Hessian rule.
We run 50 iterations of the high-dimensional setup from Section 4 and measure the number of predictors screened (included) by the Hessian screening rule, the number of violations
[Table]
and the time taken to ﬁt the full path.
We vary γ from 0.001 to 0.3.
The results are presented in Figure 9.
From the ﬁgure it is clear that the number of violations in fact has a slightly negative impact on the speed at which the path is ﬁt.
We also see that the number of violations is small considering the dimension of the data set ( p = 40 000 ) and approach zero at γ values around 0.1 for the lowest level of correlation, but have yet to reach exactly zero at 0.3 for the highest level of correlation.
The size of the screened set increase only marginally as γ increases fro 0.001 to 0.01, but eventually increase rapidly at γ approaches 0.3.
Note, however, that the screened set is still very small relative to the full set of predictors.
[Table]
[Figure]
F.8 Ablation Analysis
In this section we report an experiment wherein we study the effects of the various features of the
Hessian screening method by incrementally adding them and timing the result.
We add features incrementally in the following order, such that each step includes all of the previous features.
Hessian screening 2.
Hessian warm starts 3.
Effective updates of the Hessian matrix and its inverse using the sweep operator 4.
Gap safe screening
We then run an experiment on a design with n = 200 and p = 20 000 and two levels of pairwise correlation between the predictors.
The results (Figure 10) show that both screening and warm starts make considerable contributions in this example.
Note that these results are conditional on the order with which they are added and also on the speciﬁc design.
The Hessian updates, for instance, make a larger contribution when min { n, p } is larger and n and p are more similar.
And when n (cid:29) p , the contribution of the warm starts dominate whereas screening no longer plays as much of a role.
F.9 (cid:96) 1 -Regularized Poisson Regression
In this experiment, we provide preliminary results for (cid:96) 1 -regularized Poisson regression.
The setup is the same as Section 4 except for the following remarks:
• The response, y , is randomly sampled such that y i ∼ Poisson (cid:0) exp( x Ti β ) (cid:1) .
• We set ζ in the convergence criterion to n + (cid:80) ni
=1 log( y i !) .
• We do not use the line search procedure from Blitz.
• Due to convergence issues for higher values of ρ , we use values 0 . 0 , 0 . 15 , and 0 .
3 here.
Tackling higher values of ρ would likely need considerable modiﬁcations to the coordinate descent solver we use.
• The gradient of the negative Poisson log-likelihood is not Lipschitz continuous, which means that Gap safe screening [7] no longer works.
As a result, we have excluded the Blitz and Celer algorithms, which rely on Gap safe screening, from these benchmarks, and deactivated the additional Gap safe screening from our algorithm.
[Figure]
The results from the comparison are shown in Figure
[Figure]
showing that our algorithm is noticeably faster than the working algorithm also in this case.
[Figure]
F.10 Runtime Breakdown Along Path
In this section we take a closer look at the running time of ﬁtting the full regularization path and study the impact the Hessian screening rule and its warm starts have on the time spent on optimization of the problem using coordinate descent (CD).
To illustrate these cases we take a look at three data sets here: e2006-tﬁdf , madelon
[Figure]
and rcv1 .
The ﬁrst of these, e2006-tﬁdf, is a sparse data set of dimensions 16
× 150 360 with a numeric response, to which we ﬁt the ordinary lasso.
The second two are both data sets with a binary response, for which we use (cid:96) 1 -regularized logistic regression.
The dimensions of madelon are 2000 × 500 and the dimensions of rcv1 are 20 242 × 47 236 .
We study the contribution to the total running time per step, comparing the Hessian screening rule with the working+ strategy.
For the working+ strategy, all time is spent inside the CD optimizer and in checks of the KKT conditions.
For the Hessian screening rule, time is also spent updating the
Hessian and computing the correlation estimate ˜ c H .
Beginning with Figure 12 we see that the Hessian strategy dominates the Working+ strategy, which spends most of its running time on coordinate descent iterations, which the Hessian strategy ensures are completed in much less time.
[Figure]
In Figure 13, we see an example of (cid:96) 1 -regularized logistic regression.
In this case updating the
Hessian exactly (and directly) dominates the other approaches.
The size of the problem makes the cost of updating the Hessian negligible and offers improved screening and warm starts, which in turn greatly reduces the time spent on coordinate descent iterations and consequently the full time spent ﬁtting the path.
Finally, in Figure 14 we consider the rcv1 data set.
In contrast to the case for madelon , the cost of directly forming the Hessian (and inverse) proves more time-consuming here (although the beneﬁts still show in the time spent on coordinate descent iterations).
As a ﬁnal remark, note that the pattern by which predictors enter the model (bottom panels) differ considerably between these three cases (Figures 12 to 14).
Consider, for instance, madelon viz-a-viz e2006-tﬁdf .
In Approximate Homotopy (Section 3.3.6, main paper), we discuss a remedy for this solution that is readily available through our method.
CD
Hessian Correlation Estimate
[Figure]
H e ss i a n ( A pp r ox )
H e ss i a n ( F u ll )
W o r k
i ng
[Figure] [Figure]
T i m e (
[Figure]
A c ti v e P r e d i c t
o r s
[Figure] [Figure]
r
[Figure] [Figure]
e ss i a n (
[Figure]
u
[Figure] [Figure]
o
[Figure]
k
i
[Figure]