New Frameworks for Offline and Streaming Coreset Constructions
Vladimir Braverman, Dan Feldman, Harry Lang, Adiel Statman, Samson Zhou
Introduction
Coresets are an important technique in machine learning, data sciences, and statistics for representing a large dataset with a much smaller amount of memory. Coresets are often used as a pre-processing dimensionality technique to improve the downstream efficiency of algorithms, both space and time. Informally speaking, a coreset of an input set of underlying points is a smaller number of weighted representatives of that can be used to approximate the cost of any query from a set of a given queries. For example, in the common -means clustering problem, the coreset must approximate for every query , where is a set of points and is taken to be the smallest Euclidean distance from to any point in . Thus to use a coreset to approximately solve the -means clustering problem, it suffices to find the optimal clustering on rather than find the optimal clustering on . Because the size of is much smaller than the size of , i.e., , then finding an optimal clustering on instead of will be much more efficient.
More generally, coreset is a set of points with corresponding weight function such that is a approximation to . Coresets have been extensively studied in -means clustering [BHI02, HM04, FS05, FS08, FL11, FS12, FSS13, BLUZ19, HV20, FSS20], subspace approximation [DRVW06, DV07, FL11, FMSW10a, FSS13, CW15, SW18], and a number of other geometric problems and applications [AHY06, FFS06, Cla08, DDH+08, AB09, PT18, HJLW18, ABB+19, MSSW18, BDM+18, MOB+20], due to the increasing availability of big data and the necessity for scalable methods to process this information.
The most common algorithmic procedure to designing a coreset is the following simple template. An algorithm first approximately evaluates the sensitivity of each point in the dataset. Informally, the sensitivity of a point quantities how important or distinct that point is, with respect to the given objective function on which we would like to optimize. Approximating the sensitivity of each point can often be done efficiently, so that the time to construct a coreset is often a lower order term compared to the runtime of the post-processing algorithm. The template then samples a fixed number of points, so that each point in the dataset with probability proportional to the sensitivity of the point. This approach is called sensitivity sampling and the fixed number of points is often a monotonically increasing function of the total sensitivity, defined to be the sum of the sensitivities of each point. Hence, if the numbered of sampled points is much smaller than the number of input points, this approach allows for compact dimensionality reduction, leading to improved performance of post-processing algorithms.
Since the total sensitivity is a central quantity to coreset techniques, the total sensitivity for various objective functions has been well-studied and completely characterized in some cases. However, it is not quite known what the optimal dependency between the total sensitivity and the size of the coreset should be; that is, what is optimal monotonically increasing function of the total sensitivity that governs the number of sampled points? Clearly smaller functions lead to smaller coresets, which lead to more efficient post-processing functions. Many recent coreset constructions in the past decade require constructing coresets whose size depends quadratically on the total sensitivity. In this paper, we show this dependency is not optimal; we introduce in Theorem 1.1 a generic construction whose dependency on the total sensitivity is only rather than [FL11]. Because the dependency is already black-boxed into the design of many coreset constructions, our results automatically improve many existing coreset algorithms simply by lowering the number of required samples, without modifying any other property of the algorithm; we are only showing that the worst-case theoretical guarantee of these algorithms is significantly and universally better than previously thought.
We show that the common sensitivity sampling framework only needs to sample points, where is the total sensitivity.
Let be the dimension of a query space . For each point , let be an upper bound on the sensitivity of point . Let , and . Then by sampling i.i.d. points from and rescaling each sampled point by , the resulting sample is an -coreset for .
In contrast, previous analysis showed that the sensitivity sampling framework required points [FL11]. We emphasize that our results are purely theoretical; we show that any worst-case guarantee that could previously be achieved with samples can actually be achieved with only samples. Hence our results can be universally plugged into any existing coreset construction algorithm simply by requiring a lower number of samples. Moreover, our results are optimal, since it can be shown by standard coupon-collector arguments that samples are necessary in some cases.
We show that the results of [LLS01] also succeed if the VC-dimension of is , rather than the pseudo-dimension. This implies that the algorithm outputs a -approximation of all functions in , which means if the function is too small, then the resulting data structure can only provide an additive error guarantee rather than a multiplicative relative error guarantee, but if the function is adequately large, then the resulting data structure provides a multiplicative error guarantee.
Fortunately, we show this guarantee suffices to obtain an -coreset. We break the query space into partitions, based on how much a point contributes to a query, compared to the total contribution to a query across all the points. If the contribution of a partition is large, then our -approximation guarantees a good approximation to this partition. Now if the contribution of a partition is small, then two things can happen. Either it is possible that the sum of the contributions of all of the “small” partitions is large, in which case our -approximation again guarantees a good approximation, or the sum of the contributions remains insignificant. In this case, we only have an additive approximation of the contributions for these points, but because the sum of the contributions is insignificant, an additive error on these points translates to a small relative error on the entire objective function.
Theorem 1.1 has applications to many problems in machine learning. In Section 3, we describe applications to model fitting problems. Specifically, we consider the -projective clustering problems such as -median/-means, -line clustering, -subspace approximation, and the integer -projective clustering problem.
Informally, the goal is to find a model in a restricted family of set of -tuples of affine -subspaces that minimizes , where is a set of input points. Here, is the union of -flats so that if , then each -flat reduces to a point and the -projective clustering problem becomes the -median problem with the appropriate metric. On the other hand, with an alternate distance function (the squared Euclidean distance), , the -projective clustering objective becomes the -means problem. When and is fixed, the objective becomes the -line clustering problem but if is fixed and , then the objective instead becomes the subspace approximation problem. Finally, in the integer -projective clustering problem, all points in are assumed to have integer coordinates from some predetermined range. Our results subsume earlier versions online that have not received independent verification and are summarized in Figure 1.
Although our primary contribution is theoretical, we complement our worst-case guarantees with empirical evaluations on both small and large-scale datasets, which we describe in Section 5.
2 Preliminaries
Let be called a ground set. Let be a (possibly ordered) multi-set and be a function that maps every to a weight . The pair is called a weighted set in . If for every then the (un)weighted set may be denoted by for short.
The order of the points in can be arbitrary in this paper. However, even if contains only a single copy of each point, the corresponding coreset may contain multiple instances of some points. Hence, we consider coresets as multi-sets, although duplicated points can usually be replaced by a single weighted point without changing the claimed results. The union and intersection are also implied to be over multi-sets in this paper.
Usually the loss function has specific properties such as being a pseudo distance function , as will be defined later. However, it may also be more complicated such as a subtraction between pseudo distance functions, which will also be used in this paper. This is also why it may return a negative number. In general, we will be interested in approximating for every query in the query space up to an additive error of .
For a set , a query function , and a cost function , we define the VC-dimension of the range space that it induced, as defined below. The classic VC-dimension was defined for sets and subset and here we generalize it to query spaces, following [FL11].
The following definition of sensitivity is central to our paper, as we shall show that the coreset size of our algorithm is proportional to the total sensitivity of the input set.
Let be a query space over a ground set , where and . Then we define the sensitivity of a point by .
Then the total sensitivity of an input set is the natural definition:
Let be a query space over a ground set , where and . We define the total sensitivity of by , where is the sensitivity of .
We next define two related concepts, the -samples and relative -approximations.
[LLS01] Let . For every , we define the distance function . Let be a query space over a ground set , where and . Then the weighted set is called a -sample for if is a query space, and for every , , where .
[HS11] Let . Let be a query space over a ground set , where and . Then the weighted set is called a -sample for if is a query space, and for every ,
, for
, for ,
where .
We recall the equivalence between -samples and relative -approximations:
[HS11] Let be a range space. If is a -sample for with and , then is a relative -approximation for .
Let be a weighted set in , and be an approximation error. The weighted set in is an -coreset for a query space if for every we have .
Sensitivity Sampling
In this section, we show that provable worst-case guarantees for constant factor approximation can be achieved using the sensitivity sampling framework to construct coresets of size , where is the total sensitivityWe also achieve optimal dependence on for a -approximation, but we omit these factors for ease of discussion. This improves on previous analysis that the sensitivity sampling framework to sample points to construct coresets that guaranteed constant factor approximation [FL11]. We remark that our result is purely theoretical and does not require novel algorithmic implementation. Instead, our result shows that the parameters in existing coreset construction algorithms can be improved while still guaranteeing worst-case performance.
Recall that the sensitivity of a point is defined by , where is a weight function and is a loss function between an input point and a query set. However, determining the exact sensitivity of a point can be time-consuming, so we instead define to be an upper bound on the sensitivity. It turns out that upper bounds that are within a constant factor approximation of the exact sensitivity of a point are often efficiently computable. Then is an upper bound on the total sensitivity, which is the sum of the sensitivities of all points in .
We now formalize the sensitivity sampling framework broadly used in algorithmic design. We form a sample by picking the first point of to be with probability and reweighting the sampled point with the inverse of the sampling probability. We show that repeatedly sampling points from with replacement until has points suffices to obtain an -coreset for with probability if the underlying query space has VC dimension . The sensitivity sampling framework appears in full in Algorithm 1.
We first recall the following definition of pseudo-dimension:
[LLS01] show that if has pseudo-dimension , then samples suffices to simultaneously obtain an -sample to expectation of all functions in with constant probability. Namely, [LLS01] show the following two lemmas:
Let be a set of functions from to $\muX\nu>00<\alpha<1N\geq\frac{2}{\alpha^{2}\nu}N>0\Gamma_{N}\{1,\ldots,2N\}i\leq NiN+iiN+iU\Gamma_{m}$. Then
Let be the pseudo-dimension of , where for any . Let be the uniform distribution over . Then
Observe that combining Lemma 2.2 and Lemma 2.3 and solving for recovers the bound from [LLS01] of . We need an analog of their sampling result for VC-dimension rather than pseudo-dimension. As it turns out, the only place [LLS01] uses pseudo-dimension in Lemma 2.3 is a black-box reduction from the following lemma to bound the size of :
Moreover, [Hau95] proved the exact same statement when is the VC-dimension of , rather than the pseudo-dimension.
Specifically, Lemma 2.5 follows from Corollary 1 in [Hau95] because .
Thus by using Lemma 2.5 rather than Lemma 2.4, we can recover Lemma 2.3 using VC-dimension rather than pseudo-dimension in the following formulation of Theorem 2.6. Hence, we can relate the sampling complexity of learning a class of functions to their VC-dimension:
2 Reduction to ε𝜀\varepsilon-Coresets
We now show that an -sample to a class of functions suffices to achieve an -coreset under the appropriate parameters. The proof partitions the points in an input set by their contribution to for some in the query space. A subset that contributes a large fraction towards will be well-estimated by the -sample. On the other hand, if is not well-estimated by the -sample, then its contribution towards must be small, so that intuitively, the additive error from the -sample is also small. Thus we can show that the sample is actually an -coreset.
Let be the dimension of a query space . Suppose that such that . Let , and . Let be a sufficiently large constant, and let be a sample of
Since is -approximation for and only consists of indices such that contributes at least fraction of the mass, then
Now if , then since is a -approximation for , then
Hence combining with (1) and noting that , then we have
On the other hand, if , then since is a -approximation for , it follows that
Since we have , then and thus
Moreover, implies that . Therefore, we have , so that
Again combining with (1) and noting that , then
Note that contains at most sets , it suffices to obtain -sample for sets, each with failure probability , using Theorem 2.6. By a union bound, the total failure probability is at most .
The intuition is that the class of functions represents the objective in the query space, so that a particular represents the objective for a particular query in the query space. For objectives like -means or -median clustering, each represents the objective for a separate set of centers. Then the goal is to learn simultaneously with a small number of samples.
The domain for the class of functions translates exactly to the ground set , which is the input points for objectives like -means or -medians. We first note that sampling a point of and then rescaling by the (inverse of the) sampling probability provides an unbiased estimator to the objective. [LLS01] then states that if we sample uniformly over , we can obtain a -approximation to the objective by bounding the variance through a small number of samples. Then the idea of sensitivity sampling is that instead of uniformly sampling points from , we sample each point of according to its sensitivity, but still rescale by the (inverse of the) sampling probability. Now the expectation of the samples is still the objective, but the variance is much smaller and so we require a smaller number of samples.
The real workhorse in this bound is Lemma 2.2 by [LLS01], which uses the chaining technique of Kolmogorov and refined by Talagrand [Tal94]. Crucially, the usage of chaining by [LLS01] manages to simultaneously learn a large number of functions in a class without needing to union bound over a net over the functions in . It is precisely this technique that avoids a quadratic dependency on from the union bound.
Applications
Our theoretical worst-case guarantee has a wide range of applications due to the prevalence of the coreset technique and how well-studied the total sensitivity is of various optimization problems. Note that for any problem whose sensitivity is known to be , Theorem 1.1 gives an improvement on dependency of from to for the number of sampled points. [VX12b] considers sensitivity sampling for shape fitting problems, focusing on -projective clustering problems, such as -median/-means, -line clustering, -subspace approximation, and the integer -projective clustering problem. We show that our results imply more efficient coreset constructions using the total sensitivity bounds on these problems obtained by [VX12b].
For the -line center problem and the integer general )-projective clustering problem, [VX12a] showed the following upper bounds on the total sensitivity:
Then Theorem 3.2 and Theorem 1.1 together imply efficient coresets for both the -line center problem and the integer -projective clustering problem.
We remark that Theorem 3.4 is subsumed by Theorem 3.6 below, as [VX12b] tighten the total sensitivity upper bound for the -line center problem by showing that in Theorem 3.2 is independent of .
From Theorem 3.5 and Theorem 1.1, we have
[VX12b] bounded the total sensitivity for the )-projective clustering problem, which includes -median and -means.
For either the -median problem or the -means problem, there exists an algorithm that outputs a set of weighted points that is an -coreset, with probability at least .
[VX12b] also bounded the total sensitivity for the -subspace fitting problem.
By Theorem 3.9 and Theorem 1.1, we conclude that
Coreset for k𝑘k-clustering
This section considers tighter bounds for -clustering and may be skipped for general applications. We introduce -pseudo distances and define the importance of a point as a generalization of the sensitivity. Using the importance, we then give an analog of Theorem 1.1 with sharper bounds for -pseudo distances. As a result, we obtain stronger bounds for coreset constructions for -clustering.
We reiterate that our results in this section mirror those of Section 2. We only provide theoretical guarantees on the number of samples required by the sensitivity sampling framework for -clustering. We specify the framework in full in Algorithm 2.
We first require the following definition of -assignment for bicriteria algorithms.
Let be a ground set and be a query space where . Let be a query that minimizes the loss of over every query,
Let , and such that . A function is an -assignment for if
Every is called a center and its cluster in is .
Intuitively, an -assignment is just a bicriteria clustering with approximation factor and an overselection of centers by a factor of . Thus for -means clustering, any -approximation algorithm that chooses centers can be used to determine an -assignment for each of the points.
The following definition is especially useful for -means clustering.
Let be a ground set and . A symmetric function is -pseudo distance over if for every
For a finite set , we denote .
Note that the above definition does not assume that for every . The inequality in Definition 4.2 is sometimes called “weak triangle inequality”.
Let be a -pseudo distance over a ground set . For every pair of points and a finite set ,
Proof : For every , and a center that is closest to , i.e. , we have
We now give a generalization of the notion of sensitivity in the form of importance.
Let be a query space where and is a -pseudo distance. Let be an -assignment for . For every and , we define
For every center and a point in its cluster we define
We now show that the importance satisfies a similar function as the notion of sensitivity.
Let , and be defined as in Definition 4.4. Then for every we have
Proof : For simplicity, we denote and for every , and for every . We prove the claim for a point in the cluster of some center , as in Definition 4.4. Let and assume , otherwise the lemma trivially holds. We need to upper bound
where the first inequality holds by Lemma 4.3, and the second inequality holds since is an -assignment. To bound the last term, note that
where the first inequality is by Lemma 4.3, (4) holds since and since is symmetric by definition, and (5) holds since is an -assignment.
Dividing by yields
Substituting this in (3) yields the desired result
As a warm-up, we now prove an analog of Theorem 1.1 for -pseudo distances that provides tighter bounds, due to the tighter setting of from the assignment.
be a query space, where is a -pseudo distance and .
be an assignment for .
be the VC-dimension of , where was defined in (2).
be a sufficiently large constant, , and
be the output of a call to ; see Algorithm 2.
Then, , and, with probability at least , is an -coreset of size for .
Proof : Let . By Lemma 4.5, for every
The probability of choosing to be, say, the first point in , is
Using the last inequality and (6), we apply Theorem 2.7 to obtain that, with probability at least , we have that for all ,
implies that is an -coreset as desired.
In this section, we define a -pseudo distance function, which serves as a generalization of -pseudo distances, and give smaller coreset constructions for -pseudo distance functions. Our algorithms appear in Algorithm 3 and Algorithm 4.
We define the following generalization of distance to handle -clustering.
Let be a -pseudo distance over as in Definition 4.2. For and , is also a -pseudo distance function if for every we have
Intuitively, the -pseudo distance handles loss functions such as the squared Euclidean distance that do not satisfy the triangle inequality but rather a generalized version of the triangle inequality.
Let be a -pseudo distance function. Then for every finite set and we have
where the first inequality is by the definition of , and the second inequality is by Definition 4.7.
where the last inequality is by the assumption of this case. Combining (7) and (8) yields that (in both cases)
Let be a query space where , and is a -pseudo distance function. Let be an -assignment for . Let such that , and
Consider the variables in Definition 4.9. Let
and be the VC-dimension of . Let be a sufficiently large constant,
and be the output of a call to algorithm ; see Algorithm 3. Then, , , and with probability at least , we have that for all ,
Proof : Let and extend the function as defined in Algorithm 3 to be for every . Also define and for every . The difference in the loss between taking the original points or its coreset is
where (12) is by the triangle inequality, and (13) holds since
where the last equality is by the definition of in Line 3 of Algorithm 3.
By letting as defined in (10), (13) is bounded by , which equals
where the last inequality is by the triangle inequality. We now bound each of the last terms.
where (16) holds since is an -assignment, i.e.,
(17) is by Lemma 4.8, and (18) is by (10) and the assumption .
, and for every constant there is a sufficiently large constant such that
Plugging these bound in Theorem 2.7 with , and the query space yields that, with probability at least , we have that for all ,
Assume that the last equation indeed holds (which happens with probability at least ). By this and the definition of , for every , (14) is bounded by
Bound on (15): Since , and using the triangle inequality
where the first inequality is by Lemma 4.8, the second holds since , and the last inequality is by (9).
Our -assignment approximates the sum of distances to a query up to an additive error as follows.
where (23) is by Lemma 4.3, and (24) is by (19). Hence,
where (25) is by (21), (26) holds by (23), (27) holds by (22), and (28) holds since .
It is left to bound the rightmost term in (28). Let such that for every and
where (30) holds since , in (31) we simply multiplied and divided by , and (32) holds since for every .
where (33) holds since , and (34) is by definition (29) of .
Let , , and for every , let . Hence, for every ,
and for every constant there is a sufficiently large such that
Substituting the query space , , , and instead of in Theorem 2.7, yields that with probability at least , we have
Assume the event that (35) holds for every occurs, which happens with probability at least , by the union boundInstead of using the union bound, we could simply choose as the set of queries, instead of and . However, in this would introduce a term of in the coreset size compared to the current term.. Plugging (35) in (34) yields
Combining the last inequalities bounds (15) with probability at least , as
where (37) holds by (28), (38) by (30), and (39) by (36).
Finally, replacing (14) and (15) with (20) and (39) respectively, proves that, with probability at least we have
By this and (13), it follows that approximates as desired.
We now handle the specific case where is a -pseudo distance function.
Consider the variables in Theorem 4.10, where is replaced by
Let be the output of a call to algorithm ; see Algorithm 3.
Then, , , and with probability at least , is an -coreset of size for .
Proof : Let . After replacing with and with in Theorem 4.10, we obtain that with probability at least ,
Assume that this event indeed occurs and the inequality holds, and let .
We will bound the error by excluding from this coreset, i.e.,
where (41) is by the triangle inequality, and (42) is by (40). The rightmost term is
where (43) is by the definition of in Line 3 of Algorithm 3.
The bound on the rightmost term is similar to (35), after replacing the bound with , which is the reason for the largest size of the coreset. Specifically, let , , and for every , let , where is defined in (29). Hence, for every ,
and for every constant there is a sufficiently large such that
Substituting the query space , , and instead of in Corollary 2.7, yields that with probability at least , we have
Assume the event that (35) holds for every indeed occurs, which happens with probability at least . Substituting the value of from (35) and multiplying by yields
where (46) is by (45), and (47) is by the property of -assignment in (24).
Combining the previous inequalities all together yields the desired result
where (48) is by (42), and (49) is by (47).
Using the union bound on previous assumptions, this holds with probability at least .
2 Positively weighted coresets
In this section, we give a construction for a coreset that is guaranteed to output positive weights associated with each sampled point.
Consider the variables in Theorem 4.10. Let
and let be the output of a call to algorithm ; see Algorithm 4. Then, , , and with probability at least , we have that for all ,
Proof : The proof is the same as the proof of Theorem 4.10 except for replacing with everywhere, and replacing the bound on (25) by
where the first inequality is similar to (27), and the equality is since for every
Empirical Evaluations
This concludes our discussion of the general sensitivity sampling framework. Although our contribution is primarily theoretical, we nevertheless performed empirical evaluations in Python 3.6 via the Numpy and Scipy.sparse libraries on a desktop machine with an Intel i7-6850K CPU @ 3.60GHZ, 64GB RAM. We consider coreset constructions based on sensitivity sampling for bicriteria algorithms (Algorithm 1), general loss functions that satisfy the weak triangle inequality (Algorithm 2), and the conditional normalized distance (Algorithm 3). We compared Algorithms 1-3 to uniform sampling on -means clustering on both relatively small offline data and large-scale streaming data that cannot fit into memory. Algorithms 1-3 each require a bicriteria algorithm to approximate the importance of each point; we use kmeans++ with and to approximate the importances, so that the runtime is linear.
For experiments on small offline datasets, we compared our coreset constructions for -means clustering in Algorithms 1-3 vs. uniform sampling on the datasets: (i) Gyroscope data and (ii) Accelerometer data. Collected by [AGO+13b], and can be found on [AGO+13a], the experiments have been carried out with a group of 30 volunteers within an age bracket of 19-48 years. Each person performed six activities (walking, walking upstairs, walking downstairs, sitting, standing, laying) while wearing a Samsung Galaxy S II smartphone on the waist. Using its embedded gyroscope (resp. accelerometer), 3-axial angular velocity (resp. linear acceleration) were captured at a constant rate of 50Hz. The experiments have been video-recorded to label the data manually. Data was collected from measurements; each instance consists of measurements from dimensions: , , , each in a size of 128.
We ran Algorithms 1-3 and uniform sampling on the above six datasets with different sample/coreset size, between 1000 to 7000, with and . The multiplicative approximation error (empirical ) was calculated by , where is the matrix whose rows correspond to the input points, corresponds to the centers of the whole data (two Lloyd’s iterations after kmeans++ initialization) and is the clustering of the coreset. Our results show a significant improvement of our algorithms over uniform sampling; we present the gyroscope data evaluations in Figure 2 and the accelerometer data evaluations in Figure 3.
2 Evaluations on Streaming Data
To handle large-scale streaming data that cannot fit into memory, our system separates the points of the data into chunks of a desired size of coreset, called . We use a merge-and-reduce framework on a binary tree, e.g. [FMSW10b], where each node is a coreset of the union of the data represented by its children nodes and the bottom layer of the tree consists of consecutive chunks of the data of size . Thus the root of the tree is a coreset of the whole data. We build a tree of height for our data, dividing the input points across chunks of size .
We compared uniform sampling to Algorithms 1 and 3 for -means clustering on a created document-term matrix of Wikipedia (parsed enwiki-latest-pages-articles.xml.bz2-rss.xml from [wic19]), i.e. sparse matrix with 4624611 rows and 100k columns where each cell equals the value of how many appearances the word number has in article number . We use a standard dictionary of the 100k most common words in Wikipedia [Dic12]. We concatenated the coreset received in each floor and compared the received error in each floor. The error we determined was calculated by the formula , where is the original data matrix, is the clustering of the whole data (Lloyd’s iterations until 1% convergence, after ++ initialization) and is the clustering of the coreset. We used two values of , 100 and 200. We present our results in Figure 4. We concatenated the coreset received in each floor and compared the received error in each floor. The error we determined was calculated by the formula , where is the original data matrix, is the clustering of the whole data (Lloyd’s iterations until 1% convergence, after ++ initialization) and is the clustering of the coreset. We present our results in Figure 4 for and . Similar to the offline evaluations, we obtain better results for our algorithms than uniform sampling. However, unlike than the offline data, here the conditional normalized algorithm gets much better results than the general sensitivity sampling algorithm.
Algorithms.
The algorithms we compared are uniform sampling, and our Algorithm 2 and 4.
Results.
We concatenated the coreset received in each floor and compared the received error in each floor. The error we determined was calculated by the formula , where is the original data matrix, is the clustering of the whole data (Lloyd’s iterations until 1% convergence, after ++ initialization) and is the clustering of the coreset. We used two values of , 100 and 200. We present our results in Figure 4.
Discussion.
Indeed also for this dataset we got better results for our algorithm than uniform sampling. However, unlike than in Section 5, here Algorithm 2 gets much better results than Algorithm 1.