We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 1314b7a commit ee48407Copy full SHA for ee48407
src/tdamapper/_common.py
@@ -26,12 +26,12 @@ def _is_sparse(self, X):
26
return hasattr(X, 'toarray')
27
28
def _validate_X_y(self, X, y):
29
- X = np.asarray(X)
30
- y = np.asarray(y)
31
-
32
if self._is_sparse(X):
33
raise ValueError('Sparse data not supported.')
34
+ X = np.asarray(X)
+ y = np.asarray(y)
+
35
if X.size == 0:
36
msg = f'0 feature(s) (shape={X.shape}) while a minimum of 1 is required.'
37
raise ValueError(msg)
0 commit comments