Github user jkbradley commented on a diff in the pull request:

    https://github.com/apache/spark/pull/1407#discussion_r15073983
  
    --- Diff: 
mllib/src/main/scala/org/apache/spark/mllib/clustering/LocalKMeans.scala ---
    @@ -59,6 +59,11 @@ private[mllib] object LocalKMeans extends Logging {
             cumulativeScore += weights(j) * KMeans.pointCost(curCenters, 
points(j))
             j += 1
           }
    +      if (j == 0) {
    +        logWarning("kMeansPlusPlus initialization ran out of distinct 
points for centers." +
    +          s" Using duplicate point for center k = $i.")
    +        j = 1
    --- End diff --
    
    I'll go with the second suggestion.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

Reply via email to