Parallel coordinate descent methods for big data optimization
- First Online:
- Received:
- Accepted:
DOI: 10.1007/s10107-015-0901-6
- Cite this article as:
- Richtárik, P. & Takáč, M. Math. Program. (2016) 156: 433. doi:10.1007/s10107-015-0901-6
- 23 Citations
- 5.6k Downloads
Abstract
In this work we show that randomized (block) coordinate descent methods can be accelerated by parallelization when applied to the problem of minimizing the sum of a partially separable smooth convex function and a simple separable convex function. The theoretical speedup, as compared to the serial method, and referring to the number of iterations needed to approximately solve the problem with high probability, is a simple expression depending on the number of parallel processors and a natural and easily computable measure of separability of the smooth component of the objective function. In the worst case, when no degree of separability is present, there may be no speedup; in the best case, when the problem is separable, the speedup is equal to the number of processors. Our analysis also works in the mode when the number of blocks being updated at each iteration is random, which allows for modeling situations with busy or unreliable processors. We show that our algorithm is able to solve a LASSO problem involving a matrix with 20 billion nonzeros in 2 h on a large memory node with 24 cores.
Keywords
Parallel coordinate descentBig data optimization Partial separabilityHuge-scale optimizationIteration complexity Expected separable over-approximationComposite objective Convex optimizationLASSOMathematics Subject Classification
90C0690C2549M2049M2765K0568W1068W2068W401 Introduction
1.1 Big data optimization
Recently there has been a surge in interest in the design of algorithms suitable for solving convex optimization problems with a huge number of variables [12, 15]. Indeed, the size of problems arising in fields such as machine learning [1], network analysis [29], PDEs [27], truss topology design [16] and compressed sensing [5] usually grows with our capacity to solve them, and is projected to grow dramatically in the next decade. In fact, much of computational science is currently facing the “big data” challenge, and this work is aimed at developing optimization algorithms suitable for the task.
1.2 Coordinate descent methods
Coordinate descent methods (CDM) are one of the most successful classes of algorithms in the big data optimization domain. Broadly speaking, CDMs are based on the strategy of updating a single coordinate (or a single block of coordinates) of the vector of variables at each iteration. This often drastically reduces memory requirements as well as the arithmetic complexity of a single iteration, making the methods easily implementable and scalable. In certain applications, a single iteration can amount to as few as 4 multiplications and additions only [16]! On the other hand, many more iterations are necessary for convergence than it is usual for classical gradient methods. Indeed, the number of iterations a CDM requires to solve a smooth convex optimization problem is \(O(\tfrac{n \tilde{L} R^2}{\epsilon })\), where \(\epsilon \) is the error tolerance, \(n\) is the number variables (or blocks of variables), \(\tilde{L}\) is the average of the Lipschitz constants of the gradient of the objective function associated with the variables (blocks of variables) and \(R\) is the distance from the starting iterate to the set of optimal solutions. On balance, as observed by numerous authors, serial CDMs are much more efficient for big data optimization problems than most other competing approaches, such as gradient methods [10, 16].
1.3 Parallelization
We wish to point out that for truly huge-scale problems it is absolutely necessary to parallelize. This is in line with the rise and ever increasing availability of high performance computing systems built around multi-core processors, GPU-accelerators and computer clusters, the success of which is rooted in massive parallelization. This simple observation, combined with the remarkable scalability of serial CDMs, leads to our belief that the study of parallel coordinate descent methods (PCDMs) is a very timely topic.
1.4 Research idea
The work presented in this paper was motivated by the desire to answer the following question:
Under what natural and easily verifiable structural assumptions on the objective function does parallelization of a coordinate descent method lead to acceleration?
Our starting point was the following simple observation. Assume that we wish to minimize a separable function \(F\) of \(n\) variables (i.e., a function that can be written as a sum of \(n\) functions each of which depends on a single variable only). For simplicity, in this thought experiment, assume that there are no constraints. Clearly, the problem of minimizing \(F\) can be trivially decomposed into \(n\) independent univariate problems. Now, if we have \(n\) processors/threads/cores, each assigned with the task of solving one of these problems, the number of parallel iterations should not depend on the dimension of the problem. In other words, we get an \(n\)-times speedup compared to the situation with a single processor only. Any parallel algorithm of this type can be viewed as a parallel coordinate descent method. Hence, PCDM with \(n\) processors should be \(n\)-times faster than a serial one. If \(\tau \) processors are used instead, where \(1\le \tau \le n\), one would expect a \(\tau \)-times speedup.
By extension, one would perhaps expect that optimization problems with objective functions which are “close to being separable” would also be amenable to acceleration by parallelization, where the acceleration factor \(\tau \) would be reduced with the reduction of the “degree of separability”. One of the main messages of this paper is an affirmative answer to this. Moreover, we give explicit and simple formulae for the speedup factors.
As it turns out, and as we discuss later in this section, many real-world big data optimization problems are, quite naturally, “close to being separable”. We believe that this means that PCDMs is a very promising class of algorithms for structured big data optimization problems.
1.5 Minimizing a partially separable composite objective
1.6 Examples of partially separable functions
Three examples of loss of functions
Square loss | \(\tfrac{1}{2}(A_j^T x - y_j)^2\) |
Logistic loss | \(\log (1 + e^{-y_j A_j^T x})\) |
Hinge square loss | \(\tfrac{1}{2}\max \{0, 1- y_j A_j^Tx\}^2\) |
1.7 Brief literature review
Several papers were written recently studying the iteration complexity of serial CDMs of various flavours and in various settings. We will only provide a brief summary here, for a more detailed account we refer the reader to [15].
Classical CDMs update the coordinates in a cyclic order; the first attempt at analyzing the complexity of such a method is due to [21]. Stochastic/randomized CDMs, that is, methods where the coordinate to be updated is chosen randomly, were first analyzed for quadratic objectives [4, 24], later independently generalized to \(L_1\)-regularized problems [23] and smooth block-structured problems [10], and finally unified and refined in [15, 19]. The problems considered in the above papers are either unconstrained or have (block) separable constraints. Recently, randomized CDMs were developed for problems with linearly coupled constraints [7, 8].
A greedy CDM for \(L_1\)-regularized problems was first analyzed in [16]; more work on this topic include [2, 5]. A CDM with inexact updates was first proposed and analyzed in [26]. Partially separable problems were independently studied in [13], where an asynchronous parallel stochastic gradient algorithm was developed to solve them.
When writing this paper, the authors were aware only of the parallel CDM proposed and analyzed in [1]. Several papers on the topic appeared around the time this paper was finalized or after [6, 14, 22, 22, 28]. Further papers on various aspects of the topic of parallel CDMs, building on the work in this paper, include [3, 17, 18, 25].
1.8 Contents
We start in Sect. 2 by describing the block structure of the problem, establishing notation and detailing assumptions. Subsequently we propose and comment in detail on two parallel coordinate descent methods. In Sect. 3 we summarize the main contributions of this paper. In Sect. 4 we deal with issues related to the selection of the blocks to be updated in each iteration. It will involve the development of some elementary random set theory. Sections 5 and 6 deal with issues related to the computation of the update to the selected blocks and develop a theory of Expected Separable Overapproximation (ESO), which is a novel tool we propose for the analysis of our algorithms. In Sect. 7 we analyze the iteration complexity of our methods and finally, Sect. 8 reports on promising computational results. For instance, we conduct an experiment with a big data (cca 350GB) LASSO problem with a billion variables. We are able to solve the problem using one of our methods on a large memory machine with 24 cores in 2 h, pushing the difference between the objective value at the starting iterate and the optimal point from \(10^{22}\) down to \(10^{-14}\). We also conduct experiments on real data problems coming from machine learning.
2 Parallel block coordinate descent methods
In Sect. 2.1 we formalize the block structure of the problem, establish notation^{1} that will be used in the rest of the paper and list assumptions. In Sect. 2.2 we propose two parallel block coordinate descent methods and comment in some detail on the steps.
2.1 Block structure, notation and assumptions
The block structure^{2} of (1) is given by a decomposition of \(\mathbf {R}^N\) into \(n\) subspaces as follows. Let \(U\in \mathbf {R}^{N\times N}\) be a column permutation^{3} of the \(N\times N\) identity matrix and further let \(U= [U_1,U_2,\ldots ,U_n]\) be a decomposition of \(U\) into \(n\) submatrices, with \(U_i\) being of size \(N\times N_i\), where \(\sum _i N_i = N\).
Proposition 1
Proof
In view of the above proposition, from now on we write \(x^{(i)}\mathop {=}\limits ^{\text {def}}U_i^T x \in \mathbf {R}^{N_i}\), and refer to \(x^{(i)}\) as the \(i\)th block of \(x\). The definition of partial separability in the introduction is with respect to these blocks. For simplicity, we will sometimes write \(x = (x^{(1)},\ldots ,x^{(n)})\).
2.1.1 Projection onto a set of blocks
2.1.2 Inner products
2.1.3 Norms
2.1.4 Smoothness of \(f\)
2.1.5 Separability of \(\varOmega \)
2.1.6 Strong convexity
2.2 Algorithms
Let us comment on the individual steps of the two methods.
Step 3. At the beginning of iteration \(k\) we pick a random set (\(S_k\)) of blocks to be updated (in parallel) during that iteration. The set \(S_k\) is a realization of a random set-valued mapping \(\hat{S}\) with values in \(2^{[n]}\) or, more precisely, it the sets \(S_k\) are iid random sets with the distribution of \(\hat{S}\). For brevity, in this paper we refer to such a mapping by the name sampling. We limit our attention to uniform samplings, i.e., random sets having the following property: \(\mathbf {P}(i \in \hat{S})\) is independent of \(i\). That is, the probability that a block gets selected is the same for all blocks. Although we give an iteration complexity result covering all such samplings (provided that each block has a chance to be updated, i.e., \(\mathbf {P}(i \in \hat{S}) > 0\)), there are interesting subclasses of uniform samplings (such as doubly uniform and nonoverlapping uniform samplings; see Sect. 4) for which we give better results.
Section 6 is devoted to the computation of \(\beta \) and \(w\) for partially separable \(f\) and various special classes of uniform samplings \(\hat{S}\). Typically we will have \(w_i=L_i\), while \(\beta \) will depend on easily computable properties of \(f\) and \(\hat{S}\). For example, if \(\hat{S}\) is chosen as a subset of \({[n]}\) of cardinality \(\tau \), with each subset chosen with the same probability (we say that \(\hat{S}\) is \(\tau \)-nice) then, assuming \(n>1\), we may choose \(w=L\) and \(\beta =1+ \tfrac{(\omega -1)(\tau -1)}{n-1}\), where \(\omega \) is the degree of partial separability of \(f\). More generally, if \(\hat{S}\) is any uniform sampling with the property \(|\hat{S}|=\tau \) with probability 1, then we may choose \(w=L\) and \(\beta =\min \{\omega ,\tau \}\). Note that in both cases \(w=L\) and that the latter \(\beta \) is always larger than (or equal to) the former one. This means, as we will see in Sect. 7, that we can give better complexity results for the former, more specialized, sampling. We analyze several more options for \(\hat{S}\) than the two just described, and compute parameters \(\beta \) and \(w\) that should be used with them (for a summary, see Table 4).
Step 5. The reason why, besides PCDM1, we also consider PCDM2, is the following: in some situations we are not able to analyze the iteration complexity of PCDM1 (non-strongly-convex \(F\) where monotonicity of the method is not guaranteed by other means than by directly enforcing it by inclusion of Step 5). Let us remark that this issue arises for general \(\Omega \) only. It does not exist for \(\Omega =0\), \(\Omega (\cdot ) = \lambda \Vert \cdot \Vert _1\) and for \(\Omega \) encoding simple constraints on individual blocks; in these cases one does not need to consider PCDM2. Even in the case of general \(\Omega \) we sometimes get monotonicity for free, in which case there is no need to enforce it. Let us stress, however, that we do not recommend implementing PCDM2 as this would introduce too much overhead; in our experience PCDM1 works well even in cases when we can only analyze PCDM2.
3 Smmary of contributions
In this section we summarize the main contributions of this paper (not in order of significance).
- 1.
Problem generality We give the first complexity analysis for parallel coordinate descent methods for problem (1) in its full generality.
- 2.Complexity We show theoretically (Sect. 7) and numerically (Sect. 8) that PCDM accelerates on its serial counterpart for partially separable problems. In particular, we establish two complexity theorems giving lower bounds on the number of iterations \(k\) sufficient for one or both of the PCDM variants (for details, see the precise statements in Sect. 7) to produce a random iterate \(x_k\) for which the problem is approximately solved with high probability, i.e., \(\mathbf {P}(F(x_k)-F^* \le \epsilon ) \ge 1-\rho \). The results, summarized in Table 2, hold under the standard assumptions listed in Sect. 2.1and the additional assumption that \(f,\hat{S},\beta \) and \(w\) satisfy the following inequality for all \(x,h\in \mathbf {R}^N\):This inequality, which we call Expected Separable Overapproximation (ESO), is the main new theoretical tool that we develop in this paper for the analysis of our methods (Sects. 4, 5 and 6 are devoted to the development of this theory).$$\begin{aligned} {{\mathrm{\mathbf {E}}}}[f(x+h_{[\hat{S}]})] \le f(x) + \tfrac{{{\mathrm{\mathbf {E}}}}[|\hat{S}|]}{n}\left( \langle \nabla f(x) , h \rangle + \tfrac{\beta }{2}\Vert h\Vert _w^2\right) . \end{aligned}$$(19)Table 2
Summary of the main complexity results for PCDM established in this paper
Setting
Complexity
Theorem
Convex \(f\)
\(\mathcal{O} \left( \frac{\beta n}{{{\mathrm{\mathbf {E}}}}[|\hat{S}|] }\frac{1}{\epsilon }\log \left( \tfrac{1}{\rho }\right) \right) \)
\(\begin{array}{l} \hbox {Strongly convex} f \mu _f(w)+\mu _\Omega (w)>0 \end{array}\)
\(\frac{n}{{{\mathrm{\mathbf {E}}}}[|\hat{S}|]} \frac{\beta + \mu _\Omega (w)}{\mu _f(w)+\mu _\Omega (w)} \log \left( \frac{F(x_0)-F^*}{\epsilon \rho }\right) \)
The main observation here is that as the average number of block updates per iteration increases (say, \(\hat{\tau }={{\mathrm{\mathbf {E}}}}[|\hat{S}|]\)), enabled by the utilization of more processors, the leading term in the complexity estimate, \(n/\hat{\tau }\), decreases in proportion. However, \(\beta \) will generally grow with \(\hat{\tau }\), which has an adverse effect on the speedup. Much of the theory in this paper goes towards producing formulas for \(\beta \) (and \(w\)), for partially separable \(f\) and various classes of uniform samplings \(\hat{S}\). Naturally, the ideal situation is when \(\beta \) does not grow with \(\hat{\tau }\) at all, or if it only grows very slowly. We show that this is the case for partially separable functions \(f\) with small \(\omega \). For instance, in the extreme case when \(f\) is separable (\(\omega =1\)), we have \(\beta =1\) and we obtain linear speedup in \(\hat{\tau }\). As \(\omega \) increases, so does \(\beta \), depending on the law governing \(\hat{S}\). Formulas for \(\beta \) and \(\omega \) for various samplings \(\hat{S}\) are summarized in Table 4.
- 3.
Algorithm unification Depending on the choice of the block structure (as implied by the choice of \(n\) and the matrices \(U_1,\ldots ,U_n\)) and the way blocks are selected at every iteration (as given by the choice of \(\hat{S}\)), our framework encodes a family of known and new algorithms^{7} (see Table 3).
In particular, PCDM is the first method which “continuously” interpolates between serial coordinate descent and gradient (by manipulating \(n\) and/or \(\mathbf {E}[|\hat{S}|]\)).
- 4.
Partial separability We give the first analysis of a coordinate descent type method dealing with a partially separable loss / objective. In order to run the method, we need to know the Lipschitz constants \(L_i\) and the degree of partial separability \(\omega \). It is crucial that these quantities are often easily computable/predictable in the huge-scale setting. For example, if \(f(x) = \tfrac{1}{2}\Vert Ax-b\Vert ^2\) and we choose all blocks to be of size \(1\), then \(L_i\) is equal to the squared Euclidean norm of the \(i\)th column of \(A\) and \(\omega \) is equal to the maximum number of nonzeros in a row of \(A\). Many problems in the big data setting have small \(\omega \) compared to \(n\).
- 5.
Choice of blocks To the best of our knowledge, existing randomized strategies for paralleling gradient-type methods (e.g., [1]) assume that \(\hat{S}\) (or an equivalent thereof, based on the method) is chosen as a subset of \([n]\) of a fixed cardinality, uniformly at random. We refer to such \(\hat{S}\) by the name nice sampling in this paper. We relax this assumption and our treatment is hence much more general. In fact, we allow for \(\hat{S}\) to be any uniform sampling. It is possible to further consider nonuniform samplings,^{8} but this is beyond the scope of this paper.
In particular, as a special case, our method allows for a variable number of blocks to be updated throughout the iterations (this is achieved by the introduction of doubly uniform samplings). This may be useful in some settings such as when the problem is being solved in parallel by \(\tau \) unreliable processors each of which computes its update \(h^{(i)}(x_k)\) with probability \(p_b\) and is busy/down with probability \(1-p_b\) (binomial sampling).
Uniform, doubly uniform, nice, binomial and other samplings are defined, and their properties studied, in Sect. 4.
- 6.
ESO and formulas for\(\beta \)and\(w\). In Table 4 we list parameters \(\beta \) and \(w\) for which ESO inequality (19) holds. Each row corresponds to a specific sampling \(\hat{S}\) (see Sect. 4 for the definitions). The last 5 samplings are special cases of one or more of the first three samplings. Details such as what is \(\nu ,\gamma \) and “monotonic” ESO are explained in appropriate sections later in the text. When a specific sampling \(\hat{S}\) is used in the algorithm to select blocks in each iteration, the corresponding parameters \(\beta \) and \(w\) are to be used in the method for the computation of the update (see Eqs. 17 and 18).
En route to proving the iteration complexity results for our algorithms, we develop a theory of deterministic and expected separable overapproximation (Sects. 5, 6) which we believe is of independent interest, too. For instance, methods based on ESO can be compared favorably to the Diagonal Quadratic Approximation (DQA) approach used in the decomposition of stochastic optimization programs [20].
- 7.
Parallelization speedup Our complexity results can be used to derive theoretical parallelization speedup factors. For several variants of our method, in case of a non-strongly convex objective, these are summarized in Table 5 (see Sect 7.1 for the derivations). For instance, in the case when all block are updated at each iteration (we later refer to \(\hat{S}\) having this property by the name fully parallel sampling), the speedup factor is equal to \(\tfrac{n}{\omega }\). If the problem is separable (\(\omega =1\)), the speedup is equal to \(n\); if the problem is not separable (\(\omega =n\)), there may be no speedup. For strongly convex \(F\) the situation is even better; the details are given in Sect. 7.2.
- 8.
Relationship to existing results To the best of our knowledge, there are just two papers analyzing a parallel coordinate descent algorithm for convex optimization problems[1, 6]. In the first paper all blocks are of size \(1\), \(\hat{S}\) corresponds to what we call in this paper a \(\tau \)-nice sampling (i.e., all sets of \(\tau \) coordinates are updated at each iteration with equal probability) and hence their algorithm is somewhat comparable to one of the many variants of our general method. While the analysis in [1] works for a restricted range of values of \(\tau \), our results hold for all \(\tau \in {[n]}\). Moreover, the authors consider a more restricted class of functions \(f\) and the special case \(\Omega =\lambda \Vert x\Vert _1\), which is simpler to analyze. Lastly, the theoretical speedups obtained in [1], when compared to the serial CDM method, depend on a quantity \(\sigma \) that is hard to compute in big data settings (it involves the computation of an eigenvalue of a huge-scale matrix). Our speedups are expressed in terms of natural and easily computable quantity: the degree \(\omega \) of partial separability of \(f\). In the setting considered by [1], in which more structure is available, it turns out that \(\omega \) is an upper bound^{9} on \(\sigma \). Hence, we show that one can develop the theory in a more general setting, and that it is not necessary to compute \(\sigma \) (which may be complicated in the big data setting). The parallel CDM method of the second paper [6] only allows all blocks to be updated at each iteration. Unfortunately, the analysis (and the method) is too coarse as it does not offer any theoretical speedup when compared to its serial counterpart. In the special case when only a single block is updated in each iteration, uniformly at random, our theoretical results specialize to those established in [15].
- 9.
Computations We demonstrate that our method is able to solve a LASSO problem involving a matrix with a billion columns and 2 billion rows on a large memory node with 24 cores in 2 h (Sect. 8), achieving a \(20\times \) speedup compared to the serial variant and pushing the residual by more than 30 degrees of magnitude. While this is done on an artificial problem under ideal conditions (controlling for small \(\omega \)), large speedups are possible in real data with \(\omega \) small relative to \(n\). We also perform additional experiments on real machine learning data sets (e.g., training linear SVMs) to illustrate that the predictions of our theory match reality.
- 10.
Code The open source code with an efficient implementation of the algorithm(s) developed in this paper is published here: http://code.google.com/p/ac-dc/.
New and known gradient methods obtained as special cases of our general framework
Method | Parameters | Comment |
---|---|---|
Gradient descent | \(n=1\) | [11] |
Serial random CDM | \(N_i=1\) for all \(i\) and \(\mathbf {P}(|\hat{S}|=1)=1\) | [15] |
Serial block random CDM | \(N_i\ge 1\) for all \(i\) and \(\mathbf {P}(|\hat{S}|=1)=1\) | [15] |
Parallel random CDM | \(\mathbf {P}(|\hat{S}|>1) > 0 \) | NEW |
Distributed random CDM | \(\hat{S}\) is a distributed sampling | [17]\(^{\mathrm{a}}\) |
Values of parameters \(\beta \) and \(w\) for various samplings \(\hat{S}\)
sampling \(\hat{S}\) | \({{\mathrm{\mathbf {E}}}}[|\hat{S}|]\) | \(\beta \) | \(w\) | ESO monotonic? | Follows from |
---|---|---|---|---|---|
uniform | \(\mathbf {E}[|\hat{S}|] \) | \(1\) | \(\nu \odot L\) | No | Thm 10 |
nonoverlapping uniform | \(\tfrac{n}{l}\) | \(1\) | \(\gamma \odot L\) | Yes | Thm 11 |
doubly uniform | \({{\mathrm{\mathbf {E}}}}[|\hat{S}|]\) | \(1+\frac{ (\omega -1)\left( \frac{{{\mathrm{\mathbf {E}}}}[|\hat{S}|^2]}{{{\mathrm{\mathbf {E}}}}[|\hat{S}|]}-1\right) }{\max (1,n-1)}\) | \(L\) | No | Thm 13 |
\(\tau \)-uniform | \(\tau \) | \(\min \{\omega ,\tau \}\) | \(L\) | Yes | Thm 10 |
\(\tau \)-nice | \(\tau \) | \(1+ \frac{ (\omega -1)(\tau -1)}{\max (1,n-1)}\) | \(L\) | No | |
\((\tau ,p_b)\)-binomial | \(\tau p_b\) | \(1+ \frac{p_b(\omega -1)(\tau -1)}{\max (1,n-1)}\) | \(L\) | No | Thm 13 |
serial | \(1\) | \(1\) | \(L\) | Yes | |
fully parallel | \(n\) | \(\omega \) | \(L\) | Yes |
Convex \(F\): Parallelization speedup factors for DU samplings. The factors below the line are special cases of the general expression. Maximum speedup is naturally obtained by the fully parallel sampling: \(\tfrac{n}{\omega }\)
\(\hat{S}\) | Parallelization speedup factor |
---|---|
Doubly uniform | \(\frac{\mathbf {E}[|\hat{S}|]}{1 + \tfrac{(\omega -1)\left( (\mathbf {E}[|\hat{S}|^2]/\mathbf {E}[|\hat{S}|])-1\right) }{\max (1,n-1)}}\) |
\((\tau ,p_b)\)-binomial | \(\frac{\tau }{\tfrac{1}{p_b}+ \tfrac{(\omega -1)(\tau -1)}{\max (1,n-1)}}\) |
\(\tau \)-nice | \(\frac{\tau }{1+ \tfrac{(\omega -1)(\tau -1)}{\max (1,n-1)}}\) |
Fully parallel | \(\frac{n}{\omega }\) |
Serial | \(1\) |
4 Block samplings
4.1 Uniform, doubly uniform and nonoverlapping uniform samplings
A sampling is proper if \(p_i>0\) for all blocks \(i\). That is, from the perspective of PCDM, under a proper sampling each block gets updated with a positive probability at each iteration. Clearly, PCDM can not converge for a sampling that is not proper. A sampling \(\hat{S}\) is uniform if all blocks get updated with the same probability, i.e., if \(p_i=p_j\) for all \(i,j\). We show in (33) that, necessarily, \(p_i = \tfrac{\mathbf {E}[|\hat{S}|]}{n}\). Further, we say \(\hat{S}\) is nil if \(\mathbf {P}(\emptyset ) = 1\). Note that a uniform sampling is proper if and only if it is not nil.
All complexity results of this paper are formulated for proper uniform samplings. We give a complexity result covering all such samplings. However, the family of proper uniform samplings is large, with several interesting subfamilies for which we can give better results. We now define these families.
- 1.Doubly Uniform (DU) samplings A DU sampling is one which generates all sets of equal cardinality with equal probability. That is, \(\mathbf {P}(S')=\mathbf {P}(S'')\) whenever \(|S'| = |S''|\). The name comes from the fact that this definition postulates a different uniformity property, “standard” uniformity is a consequence. Indeed, let us show that a DU sampling is necessarily uniform. Let \(q_j = \mathbf {P}(|\hat{S}| = j)\) for \(j=0,1,\ldots , n\) and note that from the definition we know that whenever \(S\) is of cardinality \(j\), we have \(\mathbf {P}(S) = q_j/{n \atopwithdelims ()j}\). Finally, using this we obtainIt is clear that each DU sampling is uniquely characterized by the vector of probabilities \(q\); its density function is given by$$\begin{aligned} p_i= & {} \sum \limits _{S:i\in S} \mathbf {P}(S) = \sum \limits _{j=1}^n \sum \limits _{\begin{array}{c} S: i \in S\\ |S|=j \end{array}} \mathbf {P}(S) = \sum \limits _{j=1}^n \sum \limits _{\begin{array}{c} S: i \in S |S|=j \end{array}} \tfrac{q_j}{{n \atopwithdelims ()j}} =\sum \limits _{j=1}^n \tfrac{{n-1\atopwithdelims ()j-1}}{{n\atopwithdelims ()j}} q_j\nonumber \\= & {} \tfrac{1}{n}\sum \limits _{j=1}^n q_j j = \tfrac{\mathbf {E}[|\hat{S}|]}{n}. \end{aligned}$$$$\begin{aligned} \mathbf {P}(S) = q_{|S|}/ {n \atopwithdelims ()|S|}, \quad S \subseteq {[n]}. \end{aligned}$$(22)
- 2.Nonoverlapping Uniform (NU) samplings A NU sampling is one which is uniform and which assigns positive probabilities only to sets forming a partition of \({[n]}\). Let \(S^1,S^2,\ldots , S^l\) be a partition of \({[n]}\), with \(|S^j|>0\) for all \(j\). The density function of a NU sampling corresponding to this partition is given byNote that \(\mathbf {E}[|\hat{S}|] = \tfrac{n}{l}\).$$\begin{aligned} \mathbf {P}(S) = {\left\{ \begin{array}{ll}\tfrac{1}{l}, &{} \quad \text {if } S \in \{S^1,S^2,\ldots ,S^l\},\\ 0, &{} \quad \text {otherwise.}\end{array}\right. } \end{aligned}$$(23)
- 3.
Nice sampling Fix \(1\le \tau \le n\). A \(\tau \)-nice sampling is a DU sampling with \(q_\tau = 1\). Interpretation: There are \(\tau \) processors/threads/cores available. At the beginning of each iteration we choose a set of blocks using a \(\tau \)-nice sampling (i.e., each subset of \(\tau \) blocks is chosen with the same probability), and assign each block to a dedicated processor/thread/core. Processor assigned with block \(i\) would compute and apply the update \(h^{(i)}(x_k)\). This is the sampling we use in our computational experiments.
- 4.Independent sampling Fix \(1\le \tau \le n\). A \(\tau \)-independent sampling is a DU sampling withwhere \(c_1 = \left( \tfrac{1}{n}\right) ^\tau \) and \(c_{k} = \left( \tfrac{k}{n}\right) ^\tau - \sum _{i=1}^{k-1} {k \atopwithdelims ()i}c_i\) for \(k \ge 2\). Interpretation: There are \(\tau \) processors/threads/cores available. Each processor chooses one of the \(n\) blocks, uniformly at random and independently of the other processors. It turns out that the set \(\hat{S}\) of blocks selected this way is DU with \(q\) as given above. Since in one parallel iteration of our methods each block in \(\hat{S}\) is updated exactly once, this means that if two or more processors pick the same block, all but one will be idle. On the other hand, this sampling can be generated extremely easily and in parallel! For \(\tau \ll n\) this sampling is a good (and fast) approximation of the \(\tau \)-nice sampling. For instance, for \(n=10^3\) and \(\tau =8\) we have \(q_8=0.9723\), \(q_7=0.0274\), \(q_6=0.0003\) and \(q_k\approx 0\) for \(k=1,\ldots ,5\).$$\begin{aligned} q_k = {\left\{ \begin{array}{ll}{n \atopwithdelims ()k} c_k, \quad &{} k=1,2,\ldots ,\tau ,\\ 0, \quad &{} k=\tau +1, \ldots , n, \end{array}\right. } \end{aligned}$$
- 5.Binomial sampling Fix \(1\le \tau \le n\) and \(0< p_b \le 1\). A \((\tau ,p_b)\)-binomial sampling is defined as a DU sampling withNotice that \(\mathbf {E}[|\hat{S}|] =\tau p_b\) and \(\mathbf {E}[|\hat{S}|^2] = \tau p_b(1+ \tau p_b - p_b)\).$$\begin{aligned} q_k = {\tau \atopwithdelims ()k} p_b^k (1-p_b)^k, \quad k=0,1,\ldots ,\tau . \end{aligned}$$(24)Interpretation: Consider the following situation with independent equally unreliable processors. We have \(\tau \) processors, each of which is at any given moment available with probability \(p_b\) and busy with probability \(1-p_b\), independently of the availability of the other processors. Hence, the number of available processors (and hence blocks that can be updated in parallel) at each iteration is a binomial random variable with parameters \(\tau \) and \(p_b\). That is, the number of available processors is equal to \(k\) with probability \(q_k\).
Case 1 (explicit selection of blocks): We learn that \(k\) processors are available at the beginning of each iteration. Subsequently, we choose \(k\) blocks using a \(k\)-nice sampling and “assign one block” to each of the \(k\) available processors.
Case 2 (implicit selection of blocks): We choose \(\tau \) blocks using a \(\tau \)-nice sampling and assign one to each of the \(\tau \) processors (we do not know which will be available at the beginning of the iteration). With probability \(q_k\), \(k\) of these will send their updates. It is easy to check that the resulting effective sampling of blocks is \((\tau ,p_b)\)-binomial.
- 6.
Serial sampling This is a DU sampling with \(q_1 = 1\). Also, this is a NU sampling with \(l=n\) and \(S^j=\{j\}\) for \(j=1,2,\ldots ,l\). That is, at each iteration we update a single block, uniformly at random. This was studied in [15].
- 7.
Fully parallel sampling This is a DU sampling with \(q_n = 1\). Also, this is a NU sampling with \(l=1\) and \(S^1 = {[n]}\). That is, at each iteration we update all blocks.
Example 2
Sampling \(\hat{S}\) defined by \(\mathbf {P}(\hat{S}=\{1\})=0.5\), \(\mathbf {P}(\hat{S}=\{2\})=0.4\) and \(\mathbf {P}(\hat{S}=\{3\})=0.1\) is not uniform.
Sampling \(\hat{S}\) defined by \(\mathbf {P}(\hat{S}=\{1,2\}) = 2/3\) and \(\mathbf {P}(\hat{S}=\{3\})=1/3\) is uniform and NU, but it is not DU (and, particular, it is not \(\tau \)-nice for any \(\tau \)).
Sampling \(\hat{S}\) defined by \(\mathbf {P}(\hat{S}=\{1,2\}) = 1/3\), \(\mathbf {P}(\hat{S}=\{2,3\}) = 1/3\) and \(\mathbf {P}(\hat{S}=\{3,1\}) = 1/3\) is \(2\)-nice. Since all \(\tau \)-nice samplings are DU, it is DU. Since all DU samplings are uniform, it is uniform.
Sampling \(\hat{S}\) defined by \(\mathbf {P}(\hat{S}=\{1,2,3\}) =1\) is \(3\)-nice. This is the fully parallel sampling. It is both DU and NU.
The following simple result says that the intersection between the class of DU and NU samplings is very thin. A sampling is called vacuous if \(\mathbf {P}(\emptyset )>0\).
Proposition 3
There are precisely two nonvacuous samplings which are both DU and NU: i) the serial sampling and ii) the fully parallel sampling.
Proof
Assume \(\hat{S}\) is nonvacuous, NU and DU. Since \(\hat{S}\) is nonvacuous, \(\mathbf {P}(\hat{S}= \emptyset )=0\). Let \(S\subset {[n]}\) be any set for which \(\mathbf {P}(\hat{S}=S)>0\). If \(1<|S|<n\), then there exists \(S'\ne S\) of the same cardinality as \(S\) having a nonempty intersection with \(S\). Since \(\hat{S}\) is doubly uniform, we must have \(\mathbf {P}(\hat{S}=S') = \mathbf {P}(\hat{S}= S')>0\). However, this contradicts the fact that \(\hat{S}\) is non-overlapping. Hence, \(\hat{S}\) can only generate sets of cardinalities \(1\) or \(n\) with positive probability, but not both. One option leads to the fully parallel sampling, the other one leads to the serial sampling.
4.2 Technical results
Lemma 4
Proof
The consequences are summarized in the next theorem and the discussion that follows.
Theorem 5
Proof
- Uniform samplings. If \(\hat{S}\) is uniform, then from (28) using \(J={[n]}\) we getPlugging (33) into (28, 30, 31) and (32) yields$$\begin{aligned} p_i = \tfrac{{{\mathrm{\mathbf {E}}}}\left[ |\hat{S}|\right] }{n}, \qquad i \in {[n]}. \end{aligned}$$(33)$$\begin{aligned} {{\mathrm{\mathbf {E}}}}\left[ |J\cap \hat{S}|\right]= & {} \tfrac{|J|}{n}\mathbf {E}[|\hat{S}|],\end{aligned}$$(34)$$\begin{aligned} {{\mathrm{\mathbf {E}}}}\left[ \langle a , h_{[\hat{S}]} \rangle _w\right]= & {} \tfrac{{{\mathrm{\mathbf {E}}}}\left[ |\hat{S}|\right] }{n} \langle a , h \rangle _w,\end{aligned}$$(35)$$\begin{aligned} \mathbf {E}\left[ \Vert h_{[\hat{S}]}\Vert _w^2 \right]= & {} \tfrac{{{\mathrm{\mathbf {E}}}}\left[ |\hat{S}|\right] }{n} \Vert h\Vert ^2_{w},\end{aligned}$$(36)$$\begin{aligned} {{\mathrm{\mathbf {E}}}}\left[ g(x+h_{[\hat{S}]})\right]= & {} \tfrac{{{\mathrm{\mathbf {E}}}}[|\hat{S}|]}{n} g(x+h) + \left( 1-\tfrac{{{\mathrm{\mathbf {E}}}}[|\hat{S}|]}{n}\right) g(x). \end{aligned}$$(37)
- Doubly uniform samplings. Consider the case \(n>1\); the case \(n=1\) is trivial. For doubly uniform \(\hat{S}\), \(p_{ij}\) is constant for \(i\ne j\):Indeed, this follows from$$\begin{aligned} p_{ij} = \tfrac{\mathbf {E}[|\hat{S}|^2-|\hat{S}|]}{n(n-1)}. \end{aligned}$$(38)Substituting (38) and (33) into (29) then gives$$\begin{aligned} p_{ij} = \sum _{k=1}^n \mathbf {P}(\{i,j\}\subseteq \hat{S}\;|\; |\hat{S}| = k)\mathbf {P}(|\hat{S}|=k) = \sum _{k=1}^n \tfrac{k(k-1)}{n(n-1)}\mathbf {P}(|\hat{S}|=k). \end{aligned}$$$$\begin{aligned} \mathbf {E}[|J \cap \hat{S}|^2] = (|J|^2 - |J|)\tfrac{\mathbf {E}[|\hat{S}|^2-|\hat{S}|]}{n\max \{1,n-1\}} + |J|\tfrac{|\hat{S}|}{n}. \end{aligned}$$(39)
- Nice samplings. Finally, if \(\hat{S}\) is \(\tau \)-nice (and \(\tau \ne 0\)), then \(\mathbf {E}[|\hat{S}|]=\tau \) and \(\mathbf {E}[|\hat{S}|^2] = \tau ^2\), which used in (39) givesMoreover, assume that \(\mathbf {P}(|J \cap \hat{S}|=k) \ne 0\) (this happens precisely when \(0\le k \le |J|\) and \(k \le \tau \le n-|J|+k\)). Then for all \(i \in J\),$$\begin{aligned} \mathbf {E}[|J \cap \hat{S}|^2] = \tfrac{|J|\tau }{n}\left( 1+ \tfrac{(|J| - 1)(\tau -1)}{\max \{1,n-1\}}\right) . \end{aligned}$$(40)Substituting this into (26) yields$$\begin{aligned} \mathbf {P}(i \in \hat{S}\;|\; |J\cap \hat{S}| = k) = \frac{{|J| -1 \atopwithdelims ()k-1}{n-|J| \atopwithdelims ()\tau - k}}{{|J| \atopwithdelims ()k}{n-|J| \atopwithdelims ()\tau -k}} = \frac{k}{|J|}. \end{aligned}$$$$\begin{aligned} \mathbf {E}\left[ \sum _{i \in J \cap \hat{S}} \theta _i \;|\; |J\cap \hat{S}| = k \right] = \tfrac{k}{|J|}\sum _{i\in J} \theta _i. \end{aligned}$$(41)
5 Expected separable overapproximation
The above discussion leads to the following definition.
Definition 6
(Expected Separable Overapproximation (ESO)) Let \(\beta > 0\), \(w\in \mathbf {R}^n_{++}\) and let \(\hat{S}\) be a proper uniform sampling. We say that \(f:\mathbf {R}^N\rightarrow \mathbf {R}\) admits a \((\beta ,w)\)-ESO with respect to \(\hat{S}\) if inequality (43) holds for all \(x,h\in \mathbf {R}^N\). For simplicity, we write \((f,\hat{S}) \sim ESO(\beta ,w)\).
- 1.
Inflation If \((f,\hat{S}) \sim ESO(\beta , w)\), then for \(\beta ' \ge \beta \) and \(w'\ge w\), \((f,\hat{S})\sim ESO(\beta ',w')\).
- 2.Reshuffling Since for any \(c>0\) we have \(\Vert h\Vert _{c w}^2 = c\Vert h\Vert _{w}^2\), one can “shuffle” constants between \(\beta \) and \(w\) as follows:$$\begin{aligned} (f,\hat{S})\sim ESO(c \beta ,w) \Leftrightarrow (f,\hat{S})\sim ESO(\beta ,c w), \qquad c > 0. \end{aligned}$$(46)
- 3.Strong convexity If \((f,\hat{S}) \sim ESO(\beta , w)\), thenIndeed, it suffices to take expectation in (14) with \(y\) replaced by \(x+h_{[\hat{S}]}\) and compare the resulting inequality with (43) (this gives \(\beta \Vert h\Vert _w^2 \ge \mu _f(w)\Vert h\Vert _w^2\), which must hold for all \(h\)).$$\begin{aligned} \beta \ge \mu _f(w). \end{aligned}$$(47)
Definition 7
(Monotonic ESO) Assume \((f,\hat{S}) \sim ESO(\beta ,w)\) and let \(h(x)\) be as in (45). We say that the ESO is monotonic if \(F(x+(h(x))_{[\hat{S}]}) \le F(x)\), with probability 1, for all \(x \in {{\mathrm{dom}}}F\).
5.1 Deterministic separable overapproximation (DSO) of partially separable functions
The following theorem will be useful in deriving ESO for uniform samplings (Sect. 6.1) and nonoverlapping uniform samplings (Sect. 6.2). It will also be useful in establishing monotonicity of some ESOs (Theorems 10 and 11).
Theorem 8
Proof
- 1.
Block Lipschitz continuity of\(\nabla f\) The DSO inequality (48) is a generalization of (12) since (12) can be recovered from (48) by choosing \(h\) with \({{\mathrm{Supp}}}(h)=\{i\}\) for \(i\in {[n]}\).
- 2.Global Lipschitz continuity of\(\nabla f\) The DSO inequality also says that the gradient of \(f\) is Lipschitz with Lipschitz constant \(\omega \) with respect to the norm \(\Vert \cdot \Vert _L\):Indeed, this follows from (48) via \(\max _{J\in \mathcal J} |J\cap {{\mathrm{Supp}}}(h)| \le \max _{J\in \mathcal J} |J| = \omega \). For \(\omega =n\) this has been shown in [10]; our result for partially separable functions appears to be new.$$\begin{aligned} f(x+h) \le f(x) + \langle \nabla f(x) , h \rangle + \tfrac{\omega }{2}\Vert h\Vert _L^2. \end{aligned}$$(54)
- 3.Tightness of the global Lipschitz constant The Lipschitz constant \(\omega \) is “tight” in the following sense: there are functions for which \(\omega \) cannot be replaced in (54) by any smaller number. We will show this on a simple example. Let \(f(x)=\tfrac{1}{2}\Vert Ax\Vert ^2\) with \(A\in \mathbf {R}^{m\times n}\) (blocks are of size 1). Note that we can write \(f(x+h) = f(x) + \langle \nabla f(x) , h \rangle + \tfrac{1}{2}h^T A^T A h\), and that \(L=(L_1,\ldots ,L_n)={{\mathrm{diag}}}(A^TA)\). Let \(D={{\mathrm{Diag}}}(L)\). We need to argue that there exists \(A\) for which \(\sigma \mathop {=}\limits ^{\text {def}}\max _{h\ne 0} \tfrac{h^T A^T A h}{\Vert h\Vert _L^2} = \omega \). Since we know that \(\sigma \le \omega \) (otherwise (54) would not hold), all we need to show is that there is \(A\) and \(h\) for whichSince \(f(x) = \sum _{i=1}^m (A_j^Tx)^2\), where \(A_j\) is the \(j\)th row of \(A\), we assume that each row of \(A\) has at most \(\omega \) nonzeros (i.e., \(f\) is partially separable of degree \(\omega \)). Let us pick \(A\) with the following further properties: a) \(A\) is a 0-1 matrix, b) all rows of \(A\) have exactly \(\omega \) ones, c) all columns of \(A\) have exactly the same number (\(k\)) of ones. Immediate consequences: \(L_i = k\) for all \(i\), \(D = k I_n\) and \(\omega m = kn\). If we let \(e_m\) be the \(m\times 1\) vector of all ones and \(e_n\) be the \(n\times 1\) vector of all ones, and set \(h = k^{-1/2}e_n\), then$$\begin{aligned} h^T A^T A h = \omega h^T D h. \end{aligned}$$(55)establishing (55). Using similar techniques one can easily prove the following more general result: Tightness also occurs for matrices \(A\) which in each row contain \(\omega \) identical nonzero elements (but which can vary from row to row).$$\begin{aligned} h^T A^T A h= & {} \tfrac{1}{k} e_n^T A^T A e_n = \tfrac{1}{k} (\omega e_m)^T (\omega e_m)\\&=\tfrac{\omega ^2 m}{k} = \omega n = \omega \tfrac{1}{k}e_n^T k I_n e_n = \omega h^T D h, \end{aligned}$$
6 Expected separable overapproximation (ESO) of partially separable functions
Here we derive ESO inequalities for partially separable smooth functions \(f\) and (proper) uniform (Sect. 6.1), nonoverlapping uniform (Sect. 6.2), nice (Sect. 6.3) and doubly uniform (Sect. 6.4) samplings.
6.1 Uniform samplings
Lemma 9
Proof
The above lemma will now be used to establish ESO for arbitrary (proper) uniform samplings.
Theorem 10
Proof
Besides establishing an ESO result, we have just shown that, in the case of \(\tau \)-uniform samplings with a conservative estimate for \(\beta \), PCDM1 is monotonic, i.e., \(F(x_{k+1})\le F(x_k)\). In particular, PCDM1 and PCDM2 coincide. We call the estimate \(\beta = \min \{\omega ,\tau \}\) “conservative” because it can be improved (made smaller) in special cases; e.g., for the \(\tau \)-nice sampling. Indeed, Theorem 12 establishes an ESO for the \(\tau \)-nice sampling with the same \(w\) (\(w=L\)), but with \(\beta = 1 + \tfrac{(\omega -1)(\tau -1)}{n-1}\), which is better (and can be much better than) \(\min \{\omega ,\tau \}\). Other things equal, smaller \(\beta \) directly translates into better complexity. The price for the small \(\beta \) in the case of the \(\tau \)-nice sampling is the loss of monotonicity. This is not a problem for strongly convex objective, but for merely convex objective this is an issue as the analysis techniques we developed are only applicable to the monotonic method PCDM2 (see Theorem 17).
6.2 Nonoverlapping uniform samplings
Theorem 11
Proof
6.3 Nice samplings
In this section we establish an ESO for nice samplings.
Theorem 12
Proof
6.4 Doubly uniform samplings
We are now ready, using a bootstrapping argument, to formulate and prove a result covering all doubly uniform samplings.
Theorem 13
Proof
Note that Theorem 13 reduces to that of Theorem 12 in the special case of a nice sampling, and gives the same result as Theorem 11 in the case of the serial and fully parallel samplings.
7 Iteration complexity
In this section we prove two iteration complexity theorems.^{11} The first result (Theorem 17) is for non-strongly-convex \(F\) and covers PCDM2 with no restrictions and PCDM1 only in the case when a monotonic ESO is used. The second result (Theorem 18) is for strongly convex \(F\) and covers PCDM1 without any monotonicity restrictions. Let us first establish two auxiliary results.
Lemma 14
For all \(x\in {{\mathrm{dom}}}F\), \(H_{\beta ,w}(x,h(x)) \le \min _{y\in \mathbf {R}^N} \{F(y) + \tfrac{\beta -\mu _f(w)}{2}\Vert y-x\Vert _w^2\}\).
Proof
Lemma 15
- (i)Let \(x^*\) be an optimal solution of (1), \(x\in {{\mathrm{dom}}}F\) and let \(R = \Vert x-x^*\Vert _w\). Then$$\begin{aligned} H_{\beta ,w}(x,h(x)) - F^* \le {\left\{ \begin{array}{ll} \left( 1-\tfrac{F(x)-F^*}{2\beta R^2}\right) (F(x)-F^*), \quad &{} \text {if } F(x)-F^*\le \beta R^2,\\ \tfrac{1}{2} \beta R^2 < \tfrac{1}{2}(F(x)-F^*), \quad &{} \text {otherwise.} \end{array}\right. } \end{aligned}$$(71)
- (ii)If \(\mu _f(w) + \mu _\Omega (w) > 0\) and \(\beta \ge \mu _f(w)\), then for all \(x\in {{\mathrm{dom}}}F\),$$\begin{aligned} H_{\beta ,w}(x,h(x)) - F^* \le \frac{\beta -\mu _f(w)}{\beta +\mu _\Omega (w)} (F(x)-F^*). \end{aligned}$$(72)
Proof
We could have formulated part (ii) of the above result using the weaker assumption \(\mu _F(w)>0\), leading to a slightly stronger result. However, we prefer the above treatment as it gives more insight.
7.1 Iteration complexity: convex case
The following lemma will be used to finish off the proof of the complexity result of this section.
Lemma 16
- (i)
\(\mathbf {E}[\xi _{k+1} \;|\; x_k] \le (1 - \tfrac{\xi _k}{c_1})\xi _k \), for all \(k\), where \(c_1>\epsilon \) is a constant,
- (ii)
\(\mathbf {E}[\xi _{k+1} \;|\; x_k] \le (1-\tfrac{1}{c_2}) \xi _k\), for all \(k\) such that \(\xi _k\ge \epsilon \), where \(c_2>1\) is a constant.
This lemma was recently extended in [26] so as to aid the analysis of a serial coordinate descent method with inexact updates, i.e., with \(h(x)\) chosen as an approximate rather than exact minimizer of \(H_{1,L}(x,\cdot )\) (see (17)). While in this paper we deal with exact updates only, the results can be extended to the inexact case.
Theorem 17
- (i)\(\epsilon <F(x_0)-F^*\) and$$\begin{aligned} K \ge 2 + \frac{2\left( \tfrac{\beta }{\alpha }\right) \max \left\{ \mathcal R^2_{w}(x_0,x^*), \tfrac{F(x_0)-F^*}{\beta }\right\} }{\epsilon } \left( 1 - \frac{\epsilon }{F(x_0)-F^*} + \log \left( \frac{1}{\rho }\right) \right) , \end{aligned}$$(74)
- (ii)\(\epsilon < \min \{2\left( \tfrac{\beta }{\alpha }\right) \mathcal R^2_{w}(x_0,x^*), F(x_0)-F^*\}\) and$$\begin{aligned} K \ge \frac{2 \left( \tfrac{\beta }{\alpha }\right) \mathcal R^2_{w}(x_0,x^*)}{\epsilon } \log \left( \frac{F(x_0)-F^*}{\epsilon \rho }\right) . \end{aligned}$$(75)
Proof
The speedup of the serial sampling (i.e., of the algorithm based on it) is 1 as we are comparing it to itself. On the other end of the spectrum is the fully parallel sampling with a speedup of \(\tfrac{n}{\omega }\). If the degree of partial separability is small, then this factor will be high — especially so if \(n\) is huge, which is the domain we are interested in. This provides an affirmative answer to the research question stated in italics in the introduction.
7.2 Iteration complexity: strongly convex case
In this section we assume that \(F\) is strongly convex with respect to the norm \(\Vert \cdot \Vert _w\) and show that \(F(x_k)\) converges to \(F^*\) linearly, with high probability.
Theorem 18
Proof
- 1.
\(\mu _f(w) = 0\). Then the leading term in (78) is \(\tfrac{1+\beta /\mu _\Omega (w)}{\alpha }\).
- 2.
\(\mu _\Omega (w) = 0\). Then the leading term in (78) is \(\tfrac{\beta /\mu _f(w)}{\alpha }\).
- 3.
\(\mu _\Omega (w)\) is “large enough”. Then \(\tfrac{\beta +\mu _{\Omega }(w)}{\mu _f(w)+\mu _{\Omega }(w)} \approx 1\) and the leading term in (78) is \(\tfrac{1}{\alpha }\).
8 Numerical experiments
In Sect. 8.1 we present preliminary but very encouraging results showing that PCDM1 run on a system with 24 cores can solve huge-scale partially-separable LASSO problems with a billion variables in 2 h, compared with 41 h on a single core. In Sect. 8.2 we demonstrate that our analysis is in some sense tight. In particular, we show that the speedup predicted by the theory can be matched almost exactly by actual wall time speedup for a particular problem.
8.1 A LASSO problem with 1 billion variables
We solved the problem using PCDM1 with \(\tau \)-nice sampling \(\hat{S}\), \(\beta = 1+ \tfrac{(\omega -1)(\tau -1)}{n-1}\) and \(w=L=(\Vert a_1\Vert ^2_2,\ldots ,\Vert a_n\Vert _2^2)\), for \(\tau =1,2,4,8,16, 24\), on a single large-memory computer utilizing \(\tau \) of its 24 cores. The problem description took around 350GB of memory space. In fact, in our implementation we departed from the just described setup in two ways. First, we implemented an asynchronous version of the method; i.e., one in which cores do not wait for others to update the current iterate within an iteration before reading \(x_{k+1}\) and proceeding to another update step. Instead, each core reads the current iterate whenever it is ready with the previous update step and applies the new update as soon as it is computed. Second, as mentioned in Sect. 4, the \(\tau \)-independent sampling is for \(\tau \ll n\) a very good approximation of the \(\tau \)-nice sampling. We therefore allowed each processor to pick a block uniformly at random, independently from the other processors.
Choice of the first column of Table 6 In Table 6 we show the development of the gap \(F(x_k)-F^*\) as well as the elapsed time. The choice and meaning of the first column of the table, \(\tfrac{\tau k}{n}\), needs some commentary. Note that exactly \(\tau k\) coordinate updates are performed after \(k\) iterations. Hence, the first column denotes the total number of coordinate updates normalized by the number of coordinates \(n\). As an example, let \(\tau _1=1\) and \(\tau _2=24\). Then if the serial method is run for \(k_1=24\) iterations and the parallel one for \(k_2=1\) iteration, both methods would have updated the same number (\(\tau _1 k_1 = \tau _2 k_2 = 24\)) of coordinates; that is, they would “be” in the same row of Table 6. In summary, each row of the table represents, in the sense described above, the “same amount of work done” for each choice of \(\tau \). We have highlighted in bold elapsed time after 13 and 26 passes over data for \(\tau = 1, 2, 4, 8, 16.\) Note that for any fixed \(\tau \), the elapsed time has approximately doubled, as one would expect. More importantly, note that we can clearly observe close to linear speedup in the number of processors \(\tau \).
8.1.1 Progress to solving the problem
A LASSO problem with \(10^9\) variables solved by PCDM1 with \(\tau =\) 1, 2, 4, 8, 16 and 24
\(\tfrac{\tau k}{n}\) | \(F(x_k)-F^*\) | Elapsed time | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
\(\tau =1\) | \(\tau = 2\) | \(\tau = 4\) | \(\tau = 8\) | \(\tau = 16\) | \(\tau = 24\) | \(\tau = 1\) | \(\tau = 2\) | \(\tau = 4\) | \(\tau = 8\) | \(\tau = 16\) | \(\tau = 24\) | |
0 | 6.27e+22 | 6.27e+22 | 6.27e+22 | 6.27e+22 | 6.27e+22 | 6.27e+22 | 0.00 | 0.00 | 0.00 | 0.00 | 0.00 | 0.00 |
1 | 2.24e+22 | 2.24e+22 | 2.24e+22 | 2.24e+22 | 2.24e+22 | 2.24e+22 | 0.89 | 0.43 | 0.22 | 0.11 | 0.06 | 0.05 |
2 | 2.24e+22 | 2.24e+22 | 2.24e+22 | 3.64e+19 | 2.24e+22 | 8.13e+18 | 1.97 | 1.06 | 0.52 | 0.27 | 0.14 | 0.10 |
3 | 1.15e+20 | 2.72e+19 | 8.37e+19 | 1.94e+19 | 1.37e+20 | 5.74e+18 | 3.20 | 1.68 | 0.82 | 0.43 | 0.21 | 0.16 |
4 | 5.25e+19 | 1.45e+19 | 2.22e+19 | 1.42e+18 | 8.19e+19 | 5.06e+18 | 4.28 | 2.28 | 1.13 | 0.58 | 0.29 | 0.22 |
5 | 1.59e+19 | 2.26e+18 | 1.13e+19 | 1.05e+17 | 3.37e+19 | 3.14e+18 | 5.37 | 2.91 | 1.44 | 0.73 | 0.37 | 0.28 |
6 | 1.97e+18 | 4.33e+16 | 1.11e+19 | 1.17e+16 | 1.33e+19 | 3.06e+18 | 6.64 | 3.53 | 1.75 | 0.89 | 0.45 | 0.34 |
7 | 2.40e+16 | 2.94e+16 | 7.81e+18 | 3.18e+15 | 8.39e+17 | 3.05e+18 | 7.87 | 4.15 | 2.06 | 1.04 | 0.53 | 0.39 |
8 | 5.13e+15 | 8.18e+15 | 6.06e+18 | 2.19e+14 | 5.81e+16 | 9.22e+15 | 9.15 | 4.78 | 2.37 | 1.20 | 0.61 | 0.45 |
9 | 8.90e+14 | 7.87e+15 | 2.09e+16 | 2.08e+13 | 2.24e+16 | 5.63e+15 | 10.43 | 5.39 | 2.67 | 1.35 | 0.69 | 0.51 |
10 | 5.81e+14 | 6.52e+14 | 7.75e+15 | 3.42e+12 | 2.89e+15 | 2.20e+13 | 11.73 | 6.02 | 2.98 | 1.51 | 0.77 | 0.57 |
11 | 5.13e+14 | 1.97e+13 | 2.55e+15 | 1.54e+12 | 2.55e+15 | 7.30e+12 | 12.81 | 6.64 | 3.29 | 1.66 | 0.84 | 0.63 |
12 | 5.04e+14 | 1.32e+13 | 1.84e+13 | 2.18e+11 | 2.12e+14 | 1.44e+12 | 14.08 | 7.26 | 3.60 | 1.83 | 0.92 | 0.68 |
13 | 2.18e+12 | 7.06e+11 | 6.31e+12 | 1.33e+10 | 1.98e+14 | 6.37e+11 | 15.35 | 7.88 | 3.91 | 1.99 | 1.00 | 0.74 |
14 | 7.77e+11 | 7.74e+10 | 3.10e+12 | 3.43e+09 | 1.89e+12 | 1.20e+10 | 16.65 | 8.50 | 4.21 | 2.14 | 1.08 | 0.80 |
15 | 1.80e+10 | 6.23e+10 | 1.63e+11 | 1.60e+09 | 5.29e+11 | 4.34e+09 | 17.94 | 9.12 | 4.52 | 2.30 | 1.16 | 0.86 |
16 | 1.38e+09 | 2.27e+09 | 7.86e+09 | 1.15e+09 | 1.46e+11 | 1.38e+09 | 19.23 | 9.74 | 4.83 | 2.45 | 1.24 | 0.91 |
17 | 3.63e+08 | 3.99e+08 | 3.07e+09 | 6.47e+08 | 2.92e+09 | 7.06e+08 | 20.49 | 10.36 | 5.14 | 2.61 | 1.32 | 0.97 |
18 | 2.10e+08 | 1.39e+08 | 2.76e+08 | 1.88e+08 | 1.17e+09 | 5.93e+08 | 21.76 | 10.98 | 5.44 | 2.76 | 1.39 | 1.03 |
19 | 3.81e+07 | 1.92e+07 | 7.47e+07 | 1.55e+06 | 6.51e+08 | 5.38e+08 | 23.06 | 11.60 | 5.75 | 2.91 | 1.47 | 1.09 |
20 | 1.27e+07 | 1.59e+07 | 2.93e+07 | 6.78e+05 | 5.49e+07 | 8.44e+06 | 24.34 | 12.22 | 6.06 | 3.07 | 1.55 | 1.15 |
21 | 4.69e+05 | 2.65e+05 | 8.87e+05 | 1.26e+05 | 3.84e+07 | 6.32e+06 | 25.42 | 12.84 | 6.36 | 3.22 | 1.63 | 1.21 |
22 | 1.47e+05 | 1.16e+05 | 1.83e+05 | 2.62e+04 | 3.09e+06 | 1.41e+05 | 26.64 | 13.46 | 6.67 | 3.38 | 1.71 | 1.26 |
23 | 5.98e+04 | 7.24e+03 | 7.94e+04 | 1.95e+04 | 5.19e+05 | 6.09e+04 | 27.92 | 14.08 | 6.98 | 3.53 | 1.79 | 1.32 |
24 | 3.34e+04 | 3.26e+03 | 5.61e+04 | 1.75e+04 | 3.03e+04 | 5.52e+04 | 29.21 | 14.70 | 7.28 | 3.68 | 1.86 | 1.38 |
25 | 3.19e+04 | 2.54e+03 | 2.17e+03 | 5.00e+03 | 6.43e+03 | 4.94e+04 | 30.43 | 15.32 | 7.58 | 3.84 | 1.94 | 1.44 |
26 | 3.49e+02 | 9.62e+01 | 1.57e+03 | 4.11e+01 | 3.68e+03 | 4.91e+04 | 31.71 | 15.94 | 7.89 | 3.99 | 2.02 | 1.49 |
27 | 1.92e+02 | 8.38e+01 | 6.23e+01 | 5.70e+00 | 7.77e+02 | 4.90e+04 | 33.00 | 16.56 | 8.20 | 4.14 | 2.10 | 1.55 |
28 | 1.07e+02 | 2.37e+01 | 2.38e+01 | 2.14e+00 | 6.69e+02 | 4.89e+04 | 34.23 | 17.18 | 8.49 | 4.30 | 2.17 | 1.61 |
29 | 6.18e+00 | 1.35e+00 | 1.52e+01 | 2.35e\(-\)01 | 3.64e+01 | 4.89e+04 | 35.31 | 17.80 | 8.79 | 4.45 | 2.25 | 1.67 |
30 | 4.31e+00 | 3.93e\(-\)01 | 6.25e\(-\)01 | 4.03e\(-\)02 | 2.74e+00 | 3.15e+01 | 36.60 | 18.43 | 9.09 | 4.60 | 2.33 | 1.73 |
31 | 6.17e\(-\)01 | 3.19e\(-\)01 | 1.24e\(-\)01 | 3.50e\(-\)02 | 6.20e\(-\)01 | 9.29e+00 | 37.90 | 19.05 | 9.39 | 4.75 | 2.41 | 1.78 |
32 | 1.83e\(-\)02 | 3.06e\(-\)01 | 3.25e\(-\)02 | 2.41e\(-\)03 | 2.34e\(-\)01 | 3.10e\(-\)01 | 39.17 | 19.67 | 9.69 | 4.91 | 2.48 | 1.84 |
33 | 3.80e\(-\)03 | 1.75e\(-\)03 | 1.55e\(-\)02 | 1.63e\(-\)03 | 1.57e\(-\)02 | 2.06e\(-\)02 | 40.39 | 20.27 | 9.99 | 5.06 | 2.56 | 1.90 |
34 | 7.28e-14 | 7.28e-14 | 1.52e\(-\)02 | 7.46e-14 | 1.20e\(-\)02 | 1.58e\(-\)02 | 41.47 | 20.89 | 10.28 | 5.21 | 2.64 | 1.96 |
35 | – | – | 1.24e\(-\)02 | – | 1.23e\(-\)03 | 8.70e-14 | – | – | 10.58 | – | 2.72 | 2.02 |
36 | – | – | 2.70e\(-\)03 | – | 3.99e\(-\)04 | – | – | – | 10.88 | – | 2.80 | – |
37 | – | – | 7.28e\(-\)14 | – | 7.46e\(-\)14 | – | – | – | 11.19 | - | 2.87 | - |
The progress to solving the problem during the final 1 billion coordinate updates (i.e., when moving from the last-but-one to the last nonempty line in each of the columns of Table 6 showing \(F(x_k)-F^*\) ) is remarkable. The method managed to push the optimality gap by 9-12 degrees of magnitude. We do not have an explanation for this phenomenon; we do not give local convergence estimates in this paper. It is certainly the case though that once the method managed to find the nonzero places of \(x^*\), fast local convergence comes in.
8.1.2 Parallelization speedup
Since a parallel method utilizing \(\tau \) cores manages to do the same number of coordinate updates as the serial one \(\tau \) times faster, a direct consequence of the above observation is that doubling the number of cores corresponds to roughly halving the number of iterations (see Fig. 3b. This is due to the fact that \(\omega \ll n\) and \(\tau \ll n\). It turns out that the number of iterations is an excellent predictor of wall time; this can be seen by comparing Fig. 3b, c. Finally, it follows from the above, and can be seen in Fig. 3d, that the speedup of PCDM1 utilizing \(\tau \) cores is roughly equal to \(\tau \). Note that this is caused by the fact that the problem is, relative to its dimension, partially separable to a very high degree.
8.2 Theory versus reality
We generated 4 matrices with \(\omega =5, 10, 50\) and \( 100\) and measured the number of iterations needed for PCDM1 used with \(\tau \)-nice sampling to get within \(\epsilon = 10^{-6}\) of the optimal value. The experiment was done for a range of values of \(\tau \) (between 1 core and 1000 cores).
8.3 Training linear SVMs with bad data for PCDM
We consider the rcv1.binary dataset.^{12} The training data has \(n = 677,399\) examples, \(d= 47,236\) features, \(49,556,258\) nonzero elements and requires cca 1GB of RAM for storage. Hence, this is a small-scale problem. The degree of partial separability of \(f\) is \(\omega = 291,516\) (i.e., the maximum number of examples sharing a given feature). This is a very large number relative to \(n\), and hence our theory would predict rather bad behavior for PCDM. We use PCDM1 with \(\tau \)-nice sampling ( approximating it by \(\tau \)-independent sampling for added efficiency) with \(\beta \) following Theorem 12: \(\beta =1+ \frac{(\tau -1)(\omega -1)}{n-1}\).
The results of our experiments are summarized in Fig. 5. Each column corresponds to a different level of regularization: \(\lambda \in \{1,10^{-3},10^{-5}\}\). The rows show the (1) duality gap, (2) dual suboptimality, (3) train error and (4) test error; each for 1,4 and 16 processors (\(\tau = 1,4,16\)). Observe that the plots in the first two rows are nearly identical; which means that the method is able to solve the primal problem at about the same speed as it can solve the dual problem.^{13}
Observe also that in all cases, duality gap of around \(0.01\) is sufficient for training as training error (classification performance of the SVM on the train data) does not decrease further after this point. Also observe the effect of \(\lambda \) on training accuracy: accuracy increases from about \(92\,\%\) for \(\lambda =1\), through \(95.3\,\%\) for \(\lambda =10^{-3}\) to above \(97.8\,\%\) with \(\lambda =10^{-5}\). In our case, choosing smaller \(\lambda \) does not lead to overfitting; the test error on test dataset (# features =677,399, # examples = 20,242) increases as \(\lambda \) decreases, quickly reaching about \(95\,\%\) (after 2 seconds of training) for \(\lambda =0.001\) and for the smallest \(\lambda \) going beyond \(97\,\%\).
8.4 \(L2\)-regularized logistic regression with good data for PCDM
PCDM accelerates linearly in \(\tau \) on a good dataset
Epoch | \(F(x_0)/F(x_k)\) | Time | ||||||
---|---|---|---|---|---|---|---|---|
\(\tau =1\) | \(\tau =2\) | \(\tau =4\) | \(\tau =8\) | \(\tau =1\) | \(\tau =2\) | \(\tau =4\) | \(\tau =8\) | |
1 | 3.96490 | 3.93909 | 3.94578 | 3.99407 | 17.83 | 9.57 | 5.20 | 2.78 |
2 | 5.73498 | 5.72452 | 5.74053 | 5.74427 | 73.00 | 39.77 | 21.11 | 11.54 |
3 | 6.12115 | 6.11850 | 6.12106 | 6.12488 | 127.35 | 70.13 | 37.03 | 20.29 |
Let us remark that the training and testing accuracy stopped increasing after having trained the classifier for 1 epoch; they were \(86.07\) and \(88.77\,\%\), respectively. This is in agreement with the common wisdom in machine learning that training beyond a single pass through the data rarely improves testing accuracy (as it may lead to overfitting). This is also the reason behind the success of light-touch methods, such as coordinate descent and stochastic gradient descent, in machine learning applications.
Some elements of the setup described in this section was initially used in the analysis of block coordinate descent methods by Nesterov [10] (e.g., block structure, weighted norms and block Lipschitz constants).
The reason why we work with a permutation of the identity matrix, rather than with the identity itself, as in [10], is to enable the blocks being formed by nonconsecutive coordinates of \(x\). This way we establish notation which makes it possible to work with (i.e., analyze the properties of) multiple block decompositions, for the sake of picking the best one, subject to some criteria. Moreover, in some applications the coordinates of \(x\) have a natural ordering to which the natural or efficient block structure does not correspond.
This is a straightforeard result; we do not claim any novelty and include it solely for the benefit of the reader.
For examples of separable and block separable functions we refer the reader to [15]. For instance, \(\Omega (x)=\Vert x\Vert _1\) is separable and block separable (used in sparse optimization); and \(\Omega (x)=\sum _i \Vert x^{(i)}\Vert \), where the norms are standard Euclidean norms, is block separable (used in group lasso). One can model block constraints by setting \(\Omega _i(x^{(i)}) = 0\) for \(x \in X_i\), where \(X_i\) is some closed convex set, and \(\Omega _i(x^{(i)})=+\infty \) for \(x \notin X_i\).
A similar map was used in [10] (with \(\Omega \equiv 0\) and \(\beta =1\)) and [15] (with \(\beta =1\)) in the analysis of serial coordinate descent methods in the smooth and composite case, respectively. In loose terms, the novelty here is the introduction of the parameter \(\beta \) and in developing theory which describes what value \(\beta \) should have. Maps of this type are known as composite gradient mapping in the literature, and were introduced in [11].
All the methods are in their proximal variants due to the inclusion of the term \(\Omega \) in the objective.
Revision note requested by a reviewer: In the time since this paper was posted to arXiv, a number of follow-up papers were written analyzing parallel coordinate descent methods and establishing connections between a discrete quantity analogous to \(\omega \) (degree of partial/Nesterov separability) and a spectral quantity analogous to \(\sigma \) (largest eigenvalue of a certain matrix), most notably [3, 17]. See also [25], which uses a spectral quantity, which can be directly compared to \(\omega \).
Copyright information
Open AccessThis article is distributed under the terms of the Creative Commons Attribution License which permits any use, distribution, and reproduction in any medium, provided the original author(s) and the source are credited.