Communication-Optimal Distributed Clustering

Jiecao Chen, He Sun, David P. Woodruff, Qin Zhang

Introduction

Both the spectral clustering and the geometric clustering algorithms mentioned above have been widely used in practice, and have been the subject of extensive theoretical and experimental studies over the decades. However, these algorithms are designed for the centralized setting, and are not applicable in the setting of large-scale datasets that are maintained remotely by different sites. In particular, collecting the information from all the remote sites and performing a centralized clustering algorithm is infeasible due to high communication costs, and new distributed clustering algorithms with low communication cost need to be developed.

There are several natural communication models, and we focus on two of them: (1) a point-to-point model, and (2) a model with a broadcast channel. In the former, sometimes referred to as the message-passing model, there is a communication channel between each pair of users. This may be impractical, and the so-called coordinator model can often be used in place; in the coordinator model there is a centralized site called the coordinator, and all communication goes through the coordinator. This affects the total communication by a factor of two, since the coordinator can forward a message from one server to another and therefore simulate a point-to-point protocol. There is also an additional additive O(log⁡s)O(\log s) bits per message, where ss is the number of sites, since a server must specify to the coordinator where to forward its message. In the model with a broadcast channel, sometimes referred to as the blackboard model, the coordinator has the power to send a single message which is received by all ss sites at once. This can be viewed as a model for single-hop wireless networks.

In both models we study the total number of bits communicated among all sites. Although the blackboard model is at least as powerful as the message-passing model, it is often unclear how to exploit its power to obtain better bounds for specific problems. Also, for a number of problems the communication complexity is the same in both models, such as computing the sum of ss length-nn bit vectors modulo two, where each site holds one bit vector , or estimating large moments . Still, for other problems like set disjointness it can save a factor of ss in the communication .

We present algorithms for graph clustering: for any nn-vertex graph whose edges are arbitrarily partitioned across ss sites, our algorithms have communication cost O~(ns)\widetilde{O}(ns) in the message passing model, and have communication cost O~(n+s)\widetilde{O}(n+s) in the blackboard model, where the O~\widetilde{O} notation suppresses polylogarithmic factors. The algorithm in the message passing model has each site send a spectral sparsifier of its local data to the coordinator, who then merges them in order to obtain a spectral sparsifier of the union of the datasets, which is sufficient for solving the graph clustering problem. Our algorithm in the blackboard model is technically more involved, as we show a particular recursive sampling procedure for building a spectral sparsifier can be efficiently implemented using a broadcast channel. It is unclear if other natural ways of building spectral sparsifiers can be implemented with low communication in the blackboard model. Our algorithms demonstrate the surprising power of the blackboard model for clustering problems. Since our algorithms compute spectral sparsifiers, they also have applications to solving symmetric diagonally dominant linear systems in a distributed model. Any such system can be converted into a system involving a Laplacian (see, e.g., ), from which a spectral sparsifier serves as a good preconditioner.

Next we show that Ω(ns)\Omega(ns) bits of communication is necessary in the message passing model to even recover a constant fraction of a cluster, and Ω(n+s)\Omega(n+s) bits of communication is necessary in the blackboard model. This shows the optimality of our algorithms up to poly-logarithmic factors.

We then study clustering problems in constant-dimensional Euclidean space. We show for any c>1c>1, computing a cc-approximation for kk-median, kk-means, or kk-center correctly with constant probability in the message passing model requires Ω(sk)\Omega(sk) bits of communication. We then strengthen this lower bound, and show even for bicriteria clustering algorithms, which may output a constant factor more clusters and a constant factor approximation, our Ω(sk)\Omega(sk) bit lower bound still holds. Our proofs are based on communication and information complexity. Our results imply that existing algorithms for kk-median and kk-means with O~(sk)\widetilde{O}(sk) bits of communication, as well as the folklore parallel guessing algorithm for kk-center with O~(sk)\widetilde{O}(sk) bits of communication, are optimal up to poly-logarithmic factors. For the blackboard model, we present an algorithm for kk-median and kk-means that achieves an O(1)O(1)-approximation using O~(s+k)\widetilde{O}(s+k) bits of communication. This again separates the models.

