问题来源:
在导入sklearn库时,出现
/usr/lib/python3/dist-packages/scipy/sparse/linalg/isolve/iterative.py in ()
8
9 from scipy.sparse.linalg.interface import LinearOperator
—> 10 from scipy._lib.decorator import decorator
11 from .utils import make_system
12 from scipy._lib._util import _aligned_zeros
ModuleNotFoundError: No module named ‘scipy._lib.decorator’
卸载scipy并重新安装。(我的scipy版本为0.19.1,安装上新的1.1.0版后问题自动消失)
unbutu下卸载: sudo pip3 uninstall scipy
重新安装scipy: sudo pip3 install scipy
Mark.