[已解决]报错:XGBoostError: XGBoost Library (libxgboost.dylib) could not be loaded.

在jupyter notebook上安装xgboost
pip install xgboost

安装完成后运行 import xgboost 发生报错

报错内容如下:

XGBoostError: XGBoost Library (libxgboost.dylib) could not be loaded.

解决方法如下:

首先在终端删除xgboost

conda remove xgboost

然后重新安装

conda install py-xgboost

最后检查安装

import xgboost

posted @ 2020-09-27 15:39  hank-li  阅读(4527)  评论(0编辑  收藏  举报