We give empirical results which show that using spectral sparsifiers preserves the quality of spectral clustering surprisingly well in real-world datasets. For example, when we partition a graph with over 7070 million edges (the Sculpture dataset) into 3030 sites, only 6%6\% of the input edges are communicated in the blackboard model and 8%8\% are communicated in the message passing model, while the values of the normalized cut (the objective function of spectral clustering) given in those two models are at most 2%2\% larger than the ones given by the centralized algorithm, and the visualized results are almost identical. This is strong evidence that spectral sparsifiers can be a powerful tool in practical, distributed computation. When the number of sites is large, the blackboard model incurs significantly less communication than the message passing model, e.g., in the Twomoons dataset when there are 9090 sites, the message passing model communicates 99 times as many edges as communicated in the blackboard model, illustrating the strong separation between these models that our theory predicts.

2 Related work

There is a rich literature on spectral and geometric clustering algorithms from various aspects (see, e.g., ). Balcan et al. and Feldman et al. study distributed kk-means ( also studies kk-median), and present provable guarantees on the clustering quality. Very recently Guha et al. studied distributed kk-median/center/means with outliers. Cohen et al. study dimensionality reduction techniques for the input data matrices that can be used for distributed kk-means. The main takeaway is that there is no previous work which develops protocols for spectral clustering in the common message passing and blackboard models, and lower bounds are lacking as well. For geometric clustering, while upper bounds exist (e.g., ), no provable lower bounds in either model existed, and our main contribution is to show that previous algorithms are optimal. We also develop a new protocol in the blackboard model.

Preliminaries

For two sets XX and YY, the symmetric difference of XX and YY is defined as X△Y≜(X∖Y)∪(Y∖X)X\triangle Y\triangleq(X\setminus Y)\cup(Y\setminus X).

2 Spectral sparsification

For any undirected and weighted graph G=(V,E,w)G=(V,E,w), we say a subgraph HH of GG with proper reweighting of the edges is a (1+ε)(1+\varepsilon)-spectral sparsifier if

The following lemma shows that a spectral sparsifier preserves the clustering structure of a graph.

Let HH be a (1+ε)(1+\varepsilon)-spectral sparsifier of GG for some ε≤1/3\varepsilon\leq 1/3. Then, it holds for any set S⊆VS\subseteq V that ϕH(S)∈(12,2)ϕG(S)\phi_{H}(S)\in\left(\frac{1}{2},2\right)\phi_{G}(S).

which implies that (1−ε)⋅μG(S)≤μH(S)≤(1+ε)⋅μG(S)(1-\varepsilon)\cdot\mu_{G}(S)\leq\mu_{H}(S)\leq(1+\varepsilon)\cdot\mu_{G}(S) for any subset SS.

where the last inequality holds by assuming ε≤1/3\varepsilon\leq 1/3. Similarly, we have that

Hence, ϕH(S)\phi_{H}(S) and ϕG(S)\phi_{G}(S) differ by at most a factor of 2 for any vertex set SS. ∎

3 Models of computation

We study distributed clustering in two models for distributed data: the message passing model and the blackboard model. The message passing model represents those distributed computation systems with point-to-point communication, and the blackboard model represents those where messages can be broadcast to all parties.

More precisely, in the message passing model there are ss sites P1,…,Ps\mathcal{P}_{1},\ldots,\mathcal{P}_{s}, and one coordinator. These sites can talk to the coordinator through a two-way private channel. In fact, this is referred to as the coordinator model in Section 1, where it is shown to be equivalent to the point-to-point model up to small factors. The input is initially distributed at the ss sites. The computation is in terms of rounds: at the beginning of each round, the coordinator sends a message to some of the ss sites, and then each of those sites that have been contacted by the coordinator sends a message back to the coordinator. At the end, the coordinator outputs the answer. In the alternative blackboard model, the coordinator is simply a blackboard where these ss sites P1,…,Ps\mathcal{P}_{1},\ldots,\mathcal{P}_{s} can share information; in other words, if one site sends a message to the coordinator/blackboard then all the other s−1s-1 sites can see this information without further communication. The order for the sites to speak is decided by the contents of the blackboard.

