R中的MXNet包安装

时间:2017-05-09 14:23:56

标签: r package mxnet

尝试在R中安装 MXNet 软件包时遇到了很多麻烦 我使用的是3.4.0版本的R,我使用的是Windows 10 CPU intel i3,64位x64处理器。

我收到提示:

install.packages("mxnet")
Warning in install.packages :
  cannot open URL 'http://www.stats.ox.ac.uk/pub/RWin/src/contrib/PACKAGES.rds': HTTP status was '404 Not Found'
Installing package into ‘C:/Users/los40/OneDrive/Documentos/R/win-library/3.4’
(as ‘lib’ is unspecified)
Warning in install.packages :
  package ‘mxnet’ is not available (for R version 3.4.0)
Warning in install.packages :
  cannot open URL 'http://www.stats.ox.ac.uk/pub/RWin/bin/windows/contrib/3.4/PACKAGES.rds': HTTP status was '404 Not Found'

我已尝试下载此处提供的.rar文件。我解压缩一个并获得它所说的文件夹" R package"尝试使用以下方法安装它:

> install.packages('R.package.rar', lib='D:/mxnet',repos = NULL)
Error in install.packages : type == "both" cannot be used with 'repos = NULL'
> install.packages('R.package.rar', lib='D:/mxnet')
Warning in install.packages :
  package ‘R.package.rar’ is not available (for R version 3.4.0)

http://mxnet.io/get_started/windows_setup.html中找到的指南对我没有意义,因为我找不到在Windows上安装prebuild包的步骤中所需的文件,名为 setupenv.cmd

3 个答案:

答案 0 :(得分:16)

对于仅使用此命令的R中的mxnet软件包安装

cran <- getOption("repos")
cran["dmlc"] <- "https://s3-us-west-2.amazonaws.com/apache-mxnet/R/CRAN/"
options(repos = cran)
install.packages("mxnet",dependencies = T)
library(mxnet)

答案 1 :(得分:0)

请尝试以下行:

cran <- getOption("repos")
cran["dmlc"] <- "https://s3.amazonaws.com/mxnet-r/"
options(repos = cran)
install.packages("mxnet")

答案 2 :(得分:0)

对于Windows,如果要安装“ mxnet”。请使用以下命令:

cran <- getOption("repos")
cran["dmlc"] <- "https://s3-us-west-2.amazonaws.com/apache-mxnet/R/CRAN/"
options(repos = cran)
install.packages("mxnet",dependencies = T)
library(mxnet)