apache / mxnet

Lightweight, Portable, Flexible Distributed/Mobile Deep Learning with Dynamic, Mutation-aware Dataflow Dep Scheduler; for Python, R, Julia, Scala, Go, Javascript and more
https://mxnet.apache.org
Apache License 2.0
20.78k stars 6.79k forks source link

No mxnet binaries on CRAN for R v4.0.1 #18774

Open niranjannilekani opened 4 years ago

niranjannilekani commented 4 years ago

Description

Iam unable to install mxnet package in R 4.0.1

Error Message

package ‘mxnet’ was installed before R 4.0.0: please re-install it

To Reproduce

(If you developed your own code, please provide a short script that reproduces the error. For existing examples, please provide link.)

Steps to reproduce

(Paste the commands you ran that produced the error.)

1. 2.

What have you tried to solve it?

Environment

We recommend using our script for collecting the diagnositc information. Run the following command and paste the outputs below:

curl --retry 10 -s https://raw.githubusercontent.com/dmlc/gluon-nlp/master/tools/diagnose.py | python

# paste outputs here
szha commented 4 years ago

@niranjannilekani thanks for reporting. @hetong007 could you help on this?

hetong007 commented 4 years ago

@niranjannilekani could you share more with us about:

  1. The commands you run that eventually lead to the error message
  2. The result of executing sessionInfo() in your R console
niranjannilekani commented 4 years ago

cran <- getOption("repos") cran["dmlc"] <- "https://apache-mxnet.s3-accelerate.dualstack.amazonaws.com/R/CRAN/GPU" options(repos = cran) install.packages("mxnet") Warning in install.packages : unable to access index for repository https://apache-mxnet.s3-accelerate.dualstack.amazonaws.com/R/CRAN/GPU/src/contrib: cannot open URL 'https://apache-mxnet.s3-accelerate.dualstack.amazonaws.com/R/CRAN/GPU/src/contrib/PACKAGES' Installing package into ‘C:/Users/niranjan.nilekani/Documents/R/win-library/4.0’ (as ‘lib’ is unspecified) Warning in install.packages : unable to access index for repository https://apache-mxnet.s3-accelerate.dualstack.amazonaws.com/R/CRAN/GPU/src/contrib: cannot open URL 'https://apache-mxnet.s3-accelerate.dualstack.amazonaws.com/R/CRAN/GPU/src/contrib/PACKAGES' Warning in install.packages : package ‘mxnet’ is not available (for R version 4.0.2) Warning in install.packages : unable to access index for repository https://apache-mxnet.s3-accelerate.dualstack.amazonaws.com/R/CRAN/GPU/bin/windows/contrib/4.0: cannot open URL 'https://apache-mxnet.s3-accelerate.dualstack.amazonaws.com/R/CRAN/GPU/bin/windows/contrib/4.0/PACKAGES'

niranjannilekani commented 4 years ago

install.packages("https://s3.ca-central-1.amazonaws.com/jeremiedb/share/mxnet/GPU/mxnet.zip", repos = NULL) Installing package into ‘C:/Users/niranjan.nilekani/Documents/R/win-library/4.0’ (as ‘lib’ is unspecified) trying URL 'https://s3.ca-central-1.amazonaws.com/jeremiedb/share/mxnet/GPU/mxnet.zip' Content type 'application/zip' length 348148417 bytes (332.0 MB) downloaded 332.0 MB

library(mxnet) Error: package or namespace load failed for ‘mxnet’: package ‘mxnet’ was installed before R 4.0.0: please re-install it

niranjannilekani commented 4 years ago

cran <- getOption("repos") cran["dmlc"] <- "https://apache-mxnet.s3-accelerate.dualstack.amazonaws.com/R/CRAN/" options(repos = cran) install.packages("mxnet") Installing package into ‘C:/Users/niranjan.nilekani/Documents/R/win-library/4.0’ (as ‘lib’ is unspecified) Warning in install.packages : unable to access index for repository https://apache-mxnet.s3-accelerate.dualstack.amazonaws.com/R/CRAN/bin/windows/contrib/4.0: cannot open URL 'https://apache-mxnet.s3-accelerate.dualstack.amazonaws.com/R/CRAN/bin/windows/contrib/4.0/PACKAGES' installing the source package ‘mxnet’

