Yanbo Liang created SPARK-19144:
-----------------------------------

             Summary: Add test for GaussianMixture with distributed 
decompositions
                 Key: SPARK-19144
                 URL: https://issues.apache.org/jira/browse/SPARK-19144
             Project: Spark
          Issue Type: Test
          Components: ML
            Reporter: Yanbo Liang
            Priority: Minor


{code}
test("check distributed decomposition") {
    val k = 5
    val d = decompositionData.head.size
    assert(GaussianMixture.shouldDistributeGaussians(k, d))

    val gmm = new 
GaussianMixture().setK(k).setSeed(seed).fit(decompositionDataset)
    assert(gmm.getK === k)
}
{code}
In ML {{GaussianMixtureSuite}}, the above test only check that when we 
distribute the computation that it produces a model, but does not check that it 
produces a correct model.
It should have, but depends on {{GaussianMixture}} can be set with initialModel 
(SPARK-15785), otherwise, this algorithm seems incapable of learning even this 
very contrived example. After that was resolved, we can add a correctness test 
in the above case.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@spark.apache.org
For additional commands, e-mail: issues-h...@spark.apache.org

Reply via email to