For both models we measure the communication cost as the total number of bits sent through the channels. The two models are now standard in multiparty communication complexity (see, e.g., ). They are similar to the congested clique model studied in the distributed computing community; the main difference is that in our models we do not post any bandwidth limitations at each channel but instead consider the total number of bits communicated.

4 Communication complexity

For any problem A\mathcal{A} and any protocol Π\Pi solving A\mathcal{A}, the communication complexity of a protocol Π\Pi is the maximum communication cost of Π\Pi over all possible inputs XX. When the protocol is randomised, we define the error of Π\Pi by

where the max⁡\max is over all inputs XX and the probability is over all random strings of the coordinator and ss sites. The δ\delta-error randomised communication complexity Rδ(A)\mathsf{R}_{\delta}(\mathcal{A}) of a problem A\mathcal{A} in the message passing model is the minimum communication complexity of any randomised protocol Π\Pi that solves A\mathcal{A} with error at most δ\delta.

Let μ\mu be an input distribution on XX. We call a deterministic protocol (δ,μ)-error(\delta,\mu)\text{-error} if it gives the correct answer for A\mathcal{A} on at least a 1−δ1-\delta fraction of all input pairs, weighted by the distribution μ\mu. We denote Dδ,μ(A)\mathsf{D}_{\delta,\mu}(\mathcal{A}) as the cost of the minimum-communication (δ,μ)-error(\delta,\mu)\text{-error} protocol. A standard lemma in communication complexity called Yao’s minimax lemma shows that Rδ(A)≥max⁡μDδ,μ(A).\mathsf{R}_{\delta}(\mathcal{A})\geq\max_{\mu}\mathsf{D}_{\delta,\mu}(\mathcal{A}).

5 Information complexity

We abuse notation by using Π\Pi for both the protocol and its transcript (its concatenation of messages). In the message passing model, let Πi (i∈[s])\Pi_{i}\ (i\in[s]) be the transcript (set of messages exchanged) between the ii-th site and the coordinator. Then Π\Pi can be seen as a concatenation Π1∘Π2∘…∘Πs\Pi_{1}\circ\Pi_{2}\circ\ldots\circ\Pi_{s} ordered by the timestamps of the messages. We define the information complexity of a problem A\mathcal{A} in the message passing model by

where I(⋅ ; ⋅)I(\cdot\ ;\ \cdot) is the mutual information function. It has been shown in that Rδ(A)≥ICδ,μ(A)\mathsf{R}_{\delta}(\mathcal{A})\geq\mathsf{IC}_{\delta,\mu}(\mathcal{A}) for any input distribution μ\mu.

Distributed graph clustering

In this section we study distributed graph clustering. We assume that the vertex set of the input graph G=(V,E)G=(V,E) can be partitioned into kk clusters, where vertices in each cluster SS are highly connected to each other, and there are fewer edges between SS and V∖SV\setminus S. To formalize this notion, we define the kk-way expansion constant of graph GG by

Notice that a graph GG has kk clusters if the value of ρ(k)\rho(k) is small. It was shown in that ρ(k)\rho(k) closely relates to λk(LG)\lambda_{k}(\mathcal{L}_{G}) by the following higher-order Cheeger inequality:

Hence, a large gap between λk+1(LG)\lambda_{k+1}(\mathcal{L}_{G}) and ρ(k)\rho(k) implies (i) the existence of a kk-way partition {Si}i=1k\{S_{i}\}_{i=1}^{k} such that every SiS_{i} has small conductance ϕG(Si)≤ρ(k)\phi_{G}(S_{i})\leq\rho(k), and (ii) any (k+1)(k+1)-way partition of GG contains a subset with high conductance ρ(k+1)≥λk+1(LG)/2\rho(k+1)\geq\lambda_{k+1}(\mathcal{L}_{G})/2. Therefore, a large gap between λk+1(LG)\lambda_{k+1}(\mathcal{L}_{G}) and ρ(k)\rho(k) ensures that GG has exactly kk clusters. In the following, we assume that

