[SPARK-14634][ML][FOLLOWUP] Delete superfluous line in BisectingKMeans

## What changes were proposed in this pull request?
As commented by jkbradley in https://github.com/apache/spark/pull/12394, `model.setSummary(summary)` is superfluous

## How was this patch tested?
existing tests

Author: Zheng RuiFeng <ruifengz@foxmail.com>

Closes #15619 from zhengruifeng/del_superfluous.
This commit is contained in:
Zheng RuiFeng 2016-10-25 03:19:50 -07:00 committed by Yanbo Liang
parent 6f31833dbe
commit 38cdd6ccda
2 changed files with 5 additions and 6 deletions

View file

@ -265,9 +265,8 @@ class BisectingKMeans @Since("2.0.0") (
val summary = new BisectingKMeansSummary(
model.transform(dataset), $(predictionCol), $(featuresCol), $(k))
model.setSummary(summary)
val m = model.setSummary(summary)
instr.logSuccess(m)
m
instr.logSuccess(model)
model
}
@Since("2.0.0")

View file

@ -324,9 +324,9 @@ class KMeans @Since("1.5.0") (
val model = copyValues(new KMeansModel(uid, parentModel).setParent(this))
val summary = new KMeansSummary(
model.transform(dataset), $(predictionCol), $(featuresCol), $(k))
val m = model.setSummary(summary)
instr.logSuccess(m)
m
model.setSummary(summary)
instr.logSuccess(model)
model
}
@Since("1.5.0")