Github user yanboliang commented on a diff in the pull request:
https://github.com/apache/spark/pull/17117#discussion_r104164797
--- Diff: mllib/src/main/scala/org/apache/spark/ml/clustering/KMeans.scala
---
@@ -253,7 +255,18 @@ object KMeansModel extends MLReadable[KMeansModel] {
@Since("1.5.0")
class KMeans @Since("1.5.0") (
@Since("1.5.0") override val uid: String)
- extends Estimator[KMeansModel] with KMeansParams with
DefaultParamsWritable {
+ extends Estimator[KMeansModel]
+ with KMeansParams with HasInitialModel[KMeansModel] with MLWritable {
+
+ /**
+ * A KMeansModel to use for warm start.
+ * Note the cluster count of initial model must be equal with [[k]],
+ * otherwise, throws IllegalArgumentException.
+ * @group param
+ */
+ @Since("2.2.0")
+ final val initialModel: Param[KMeansModel] =
--- End diff --
Make sense, I refactored them as ```ALSParams``` and ```ALSModelParams```.
---
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 [email protected] or file a JIRA ticket
with INFRA.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]