to ensure that the input graph GG has exactly kk clusters. The same assumption has been used in the literature for studying graph clustering in the centralized setting .

(iii) run kk-means on the embedded points {F(v)}v∈V\{F(v)\}_{v\in V}, and group the vertices of GG into kk clusters according to the output of kk-means.

We assume the edges of the input graph G=(V,E)G=(V,E) are arbitrarily allocated among ss sites P1,⋯ ,Ps\mathcal{P}_{1},\cdots,\mathcal{P}_{s}, and we use EiE_{i} to denote the edge set maintained by site Pi\mathcal{P}_{i}. Our proposed algorithm consists of two steps: (i) every Pi\mathcal{P}_{i} computes a linear-sized (1+ε)(1+\varepsilon)-spectral sparsifier HiH_{i} of Gi≜(V,Ei)G_{i}\triangleq(V,E_{i}), for a small constant ε≤1/10\varepsilon\leq 1/10, and sends the edge set of HiH_{i}, denoted by Ei′E_{i}^{\prime}, to the coordinator; (ii) the coordinator runs a spectral clustering algorithm on the union of received graphs H≜(V,⋃i=1kEi′)H\triangleq\left(V,\bigcup_{i=1}^{k}E_{i}^{\prime}\right). The theorem below summarizes the performance of this algorithm, and shows the approximation guarantee of this algorithm is as good as the provable guarantee of spectral clustering known in the centralized setting, which is shown in the lemma below.

Let G=(V,E)G=(V,E) be an nn-vertex graph with Υ=Ω(k3)\Upsilon=\Omega(k^{3}), and suppose the edges of GG are arbitrarily allocated among ss sites. Assume S1,⋯ ,SkS_{1},\cdots,S_{k} is an optimal partition that achieves ρ(k)\rho(k). Then, the algorithm above computes a partition A1,…,AkA_{1},\ldots,A_{k} satisfying μ(Ai△Si)=O(k3⋅Υ−1⋅μ(Si))\mu(A_{i}\triangle S_{i})=O\left(k^{3}\cdot\Upsilon^{-1}\cdot\mu(S_{i})\right) for any 1≤i≤k1\leq i\leq k. The total communication cost of this algorithm is O~(ns)\widetilde{O}(ns) bits.

By the definition of the Laplacian matrix, we have that LG=∑i=1sLGiL_{G}=\sum_{i=1}^{s}L_{G_{i}}. Since every HiH_{i} is a (1+ε)(1+\varepsilon)-spectral sparsifier of graph GiG_{i}, we have that (1−ε)LHi⪯LGi⪯(1+ε)LHi(1-\varepsilon)L_{H_{i}}\preceq L_{G_{i}}\preceq(1+\varepsilon)L_{H_{i}}. This implies that (1−ε)LH⪯LG⪯(1+ε)LH(1-\varepsilon)L_{H}\preceq L_{G}\preceq(1+\varepsilon)L_{H}, by the definition of HiH_{i} and graph Laplacians. Now we show that our assumption on Υ\Upsilon is preserved in HH. By Lemma 2.1, we have for any 1≤i≤k1\leq i\leq k that ϕH(Si)∈(12,2)ϕG(Si)\phi_{H}(S_{i})\in\left(\frac{1}{2},2\right)\phi_{G}(S_{i}), which implies that SiS_{i} has low conductance in HH, and ρH(k)∈(12,2)ρG(k)\rho_{H}(k)\in\left(\frac{1}{2},2\right)\rho_{G}(k). To show that λk(LH)\lambda_{k}(\mathcal{L}_{H}) is a constant approximation of λk(LG)\lambda_{k}(\mathcal{L}_{G}), notice that

