Skip to content

Commit eb15631

Browse files
committed
[FIX][MLLIB] fix seed handling in Python GMM
If `seed` is `None` on the python side, it will pass in as a `null`. So we should use `java.lang.Long` instead of `Long` to take it. Author: Xiangrui Meng <[email protected]> Closes apache#4349 from mengxr/gmm-fix and squashes the following commits: 3be5926 [Xiangrui Meng] fix seed handling in Python GMM
1 parent d37978d commit eb15631

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

mllib/src/main/scala/org/apache/spark/mllib/api/python/PythonMLLibAPI.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -295,7 +295,7 @@ class PythonMLLibAPI extends Serializable {
295295
k: Int,
296296
convergenceTol: Double,
297297
maxIterations: Int,
298-
seed: Long): JList[Object] = {
298+
seed: java.lang.Long): JList[Object] = {
299299
val gmmAlg = new GaussianMixture()
300300
.setK(k)
301301
.setConvergenceTol(convergenceTol)

0 commit comments

Comments
 (0)