[PYTHON] from scipy.misc If "ImportError: cannot import name imread" occurs in import imread, imresize

As the title says. This is due to a lack of modules that scipy uses to read images.

error contents

Traceback (most recent call last):
  File "vg_to_imdb.py", line 9, in <module>
    from scipy.misc import imread, imresize
ImportError: cannot import name imread

When doing image processing with scipy, I think that such an error may occur.

Solution

pip install Pillow

I was able to solve it by installing Pillow. Reference: Stackoverflow: Importing image to python: cannot import name'imread'

Recommended Posts

from scipy.misc If "ImportError: cannot import name imread" occurs in import imread, imresize
ImportError: cannot resolve import name
ImportError: cannot resolve import name
When it becomes Cannot import name "Feature" from "setuptools".
ImportError: cannot import name'factorial' ~ ~ ~
ImportError: cannot import name'_check_sample_weight'
If you are told cannot by Python import, review the file name