Since DG−1/2LGDG−1/2=LGD_{G}^{-1/2}L_{G}D_{G}^{-1/2}=\mathcal{L}_{G} and 12DG−1⪯DH−1⪯2DG−1\frac{1}{2}D_{G}^{-1}\preceq D_{H}^{-1}\preceq 2D_{G}^{-1}, we have that λi(LH)=Θ(λi(LG))\lambda_{i}\left(\mathcal{L}_{H}\right)=\Theta\left(\lambda_{i}\left(\mathcal{L}_{G}\right)\right), and the assumption on Υ\Upsilon in HH is preserved from GG up to a constant factor. By Lemma 3.1, the output of a spectral clustering algorithm on HH satisfies the claimed properties. The total communication cost of O~(ns)\widetilde{O}(ns) bits follows from the fact that every HiH_{i} has O(n)O(n) edges. ∎

Next we show that the communication cost of our proposed algorithm is optimal up to a logarithmic factor. Our analysis is based on a reduction from graph clustering to the Multiparty Set-Disjointness problem (DISJs,n\mathsf{DISJ}_{s,n}): for any ss sites P1,…,Ps\mathcal{P}_{1},\ldots,\mathcal{P}_{s}, where each Pi\mathcal{P}_{i} has a set Si⊆[n]S_{i}\subseteq[n], let Xi=(Xi1,…,Xin)X_{i}=(X_{i}^{1},\ldots,X_{i}^{n}) be the characteristic vector of SiS_{i}, and let X=(X1,…,Xs)X=(X_{1},\ldots,X_{s}) be the input matrix with XiX_{i} being the ii-th row. Let Xj=(X1j,…,Xsj)X^{j}=(X_{1}^{j},\ldots,X_{s}^{j}) be the jj-th column of the input matrix XX. We define a function ALLONEs\mathsf{ALLONE}_{s} on an ss-bit vector Y=(Y1,…,Ys)Y=(Y_{1},\ldots,Y_{s}) as \text{{\mathsf{ALLONE}_{s}}}(Y)=\bigwedge_{i\in[s]}Y_{i}, and \text{{\mathsf{DISJ}_{s,n}}}(X)=\bigvee_{j\in[n]}\text{{\mathsf{ALLONE}_{s}}}(X^{j}). Then the DISJs,n\mathsf{DISJ}_{s,n} problem asks the value of \text{{\mathsf{DISJ}_{s,n}}}(X). We introduce two hard input distributions for ALLONEs\mathsf{ALLONE}_{s} and DISJs,n\mathsf{DISJ}_{s,n} respectively.

Hard input distribution ν\nu on Y∈{0,1}sY\in\{0,1\}^{s} for ALLONEs\mathsf{ALLONE}_{s}: with probability 1/21/2, we choose each Yi (i∈[s])Y_{i}\ (i\in[s]) to be or 11 with equal probability; with probability 1/41/4 we choose YY to be an all-11 vector; and with the remaining probability 1/41/4 we choose YY to be a random vector with n−1n-1 coordinates being 11’s and a random coordinate being .

Hard input distribution μn\mu_{n} on X∈{0,1}s×nX\in\{0,1\}^{s\times n} for DISJs,n\mathsf{DISJ}_{s,n}: For each j∈[n]j\in[n], we choose Xj∼νX^{j}\sim\nu.

It holds that \mathsf{IC}_{0.49,\nu}(\text{{\mathsf{ALLONE}_{s}}})=\Omega(s), and \mathsf{IC}_{0.49,\nu}(\text{{\mathsf{DISJ}_{s,n}}})=\Omega(sn).

In the message passing model, any randomized algorithm that computes DISJs,n\mathsf{DISJ}_{s,n} correctly with probability 0.90.9 needs Ω(sn)\Omega(sn) bits of communication.

The lemma follows from Theorem 3.3 and Yao’s minimax lemma. ∎

Let GG be an undirected graph with nn vertices, and suppose the edges of GG are distributed among ss sites. Then, any algorithm that correctly outputs a constant fraction of a cluster in GG requires Ω(ns)\Omega(ns) bits of communication. This holds even if each cluster has constant expansion.

