Skip to content

Commit

Permalink
Rename initializationMode to initMode
Browse files Browse the repository at this point in the history
  • Loading branch information
yu-iskw committed Jul 1, 2015
1 parent 79ea82b commit 99b1b96
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -72,10 +72,10 @@ private[clustering] trait KMeansParams
* (Bahmani et al., Scalable K-Means++, VLDB 2012). Default: k-means||.
* @group param
*/
val initializationMode = new Param[String](this, "initializationMode", "initialization algorithm")
val initMode = new Param[String](this, "initMode", "initialization algorithm")

/** @group getParam */
def getInitializationMode: String = $(initializationMode)
def getInitializationMode: String = $(initMode)

/**
* Param for the number of steps for the k-means|| initialization mode. This is an advanced
Expand Down Expand Up @@ -152,7 +152,7 @@ class KMeans(override val uid: String) extends Estimator[KMeansModel] with KMean
setDefault(k, 2)
setDefault(maxIter, 20)
setDefault(runs, 1)
setDefault(initializationMode, MLlibKMeans.K_MEANS_PARALLEL)
setDefault(initMode, MLlibKMeans.K_MEANS_PARALLEL)
setDefault(initializationSteps, 5)
setDefault(epsilon, 1e-4)
setDefault(seed, Utils.random.nextLong())
Expand All @@ -173,7 +173,7 @@ class KMeans(override val uid: String) extends Estimator[KMeansModel] with KMean
/** @group setParam */
def setInitializationMode(value: String): this.type = {
MLlibKMeans.validateInitializationMode(value)
set(initializationMode, value)
set(initMode, value)
}

/** @group setParam */
Expand Down

0 comments on commit 99b1b96

Please sign in to comment.