fixed EM sample
authorAlexander Mordvintsev <no@email>
Wed, 4 Apr 2012 12:06:36 +0000 (12:06 +0000)
committerAlexander Mordvintsev <no@email>
Wed, 4 Apr 2012 12:06:36 +0000 (12:06 +0000)
samples/python2/gaussian_mix.py

index c71ff3c..c0f9816 100644 (file)
@@ -37,8 +37,7 @@ if __name__ == '__main__':
         print 'EM (opencv) ...'\r
         em = cv2.EM(points, params = dict( nclusters = cluster_n, cov_mat_type = cv2.EM_COV_MAT_GENERIC) )\r
         means = em.getMeans()\r
-        covs = np.zeros((cluster_n, 2, 2), np.float32) \r
-        covs = em.getCovs(covs)         # FIXME\r
+        covs = em.getCovs()\r
         found_distrs = zip(means, covs)\r
         print 'ready!\n'\r
 \r