【问题标题】:Receiving error when I am importing sklearn.ensemble导入 sklearn.ensemble 时收到错误
【发布时间】:2022-08-08 21:57:42
【问题描述】:

我收到以下错误。

from sklearn.ensemble import RandomForestRegressor

ImportError                               Traceback (most recent call last)
<ipython-input-67-89db614d07d0> in <module>()
----> 1 from sklearn.ensemble import RandomForestRegressor

3 frames
/usr/local/lib/python3.7/dist-packages/sklearn/tree/_classes.py in <module>()
     39 from ..utils.validation import check_is_fitted
     40 
---> 41 from ._criterion import Criterion
     42 from ._splitter import Splitter
     43 from ._tree import DepthFirstTreeBuilder

sklearn/tree/_criterion.pyx in init sklearn.tree._criterion()

cython_special.pyx in init scipy.special.cython_special()

ImportError: scipy.special._ufuncs_cxx does not export expected C variable _export_expit

---------------------------------------------------------------------------

    标签: python


    【解决方案1】:

    大哥: 我花了很多时间来实现这个问题。我告诉你,pip install scipy == 1.4.1。

    【讨论】:

      猜你喜欢
      • 2020-11-28
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2020-11-09
      • 2019-10-06
      • 1970-01-01
      • 2021-11-08
      • 2015-07-22
      相关资源
      最近更新 更多