As a remark, it is easy to see that this lower bound also holds for constructing spectral sparsifiers: for any n×nn\times n PSD\mathsf{PSD} matrix AA whose entries are arbitrarily distributed among ss sites, any distributed algorithm that constructs a (1+Θ(1))(1+\Theta(1))-spectral sparsifier of AA requires Ω(ns)\Omega(ns) bits of communication. This follows since such a spectral sparsifier can be used to solve the spectral clustering problem. Spectral sparsification has played an important role in designing fast algorithms from different areas, e.g., machine learning, and numerical linear algebra. Hence our lower bound result for constructing spectral sparsifiers may have applications to studying other distributed learning algorithms.

2 The blackboard model

Next we present a graph clustering algorithm with O~(n+s)\widetilde{O}(n+s) bits of communication cost in the blackboard model. Our result is based on the observation that a spectral sparsifier preserves the structure of clusters, which was used for proving Theorem 3.2. So it suffices to design a distributed algorithm for constructing a spectral sparsifier in the blackboard model.

where γ(i)=λu/2i\gamma(i)=\lambda_{u}/2^{i} and K(i)=K+γ(i)IK(i)=K+\gamma(i)I. Notice that in the chain above every K(i−1)K(i-1) is obtained by adding weights to the diagonal entries of K(i)K(i), and K(i−1)K(i-1) approximates K(i)K(i) as long as the weights added to the diagonal entries are small. We will construct this chain recursively, so that K(0)K(0) has heavy diagonal entries and can be approximated by a diagonal matrix. Moreover, since KK is the Laplacian matrix of a graph GG, it is easy to see that d=O(log⁡n)d=O(\log n) as long as the edge weights of GG are polynomially upper-bounded in nn.

Based on Lemma 3.6, we will construct a chain of matrices

Let GG be an undirected graph on nn vertices, where the edges of GG are allocated among ss sites, and the edge weights are polynomially upper bounded in nn. Then, a spectral sparsifier of GG can be constructed with O~(n+s)\widetilde{O}(n+s) bits of communication in the blackboard model. That is, the chain (3) can be constructed with O~(n+s)\widetilde{O}(n+s) bits of communication in the blackboard model.

First of all, notice that λu≤2n\lambda_{u}\leq 2n, and the value of nn can be obtained with communication cost O~(n+s)\widetilde{O}(n+s) (different sites sequentially write the new IDs of the vertices on the blackboard). In the following we assume that λu\lambda_{u} is the upper bound of λmax⁡\lambda_{\max} that we actually obtained in the blackboard.

Combining Theorem 3.7 and the fact that a spectral sparsifier preserves the structure of clusters, we obtain a distributed algorithm in the blackboard model with total communication cost O~(n+s)\widetilde{O}(n+s) bits, and the performance of our algorithm is the same as in the statement of Theorem 3.2. Notice that Ω(n+s)\Omega(n+s) bits of communication are needed for graph clustering in the blackboard model, since the output of a clustering algorithm contains Ω(n)\Omega(n) bits of information and each site needs to communicate at least one bit. Hence the communication cost of our proposed algorithm is optimal up to a poly-logarithmic factor.

Distributed geometric clustering

We now consider geometric clustering, including kk-median, kk-means and kk-center. Let PP be a set of points of size nn in a metric space with distance function d(⋅,⋅)d(\cdot,\cdot), and let k≤nk\leq n be an integer. In the kk-center problem we want to find a set C (∣C∣=k)C\ (|C|=k) such that max⁡p∈Pd(p,C)\max_{p\in P}d(p,C) is minimized, where d(p,C)=min⁡c∈Cd(p,c)d(p,C)=\min_{c\in C}d(p,c). In kk-median and kk-means we replace the objective function max⁡p∈Pd(p,C)\max_{p\in P}d(p,C) with ∑p∈Pd(p,C)\sum_{p\in P}d(p,C) and ∑p∈P(d(p,C))2\sum_{p\in P}(d(p,C))^{2}, respectively.

As mentioned, for constant dimensional Euclidean space and a constant c>1c>1, there are algorithms that cc-approximate kk-median and kk-means using O~(sk)\widetilde{O}(sk) bits of communication . For kk-center, the folklore parallel guessing algorithms (see, e.g., ) achieve a 2.012.01-approximation using O~(sk)\widetilde{O}(sk) bits of communication.

