spark-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "DB Tsai (JIRA)" <>
Subject [jira] [Commented] (SPARK-17789) Don't force users to set k for KMeans if initial model is set
Date Thu, 06 Oct 2016 02:04:20 GMT


DB Tsai commented on SPARK-17789:

I have comment on the code. When the initial model is set, the k should be set to the # of
centers in the initial model.

> Don't force users to set k for KMeans if initial model is set
> -------------------------------------------------------------
>                 Key: SPARK-17789
>                 URL:
>             Project: Spark
>          Issue Type: Improvement
>          Components: ML
>            Reporter: Seth Hendrickson
>            Priority: Minor
> In the initial implementation of initalModel, we allow users to set the initial model
with a KMeansModel that has a different {{k}} than the current model. We throw an error at
train time if the two are mismatched. This means that the following code throws a runtime
> {code}
> val kmeansModel = new KMeans().setInitialModel(model).fit(df)
> {code}
> We should discuss this behavior, and decide if we should enforce users to set both the
initial model and k, or if we should alter k when the initial model is set, or if we should
keep the current behavior.

This message was sent by Atlassian JIRA

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message