Traceback (most recent call last):
from skimage import io
File "/home/Anconda3/envs/face_alignment/lib/python3.6/site-packages/skimage/__init__.py", line 167, in
from .util.dtype import (img_as_float32,
File "/home/Anconda3/envs/face_alignment/lib/python3.6/site-packages/skimage/util/__init__.py", line 8, in
from .arraycrop import crop
File "/home/Anconda3/envs/face_alignment/lib/python3.6/site-packages/skimage/util/arraycrop.py", line 8, in
from numpy.lib.arraypad import _validate_lengths
ImportError: cannot import name '_validate_lengths'
网上绝大多数回答是:
numpy版本太高,对numpy进行重新安装:
pip install numpy==1.15.0
但是降低版本会引来其他很多问题,因此我认为这不是很好的解决方式。
pip install -U scikit-image