Compruebe si la matriz Numpy es 1D
>>> a = np.array([[1, 2], [3, 4]])
>>> a.ndim == 1
False
XeN0N
>>> a = np.array([[1, 2], [3, 4]])
>>> a.ndim == 1
False