trying URL 'https://apache-mxnet.s3-accelerate.dualstack.amazonaws.com/R/CRAN/src/contrib/mxnet_1.3.0.tar.gz' Warning in install.packages : cannot open URL 'https://apache-mxnet.s3-accelerate.dualstack.amazonaws.com/R/CRAN/src/contrib/mxnet_1.3.0.tar.gz': HTTP status was '404 Not Found' Error in download.file(url, destfile, method, mode = "wb", ...) : cannot open URL 'https://apache-mxnet.s3-accelerate.dualstack.amazonaws.com/R/CRAN/src/contrib/mxnet_1.3.0.tar.gz' Warning in install.packages : download of package ‘mxnet’ failed

library("mxnet", lib.loc="C:/Users/niranjan.nilekani/R-3.6.0/mxnet.zip") Error in library("mxnet", lib.loc = "C:/Users/niranjan.nilekani/R-3.6.0/mxnet.zip") : no library trees found in 'lib.loc' library(mxnet) Error: package or namespace load failed for ‘mxnet’: package ‘mxnet’ was installed before R 4.0.0: please re-install it

niranjannilekani commented 4 years ago

sessionInfo() R version 4.0.2 (2020-06-22) Platform: x86_64-w64-mingw32/x64 (64-bit) Running under: Windows 10 x64 (build 18363)

Matrix products: default

Random number generation: RNG: Mersenne-Twister Normal: Inversion Sample: Rounding

locale: [1] LC_COLLATE=English_United States.1252 LC_CTYPE=English_United States.1252
[3] LC_MONETARY=English_United States.1252 LC_NUMERIC=C
[5] LC_TIME=English_United States.1252

attached base packages: [1] stats graphics grDevices utils datasets methods base

loaded via a namespace (and not attached): [1] compiler_4.0.2 Matrix_1.2-18 tools_4.0.2 survival_3.1-12 splines_4.0.2 grid_4.0.2 lattice_0.20-41

niranjannilekani commented 4 years ago

i tried running all possible solutions available, but not able to install mxnet. Kindly help

niranjannilekani commented 4 years ago

@niranjannilekani thanks for reporting. @hetong007 could you help on this?

Hello any update on this? Kindly help me

niranjannilekani commented 4 years ago

@niranjannilekani could you share more with us about:

  1. The commands you run that eventually lead to the error message
  2. The result of executing sessionInfo() in your R console

Hello any update on this? Kindly help me

leezu commented 4 years ago

As the error message mentions, there is no binary CRAN package ‘mxnet’ is available for R version 4.0.2. You can compile from source following the instructions: https://github.com/apache/incubator-mxnet/blob/v1.x/docs/static_site/src/pages/get_started/ubuntu_setup.md

cc @ys2843 @sandeep-krishnamurthy the instructions are missing on https://mxnet.apache.org/versions/1.6/get_started/build_from_source.html

niranjannilekani commented 4 years ago

Hi Leezu, where should i run below commands?? Please guide me...iam struggling hard to get mxnet installed sudo apt-get update sudo apt-get install -y r-base-core r-cran-devtools libcairo2-dev libxml2-dev

leezu commented 4 years ago

As you're on Windows, you need to follow the Windows guide instead of the Linux guide. Please see https://github.com/apache/incubator-mxnet/blob/v1.x/docs/static_site/src/pages/get_started/windows_setup.md Sorry that I linked the wrong guide for your case before.

niranjannilekani commented 4 years ago

Hi Leezu

i tried to install using pre built binary package CPU, but iam getting error as shown below.

R version 4.0.2 (2020-06-22) -- "Taking Off Again" Copyright (C) 2020 The R Foundation for Statistical Computing Platform: x86_64-w64-mingw32/x64 (64-bit)

