我正在使用 python 3.7 最近我在导入 sklearn 模块时开始收到此错误。我在 Jupyter Notebook、Python IDLE、Pycharm 虚拟环境中遇到同样的错误
>>> import sklearn
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "C:\Users\aditya\AppData\Roaming\Python\Python37\site-packages\sklearn\__init__.py", line 75, in <module>
from .utils._show_versions import show_versions
File "C:\Users\aditya\AppData\Roaming\Python\Python37\site-packages\sklearn\utils\_show_versions.py", line 12, in <module>
from ._openmp_helpers import _openmp_parallelism_enabled
ImportError: DLL load failed: The specified module could not be found.
我也试过重新安装。之后,我复制了另一个没有问题的项目的 venv 的 sklearn 的内容。这东西工作了几次。但现在它不能再工作了
注意:pandas、numpy、scipy 等已安装并且工作正常。几天前,Sklearn 也运行良好
这是 scikit-learn 0.22.0 打包中的一个问题,将在 0.22.1(下周发布)中解决。该问题在以下位置进行跟踪:github.com/scikit-learn/scikit-learn/issues/15899。有两种可能的解决方法:
conda install conda-forge::scikit-learn
本文收集自互联网,转载请注明来源。
如有侵权,请联系 [email protected] 删除。
我来说两句