The following theorem states that the above upper bounds are tight up to logarithmic factors. The proof uses tools from multiparty communication complexity. We in fact can prove a stronger statement that any algorithm that can differentiate whether we have kk points or k+1k+1 points in total in the message passing model needs Ω(sk)\Omega(sk) bits of communication.

For any c>1c>1, computing cc-approximation for kk-median, kk-means or kk-center correctly with probability 0.990.99 in the message passing model needs Ω(sk)\Omega(sk) bits of communication.

A number of works on clustering consider bicriteria solutions (e.g., ). An algorithm is a (c1,c2)(c_{1},c_{2})-approximation (c1,c2>1)(c_{1},c_{2}>1) if the optimal solution costs WW when using kk centers, then the output of the algorithm costs at most c1Wc_{1}W when using at most c2kc_{2}k centers. We can show that for kk-median and kk-means, the Ω(sk)\Omega(sk) lower bound holds even for algorithms with bicriteria approximations.

For any c∈[1,1.01]c\in[1,1.01], computing (7.1−6c,c)(7.1-6c,c)-bicriteria-approximation for kk-median or kk-means correctly with probability 0.990.99 in the message passing model needs Ω(sk)\Omega(sk) bits of communication.

Before proving Theorem 4.2, we first show the following technical lemma.

By a Markov inequality, there must exist Ω(s)\Omega(s) coordinates jj such that the algorithm computes ALLONEs\mathsf{ALLONE}_{s}(Xj) (Xj∼ν)(X^{j})\ (X^{j}\sim\nu) with error probability at most 0.240.24. Call each of these coordinates jj good. Let Π\Pi be the protocol transcript. We have

By Lemma 4.3, we have that for any c∈[1,1.01]c\in[1,1.01], computing (7.1−6c,c)(7.1-6c,c)-bicriteria-approximation for kk-median or kk-means in the message passing model correctly with probability 0.90.9 under distribution X∼μX\sim\mu needs Ω(sk)\Omega(sk) bits of communication. The theorem follows by Yao’s minimax principle. ∎

2 The blackboard model

We can show that there is an algorithm that achieves an O(1)O(1)-approximation using O~(s+k)\widetilde{O}(s+k) bits of communication for kk-median and kk-means. For kk-center, it is straightforward to implement the parallel guessing algorithm in the blackboard model using O~(s+k)\widetilde{O}(s+k) bits of communication.

Our algorithm for kk-median/means is an easy adaptation of the successive sampling algorithm proposed by Mettu and Plaxton in the (centralized) RAM model. We first summarize their algorithm and then describe how to port it to the blackboard model.

Let X1,…XsX_{1},\ldots X_{s} be the point sets at sites P1,…,Pk\mathcal{P}_{1},\ldots,\mathcal{P}_{k} respectively. The successive sampling algorithm proceeds in rounds. At each round jj it does the following:

ss sites jointly sample O(k)O(k) point centers, denoted by YjY_{j};

ss sites grow balls from each of the point centers in YjY_{j} synchronously until a time step when a 0.90.9 fraction of points in ⋃i∈[s]Xi\bigcup_{i\in[s]}X_{i} are covered;

each site Pi\mathcal{P}_{i} updates XjX_{j} by removing those points that are covered by any of the balls centered at points in YjY_{j};

ss sites remove all the points covered by balls centered at points in YjY_{j}, and proceed to the next round j+1j+1.

It is easy to see that the computation will finish in r=O(log⁡n)r=O(\log n) rounds since at each round we remove a constant fraction of points. At the end we compute an O(1)O(1)-approximation of kk-median or kk-means on the O(klog⁡n)O(k\log n) points ⋃j∈[r]Yj\bigcup_{j\in[r]}Y_{j}. In it has been shown that this algorithm gives an O(1)O(1)-approximation to kk-median or kk-means with high probability.

