【发布时间】:2015-06-26 11:06:54
【问题描述】:
我已经使用 scikit-learn 安装了 Anaconda Python 发行版。 导入 RandomForestClassifier 时:
from sklearn.ensemble import RandomForestClassifier
我有以下错误:
File "C:\Anaconda\lib\site-packages\sklearn\tree\tree.py", line 36, in <module>
from . import _tree
ImportError: cannot import name _tree
可能有什么问题?
【问题讨论】:
-
试试这个:运行
python -m site并确保除了 Anaconda 之外没有其他 Python 环境处于活动状态。
标签: python scikit-learn random-forest