R is free software and comes with ABSOLUTELY NO WARRANTY. You are welcome to redistribute it under certain conditions. Type 'license()' or 'licence()' for distribution details.

Natural language support but running in an English locale

R is a collaborative project with many contributors. Type 'contributors()' for more information and 'citation()' on how to cite R or R packages in publications.

Type 'demo()' for some demos, 'help()' for on-line help, or 'help.start()' for an HTML browser interface to help. Type 'q()' to quit R.

[Workspace loaded from ~/.RData]

cran <- getOption("repos") cran["dmlc"] <- "https://apache-mxnet.s3-accelerate.dualstack.amazonaws.com/R/CRAN/" options(repos = cran) install.packages("mxnet") WARNING: Rtools is required to build R packages but is not currently installed. Please download and install the appropriate version of Rtools before proceeding:

https://cran.rstudio.com/bin/windows/Rtools/ Installing package into ‘C:/Users/niranjan.nilekani/Documents/R/win-library/4.0’ (as ‘lib’ is unspecified) Warning in install.packages : unable to access index for repository https://apache-mxnet.s3-accelerate.dualstack.amazonaws.com/R/CRAN/bin/windows/contrib/4.0: cannot open URL 'https://apache-mxnet.s3-accelerate.dualstack.amazonaws.com/R/CRAN/bin/windows/contrib/4.0/PACKAGES' installing the source package ‘mxnet’

trying URL 'https://apache-mxnet.s3-accelerate.dualstack.amazonaws.com/R/CRAN/src/contrib/mxnet_1.3.0.tar.gz' Warning in install.packages : cannot open URL 'https://apache-mxnet.s3-accelerate.dualstack.amazonaws.com/R/CRAN/src/contrib/mxnet_1.3.0.tar.gz': HTTP status was '404 Not Found' Error in download.file(url, destfile, method, mode = "wb", ...) : cannot open URL 'https://apache-mxnet.s3-accelerate.dualstack.amazonaws.com/R/CRAN/src/contrib/mxnet_1.3.0.tar.gz' Warning in install.packages : download of package ‘mxnet’ failed

niranjannilekani commented 4 years ago

the link given in dmlc gives error, see below

This XML file does not appear to have any style information associated with it. The document tree is shown below.

NoSuchKey The specified key does not exist. R/CRAN/ A3993535E1D9E0C4 0B6k+WtkHSwfxQYiW3MJx+zVcagJQWgSdlPNz04UIRsdu5AaB5djyEWphIHtGA6YE552n5I8CPA=
niranjannilekani commented 4 years ago

please help

sandeep-krishnamurthy commented 4 years ago

@hetong007 can you please help with this issue with a recommendation?

hetong007 commented 4 years ago

@niranjannilekani Since you have a new R version, Building MXNet-R from Source Code(CPU) is what you should go for. Please follow it strictly and ping me here if stucked.

Some additional points:

appropiate commented 3 years ago

Is there any info on whether there will be mxnet binaries on CRAN for R v4.0 in the near future?

JaimeGoB commented 3 years ago

@appropiate were you able to install mxnet? I am facing the same issues as you. I cannot install mxnet, no matter what I do. I am running R 4.0.1 on MAC.

vikram-rawat commented 3 years ago

I have the same problem. mxNet is not available for R 4.0.2. Please look into it.

waynelapierre commented 3 years ago

any update?

leezu commented 3 years ago

Please use https://cran.r-project.org/web/packages/reticulate/vignettes/calling_python.html + the MXNet Python package

JaimeGoB commented 3 years ago

@leezu can you please give an example(code) on how to load mxNet with R 4.0.2, with the link you just gave use?

leezu commented 3 years ago

@JaimeGoB sorry, I'm not an R user so I'm not too familiar with this setup. But you can google for a tutorial about how to use Python packages from R. After you installed the MXNet Python package pip install mxnet, any such tutorial would apply. If you can comment here with the steps you took, that may help future users