美文网首页机器学习
LightGBM安装问题

LightGBM安装问题

作者: 只为此心无垠 | 来源:发表于2018-06-28 17:26 被阅读29次

第一步:安装brew(如果电脑已经有brew可略过)

在终端输入:

/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" 

第二步:用brew 安装cmake

brew install cmake
brew install gcc --without-multilib 

第三部:配置

git clone --recursive https://github.com/Microsoft/LightGBM ; cd LightGBM  
export CXX=g++-7 CC=gcc-7  
cmake ..  
make -j4

最后:用pip安装

pip install lightgbm

会出现一个问题:

在第三部会出现问题:Could not find compiler set in environment variable CC: gcc-7

git clone --recursive https://github.com/Microsoft/LightGBM ; cd LightGBM
export CXX=g++-8 CC=gcc-8
mkdir build ; cd build
cmake ..
make -j4

相关文章

网友评论

    本文标题:LightGBM安装问题

    本文链接:https://www.haomeiwen.com/subject/lmhnyftx.html