def isvector(X):
return np.prod(X.shape)==np.max(X.shape)<EOL>
Like the Matlab (TM) function with the same name, returns *True*
if the supplied numpy array or matrix *X* looks like a vector,
meaning it has a one non-singleton axis (i.e., it can have
multiple axes, but all must have length 1, except for one of
them).

If you just want to see if the array has 1 axis, use X.ndim == 1.