You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
skimage.io.imread returns incorrect dimensions (according to docs) #1496
Importing a TIFF image using skimage.io.imread returns an array with shape (3,M,N) instead of (M,N,3). This breaks the flatten and as_grey features. The results are the same calling imread with plugin='tifffile'.
In [1]: im = skimage.io.imread('image.tif')
In [2]: im.shape
Out[2]: (3, 768, 1024)
In [3]: im = skimage.io.imread('image.tif', as_grey = True)
In [4]: im.shape
Out[4]: (3, 768)
In [5]: im = skimage.io.imread('image.tif', flatten = True)
In [6]: im.shape
Out[6]: (3, 768)
Activity