首页 > 解决方案 > Python3:更新 numpy、scipy 和 scikit-learn 后没有名为“numpy.testing.decorators”的模块

问题描述

此处已回答了一个相关问题。但是,在我更新我numpyscipy、 和scikit-learn包后,

xxx:~$ pip3 freeze | grep numpy
numpy==1.19.2
xxx:~$ pip3 freeze | grep scipy
scipy==1.5.2
xxx:~$ pip3 freeze | grep scikit-learn
scikit-learn==0.23.2

并运行(我重新启动终端)

import scipy.stats as st

我仍然有错误ModuleNotFoundError: No module named 'numpy.testing.decorators'

一条评论:

此错误仅针对 Python3 显示。对于 Python2,它通过了。

标签: pythonnumpyscikit-learnscipyscipy.stats

解决方案


推荐阅读