使用编译python代码时出错sklearn.utils.shu文件

2024-04-26 04:47:53 发布

您现在位置:Python中文网/ 问答频道 /正文

我正在使用sklearn并遇到了以下问题:

  File "C:\python\lib\sklearn\__init__.py", line 74, in <module>
    from .base import clone
  File "C:\python\lib\sklearn\base.py", line 20, in <module>
    from .utils import _IS_32BIT
  File "C:\python\lib\sklearn\utils\__init__.py", line 20, in <module>
    from .murmurhash import murmurhash3_32
  File "__init__.pxd", line 918, in init sklearn.utils.murmurhash
ValueError: numpy.ufunc size changed, may indicate binary incompatibility. Expected 216 from C header, got 192 from PyObject

如何解决此错误?你知道吗


Tags: infrompyimportbasecloneinitis
1条回答
网友
1楼 · 发布于 2024-04-26 04:47:53

所以我得到了解决方案,我用 pip安装numpy升级 ,这更新了numpy,但是当我使用python时,它指向旧版本,所以我只是从中删除以前的numpy库 python/lib和python/lib/site包 然后重新安装。现在起作用了!你知道吗

相关问题 更多 >