数百万次尝试后,我尝试在r 3.5.2中安装Lightgbm库。如果有人知道如何安装它?
我尝试了这些方法来安装lightgbm,但总是会发生此类错误。
1。
i.p(...)中的错误: (从警告转换)安装软件包“ C:/Users/MUHAMM~1/AppData/Local/Temp/Rtmp4EX73g/file7d81a401a17/lightgbm_2.2.3.tar.gz”的退出状态为非零 另外:警告消息: 1:在untar2(tarfile,文件,列表,exdir)中: 跳过pax全局扩展头 2:在untar2(tarfile,文件,列表,exdir)中: 跳过pax全局扩展头文件
2。
lgb.dl(commit =“ master”,编译器=“ vs”,repo =“ https://github.com/Microsoft/LightGBM”,: 找不到函数“ lgb.dl”
#1
install.packages('devtools')
packageurl <- "http://cran.r-project.org/src/contrib/Archive/lightgbm/lightgbm_3.5.2.tar.gz"
install.packages(packageurl, contriburl=NULL, type="source")
#2
download.file("https://github.com/hadley/lightgbm/archive/master.zip", destfile = "lightgbm.zip")
#3
lgb.dl(commit = "master",libdll = "C:\\xgboost\\LightGBM\\windows\\x64\\DLL\\lib_lightgbm.dll",
# repo = "https://github.com/Microsoft/LightGBM",cores = 2)
#4
lgb.dl(commit = "master", libdll = "C:\\LightGBM\\windows\\x64\\DLL\\lib_lightgbm.dll", # YOUR PRECOMPILED DLL
#repo = "https://github.com/Microsoft/LightGBM")
lgb.dl(commit =“ master”,编译器=“ vs”,repo =“ https://github.com/Microsoft/LightGBM”,: 找不到函数“ lgb.dl”
#5
lgb.dl(commit = "master", compiler = "vs", # Remove this for MinGW + GPU installation repo = "https://github.com/Microsoft/LightGBM", use_gpu = TRUE)
#6
lgb.dl(commit = "master", compiler = "vs", # Remove this for MinGW + GPU installation repo = "https://github.com/Microsoft/LightGBM",use_gpu = TRUE)
答案 0 :(得分:0)
Context mCtx = holder.mView.getContext();
startMyActivity ( mCtx , filterList.get(getAdapterPosition() ).getId() );
// method
private void startMyActivity ( Context context , long id ) {
Intent intent = new Intent( context , sample_layout.class);
intent.putExtra("foods", id );
context.startActivity(intent);
}
最初是为了简化{lgbl.dl}
的安装而创建的,因为{lightgbm}
具有难以使用的安装过程。
该软件包没有跟上LightGBM的变化,并且不再需要在Windows上安装R软件包,如此处最初提到的那样。
{lightgbm}
现在为on CRAN。运行此R代码进行安装。
{lightgbm}