Github user jkbradley commented on a diff in the pull request:
https://github.com/apache/spark/pull/20111#discussion_r159106208
--- Diff:
mllib/src/test/scala/org/apache/spark/ml/feature/BucketedRandomProjectionLSHSuite.scala
---
@@ -98,6 +97,21 @@ class BucketedRandomProjectionLSHSuite
MLTestingUtils.checkCopyAndUids(brp, brpModel)
}
+ test("BucketedRandomProjectionLSH: streaming transform") {
+ val brp = new BucketedRandomProjectionLSH()
+ .setNumHashTables(2)
+ .setInputCol("keys")
+ .setOutputCol("values")
+ .setBucketLength(1.0)
+ .setSeed(12345)
+ val brpModel = brp.fit(dataset)
+
+ testTransformer[Tuple1[Vector]](dataset.toDF(), brpModel, "keys",
"values") {
+ case Row(_: Vector, values: Seq[_]) =>
--- End diff --
I don't think we have to. The main thing here is to make sure that the
transform really does happen. Other tests check validity of the values.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]