2017-05-27 150 views
0

我有依赖R包h2o版本3.10.0.6的模型。在一个新的机器,我尝试从源文件h2o_3.10.0.6.tar.gz安装,h2o以前的版本安装错误,说h2o.jar下载失败

install.packages("h2o_3.10.0.6.tar.gz", repos=NULL, type="source") 

10分钟后,它又回来了这项申诉,

Performing one-time download of h2o.jar from 
http://s3.amazonaws.com/h2o-release/h2o/rel-turing/6/Rjar/h2o.jar 
(This could take a few minutes, please be patient...) 
Warning in download.file(url = h2o_url, destfile = temp_file, mode = "wb", : 
    downloaded length 60135652 != reported length 62422402 
Warning in download.file(url = h2o_url, destfile = temp_file, mode = "wb", : 
    URL 'http://s3.amazonaws.com/h2o-release/h2o/rel-turing/6/Rjar/h2o.jar': status was 'Failure when receiving data from the peer' 
Error in download.file(url = h2o_url, destfile = temp_file, mode = "wb", : 
    download from 'http://s3.amazonaws.com/h2o-release/h2o/rel-turing/6/Rjar/h2o.jar' failed 

我知道这是一个老版本,所以JVM可能有已被删除。但是h2o的人可能会离开旧的JVM,所以像我这样的人仍然可以使用以前的版本。

回答

1

我无法复制您的错误。我刚刚从CRAN档案库下载了h2o_3.10.0.6.tar.gz文件,并且能够正确安装它,所以它似乎必须是您的端网络连接问题。刚才这样做:

> install.packages("h2o_3.10.0.6.tar.gz", repos=NULL, type="source") 
* installing *source* package ‘h2o’ ... 
** package ‘h2o’ successfully unpacked and MD5 sums checked 
** R 
** demo 
** inst 
** preparing package for lazy loading 
Performing one-time download of h2o.jar from 
    http://s3.amazonaws.com/h2o-release/h2o/rel-turing/6/Rjar/h2o.jar 
(This could take a few minutes, please be patient...) 
** help 
*** installing help indices 
** building package indices 
** testing if installed package can be loaded 
* DONE (h2o) 

还有一些其他的方法来重新安装旧版本的H2O [R包。如果是CRAN发行版,您可以使用版本包安装任何旧版本CRAN软件包:

install.packages("versions") 
install.versions("h2o", versions = "3.10.0.6") 

H2O的任何稳定的版本可以下载从它的发布页面。该3.10.0.6发布页面here,如果你点击“安装在R”选项卡上,它会告诉你的命令来自R安装该版本的H2O:

install.packages("h2o", type="source", repos=(c("https://h2o-release.s3.amazonaws.com/h2o/rel-turing/6/R"))) 
+1

你的建议的工作。不知道为什么我没有,但问题解决了,谢谢。 – horaceT

相关问题