diff options
author | Xiangrui Meng <meng@databricks.com> | 2015-02-03 20:39:11 -0800 |
---|---|---|
committer | Xiangrui Meng <meng@databricks.com> | 2015-02-03 20:39:18 -0800 |
commit | 679228b7f4c865147ac65099ffd6f5aa45e7126d (patch) | |
tree | 3cd8454ca53e06ebfb529bb396927d52a1fea475 /mllib | |
parent | 5c63e056746171a331b27336ebf3b8dbb23a0952 (diff) | |
download | spark-679228b7f4c865147ac65099ffd6f5aa45e7126d.tar.gz spark-679228b7f4c865147ac65099ffd6f5aa45e7126d.tar.bz2 spark-679228b7f4c865147ac65099ffd6f5aa45e7126d.zip |
[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 <meng@databricks.com>
Closes #4349 from mengxr/gmm-fix and squashes the following commits:
3be5926 [Xiangrui Meng] fix seed handling in Python GMM
(cherry picked from commit eb15631854f8e8e7bcd1b3331f18d6ee81dd6d5c)
Signed-off-by: Xiangrui Meng <meng@databricks.com>
Diffstat (limited to 'mllib')
-rw-r--r-- | mllib/src/main/scala/org/apache/spark/mllib/api/python/PythonMLLibAPI.scala | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/mllib/src/main/scala/org/apache/spark/mllib/api/python/PythonMLLibAPI.scala b/mllib/src/main/scala/org/apache/spark/mllib/api/python/PythonMLLibAPI.scala index 980980593d..3f29b82ce8 100644 --- a/mllib/src/main/scala/org/apache/spark/mllib/api/python/PythonMLLibAPI.scala +++ b/mllib/src/main/scala/org/apache/spark/mllib/api/python/PythonMLLibAPI.scala @@ -295,7 +295,7 @@ class PythonMLLibAPI extends Serializable { k: Int, convergenceTol: Double, maxIterations: Int, - seed: Long): JList[Object] = { + seed: java.lang.Long): JList[Object] = { val gmmAlg = new GaussianMixture() .setK(k) .setConvergenceTol(convergenceTol) |