opened
fqhuy
username_0
Hi username_1,

First of all, I would like to thank you guys for the great library that you are building and making it open to the research community. I just want to report a bug related to the version of scikit-learn package. The Kmeans fit and fit_predict worked well on 1.6.1 but not 1.7. I got this error message:

~/lib/python2.7/site-packages/sklearn/lda.py:4: DeprecationWarning: lda.LDA has been moved to discriminant_analysis.LinearDiscriminantAnalysis in 0.17 and will be removed in 0.19
  "in 0.17 and will be removed in 0.19", DeprecationWarning)
Traceback (most recent call last):
  File "main.py", line 429, in <module>
    cluster_covariances(params['covars'].reshape((-1, 3, 3)), n_clusters=7, means=params['means'].reshape((-1, 3)), viz=True)
  File "main.py", line 70, in cluster_covariances
    km.fit(covars)
  File "~/lib/python2.7/site-packages/pyriemann-0.2.3-py2.7.egg/pyriemann/clustering.py", line 155, in fit
    tol=self.tol)
  File "~/lib/python2.7/site-packages/pyriemann-0.2.3-py2.7.egg/pyriemann/clustering.py", line 20, in _fit_single
    X, n_clusters, init, random_state=random_state)
  File "~/lib/python2.7/site-packages/sklearn/cluster/k_means_.py", line 620, in _init_centroids
    x_squared_norms = row_norms(X, squared=True)
  File "~/lib/python2.7/site-packages/sklearn/utils/extmath.py", line 69, in row_norms
    norms = np.einsum('ij,ij->i', X, X)
ValueError: operand has more dimensions than subscripts given in einstein sum, but no '...' ellipsis provided to broadcast the extra dimensions.

Process finished with exit code 1
clustering.Kmeans works with sklearn 1.6.1 but not 1.7
issue
created
alexandrebarachant
username_1
Hi,
I'm aware of this bug, but i couldn't reproduce it locally (only on travis).
I will try to fix it ASAP.
comment
closed
alexandrebarachant
username_1
issue