I have successfully installed scipy, numpy, and pillow, however I get error as below
ImportError: cannot import name 'imread'
I have successfully installed scipy, numpy, and pillow, however I get error as below
ImportError: cannot import name 'imread'
Are you following the same steps?
import scipy.misc
img = scipy.misc.imread('my_image_path')
# To verify image is read properly.
import matplotlib.pyplot as plt
print(img.shape)
plt.imshow(img)
plt.show()
imread
and imsave
are deprecated in scipy.misc
Use imageio.imread
instead after import imageio
.
For saving -
Use imageio.imsave
instead or use imageio.write
For resizing use skimage.transform.resize
instead after import skimage