We now describe how to implement this centralized algorithm in the blackboard model. We first consider each round. Step 1 can be done by the distributed sampling algorithm in using O~(k+s)\widetilde{O}(k+s) bits of communication; note that at the end of this step the sampled points in YjY_{j} are written on the blackboard. Step 22 can be done by a binary search for the minimum ball radius tjt_{j} such that ⋃p∈YjBall(p,tj)\bigcup_{p\in Y_{j}}\mathtt{Ball}(p,t_{j}) covers at least a 0.90.9 fraction of points in ⋃i∈[s]Xi\bigcup_{i\in[s]}X_{i}, where Ball(p,tj)\mathtt{Ball}(p,t_{j}) denotes the ball centered at pp with radius tjt_{j}; this binary search can be done using O~(1)\widetilde{O}(1) bits of communication. Step 33 and 44 can be done locally without any communication. After rr rounds, the final clustering step can be done by any of the ss sites since all points in ⋃j∈[r]Yj\bigcup_{j\in[r]}Y_{j} have already been written on the blackboard. Therefore the total communication cost can be bounded by O~(k+s)\widetilde{O}(k+s).

Finally, we would like to mention that Ω(k+s)\Omega(k+s) is an obvious lower bound, and thus our upper bound is tight up to logarithmic factors. To see this, notice that kk is the size of the output, and the coordinator has to communication with each of the ss sites for at least 11 bit.

Experiments

In this section we present experimental results for graph clustering in the message passing and blackboard models. We will compare the following three algorithms. (1) Baseline: each site sends all the data to the coordinator directly; (2) MsgPassing: our algorithm in the message passing model (Section 3.1); (3) Blackboard: our algorithm in the blackboard model (Section 3.2).

Besides giving the visualized results of these algorithms on various datasets, we also measure the qualities of the results via the normalized cut, defined as

which is a standard objective function to be minimized for spectral clustering algorithms.

We implemented the algorithms using multiple languages, including Matlab, Python and C++. Our experiments were conducted on an IBM NeXtScale nx360 M4 server, which is equipped with 2 Intel Xeon E5-2652 v2 8-core processors, 32GB RAM and 250GB local storage.

We test the algorithms in the following real and synthetic datasets, which is visualized in Figure 1.

In the distributed model edges are randomly partitioned across ss sites.

2 Results on clustering quality

We visualize the clustered results for the Twomoons, Gauss and Sculpture in Figure 2. It can be seen that Baseline, MsgPassing and Blackboard give results of very similar qualities. For simplicity, here we only present the visualization for s=15s=15. Similar results were observed when we varied the values of ss.

We also compare the normalized cut (ncut) values of the clustering results of different algorithms. The results are presented in Figure 3. In all datasets, the ncut values of different algorithms are very close. The ncut value of MsgPassing slightly decreases when we increase the value of ss, while the ncut value of Blackboard is independent of ss.

3 Results on communication costs

We compare the communication costs of different algorithms in Figure 4. We observe that while achieving similar clustering qualities as Baseline, both MsgPassing and Blackboard are significantly more communication-efficient (by one or two orders of magnitudes in our experiments). We also notice that the value of ss does not affect the communication cost of Blackboard, while the communication cost of MsgPassing grows almost linearly with ss; when ss is large, MsgPassing uses significantly more communication than Blackboard. These confirm our theory.

4 Parameters in MsgPassing and Blackboard

Figure 5 shows in MsgPassinghow the value of ncut is affected by the number of sites and the number of edges sampled in each site. Here, each site samples cncn edges. When c=3c=3 and s=1s=1, the ncut value diverges in all datasets. This is because with such a small cc, the algorithm does not generate a valid sparsifier. In general, increasing cc or ss will slightly decrease the ncut value. But once they are above some thresholds, the ncut values of MsgPassing and Baseline become very close.

Figure 6 shows in Blackboardhow the ncut value is affected by the number of iterations and the number of edges sampled. When the number of iterations is set to be 55, ncut values diverge in all datasets. This is because we cannot expect to generate a valid sparsifier by using such few iterations. It can be seen from 6(b) that for a fixed cc, performing more iterations will help to reduce ncut values. From the same figure, one can also conclude that for fixed iterations, increasing cc also helps to reduce the ncut values.

References