Github user josepablocam commented on a diff in the pull request:
https://github.com/apache/spark/pull/7075#discussion_r35943216
--- Diff:
mllib/src/test/scala/org/apache/spark/mllib/stat/HypothesisTestSuite.scala ---
@@ -254,4 +254,115 @@ class HypothesisTestSuite extends SparkFunSuite with
MLlibTestSparkContext {
assert(rCompResult.statistic ~== rKSStat relTol 1e-4)
assert(rCompResult.pValue ~== rKSPVal relTol 1e-4)
}
+
--- End diff --
The edge case of partitions with no elements does indeed exist, which is
why we have that odd check for whether a result after folding in a partition
matches the initial accumulator. The test involving `nonOverlap1P` and
`nonOverlap2P` should test for situations where a partition has only 1 sample.
I'll break these out into separate tests, since they probably deserve to be
singled out.
---
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]