Skip to content

Commit

Permalink
update the initialization of h2o
Browse files Browse the repository at this point in the history
  • Loading branch information
spennihana committed Aug 5, 2014
1 parent ce93c68 commit 8ae399b
Showing 1 changed file with 12 additions and 12 deletions.
24 changes: 12 additions & 12 deletions h2o-perf/bench/R/h2oPerf/prologue.R
Original file line number Diff line number Diff line change
Expand Up @@ -157,18 +157,18 @@ function(optional = FALSE) {

.h2oSetup<-
function() {
if (!"h2o" %in% rownames(installed.packages())) {
envPath <- Sys.getenv("H2OWrapperDir")
wrapDir <- ifelse(envPath == "", defaultPath, envPath)
wrapName <- list.files(wrapDir, pattern = "h2o")[1]
wrapPath <- paste(wrapDir, wrapName, sep = "/")

if (!file.exists(wrapPath))
stop(paste("h2o package does not exist at", wrapPath));
print(paste("Installing h2o package from", wrapPath))
.installDepPkgs()
install.packages(wrapPath, repos = NULL, type = "source")
}
# if (!"h2o" %in% rownames(installed.packages())) {
# envPath <- Sys.getenv("H2OWrapperDir")
# wrapDir <- ifelse(envPath == "", defaultPath, envPath)
# wrapName <- list.files(wrapDir, pattern = "h2o")[1]
# wrapPath <- paste(wrapDir, wrapName, sep = "/")
#
# if (!file.exists(wrapPath))
# stop(paste("h2o package does not exist at", wrapPath));
# print(paste("Installing h2o package from", wrapPath))
# .installDepPkgs()
# install.packages(wrapPath, repos = NULL, type = "source")
# }

.installDepPkgs()
library(h2o)
Expand Down

0 comments on commit 8ae399b

Please sign in to comment.