java.lang.NullPointerException

JIRA | Neeraja Madabhushi | 1 year ago
  1. 0

    Failed tests : runit_GBM_one_node.R, runit_RF_one_node.R Terminated list: runit_v_3_apply.R, runit_v_4_createfunctions.R ========== runit_RF_one_node.R LOG =========== R version 3.2.0 (2015-04-16) -- "Full of Ingredients" Copyright (C) 2015 The R Foundation for Statistical Computing Platform: x86_64-unknown-linux-gnu (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. > setwd(normalizePath(dirname(R.utils::commandArgs(asValues=TRUE)$"f"))) > source('../../h2o-runit.R') Loading required package: R.oo Loading required package: R.methodsS3 R.methodsS3 v1.7.0 (2015-02-19) successfully loaded. See ?R.methodsS3 for help. R.oo v1.19.0 (2015-02-27) successfully loaded. See ?R.oo for help. Attaching package: ‘R.oo’ The following objects are masked from ‘package:methods’: getClasses, getMethods The following objects are masked from ‘package:base’: attach, detach, gc, load, save R.utils v2.0.0 (2015-02-28) successfully loaded. See ?R.utils for help. Attaching package: ‘R.utils’ The following object is masked from ‘package:utils’: timestamp The following objects are masked from ‘package:base’: cat, commandArgs, getOption, inherits, isOpen, parse, warnings [2015-06-19 09:31:52] [INFO]: ============== Setting up R-Unit environment... ================ [2015-06-19 09:31:52] [INFO]: Branch: * (no branch) [2015-06-19 09:31:52] [INFO]: Hash: b6205582c9d058bf33585ebdd22e0406e50f8337 [2015-06-19 09:31:52] [INFO]: Check if H2O R wrapper package is installed [2015-06-19 09:31:52] [INFO]: Check that H2O R package matches version on server Loading required package: RCurl Loading required package: bitops Attaching package: ‘RCurl’ The following object is masked from ‘package:R.utils’: reset The following object is masked from ‘package:R.oo’: clone Loading required package: rjson Loading required package: tools Loading required package: statmod ---------------------------------------------------------------------- Your next step is to start H2O and get a connection object (named 'localH2O', for example): > localH2O = h2o.init() For H2O package documentation, ask for help: > ??h2o After starting H2O, you can use the Web UI at http://localhost:54321 For more information visit http://docs.h2o.ai ---------------------------------------------------------------------- Successfully connected to http://127.0.0.1:41014/ R is connected to H2O cluster: H2O cluster uptime: 18 minutes 41 seconds H2O cluster version: 3.1.0.99999 H2O cluster name: H2O_runit_jenkins_1836819 H2O cluster total nodes: 1 H2O cluster total memory: 3.56 GB H2O cluster total cores: 8 H2O cluster allowed cores: 8 H2O cluster healthy: TRUE [2015-06-19 09:31:53] [INFO]: Checking Package dependencies for this test. [2015-06-19 09:31:53] [INFO]: Loading RUnit and testthat and R.utils Loading required package: RUnit Loading required package: testthat Attaching package: ‘testthat’ The following object is masked from ‘package:R.oo’: equals [2015-06-19 09:31:53] [INFO]: Loading other required test packages Loading required package: glmnet Loading required package: Matrix Loaded glmnet 1.9-8 Loading required package: gbm Loading required package: survival Loading required package: lattice Loading required package: splines Loading required package: parallel Loaded gbm 2.1.1 Loading required package: ROCR Loading required package: gplots Attaching package: ‘gplots’ The following object is masked from ‘package:stats’: lowess Creating a generic function for ‘sapply’ from package ‘base’ in the global environment [INFO]: Using SEED: 1274067324 [SEED] : 1274067324 Appending REST API transactions to log file ./Rsandbox_runit_RF_one_node.R/rest.log [1] 600 > > test.one.node.drf <- function(conn) { + Log.info("Loading data and building models...") + airs.hex <- h2o.importFile(locate("smalldata/airlines/allyears2k.zip")) + + drf.mult <- h2o.randomForest(x = 1:30, y = 31, training_frame = airs.hex, + build_tree_one_node = F, seed = 1234) + drf.sing <- h2o.randomForest(x = 1:30, y = 31, training_frame = airs.hex, + build_tree_one_node = T, seed = 1234) + + Log.info("Multi Node:") + print(paste("MSE:", h2o.mse(drf.mult))) + print(paste("AUC:", h2o.auc(drf.mult))) + print(paste("R^2:", h2o.r2(drf.mult))) + Log.info("Single Node:") + print(paste("MSE:", h2o.mse(drf.sing))) + print(paste("AUC:", h2o.auc(drf.sing))) + print(paste("R^2:", h2o.r2(drf.sing))) + + Log.info("MSE, AUC, and R2 should be the same...") + print((h2o.mse(drf.sing)-h2o.mse(drf.mult))/h2o.mse(drf.mult)) + expect_equal(h2o.mse(drf.sing), h2o.mse(drf.mult), tolerance = 0.01) + expect_equal(h2o.auc(drf.sing), h2o.auc(drf.mult), tolerance = 0.01) + expect_equal(h2o.r2(drf.sing), h2o.r2(drf.mult), tolerance = 0.01) + + testEnd() + } > > doTest("Testing One Node vs Multi Node Random Forest", test.one.node.drf) [2015-06-19 09:31:56] [INFO]: ======================== Begin Test =========================== [2015-06-19 09:31:56] [INFO]: Loading data and building models... | | | 0% Got exception 'class java.lang.NullPointerException', with msg 'null' java.lang.NullPointerException at hex.tree.Score.makeModelMetrics(Score.java:61) at hex.tree.SharedTree.doScoringAndSaveModel(SharedTree.java:412) at hex.tree.drf.DRF.access$2100(DRF.java:32) at hex.tree.drf.DRF$DRFDriver.buildModel(DRF.java:190) at hex.tree.SharedTree$Driver.compute2(SharedTree.java:195) at water.H2O$H2OCountedCompleter.compute(H2O.java:698) at jsr166y.CountedCompleter.exec(CountedCompleter.java:429) at jsr166y.ForkJoinTask.doExec(ForkJoinTask.java:263) at jsr166y.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:974) at jsr166y.ForkJoinPool.runWorker(ForkJoinPool.java:1477) at jsr166y.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:104) ######## ### #### ## ## ## ## ## ## ## ## ## ## ## ###### ## ## ## ## ## ######### ## ## ## ## ## ## ## ## ## ## #### ######## [2015-06-19 09:32:31] [ERROR] : Error: Test failed: 'Testing One Node vs Multi Node Random Forest' Not expected: 'null' 1: withCallingHandlers(eval(code, new_test_environment), error = capture_calls) 2: eval(code, new_test_environment) 3: eval(expr, envir, enclos) 4: withWarnings(test(conn)) 5: withCallingHandlers(expr, warning = wHandler) 6: test(conn) 7: h2o.randomForest(x = 1:30, y = 31, training_frame = airs.hex, build_tree_one_node = T, seed = 1234) 8: .h2o.createModel(training_frame@conn, "drf", parms) 9: h2o.getFutureModel(.h2o.startModelJob(conn, algo, params)) 10: .h2o.__waitOnJob(object@conn, object@job_key) 11: tryCatch({ while (keepRunning) { myJobUrlSuffix <- paste0(.h2o.__JOBS, "/", job_key) rawResponse <- .h2o.doSafeGET(conn, urlSuffix = myJobUrlSuffix) jsonObject <- .h2o.fromJSON(rawResponse) jobs <- jsonObject$jobs if (length(jobs) > 1) { stop("Job list has more than 1 entry") } else if (length(jobs) == 0) { stop("Job list is empty") } job = jobs[[1]] status = job$status stopifnot(is.character(status)) if (status == "FAILED") { cat("\n\n") cat(job$exception) cat("\n\n") m <- strsplit(jobs[[1]]$exception, "\n")[[1]][1] m <- gsub(".*msg ", "", m) stop(m, call. = FALSE) } if (status == "CANCELLED") { stop("Job key ", job_key, " cancelled by user") } key = job$key name = key$name if (name != job_key) { message <- sprintf("Job %s not found in job list", job_key) stop(message) } if (progressBar) { progress = job$progress if (is.numeric(progress)) { setTxtProgressBar(pb, progress) } } if ((status == "CREATED") || (status == "RUNNING")) { } else { stopifnot(status == "DONE") keepRunning <- FALSE } if (keepRunning) { Sys.sleep(pollInterval) } else { if (progressBar) { close(pb) } } } }, interrupt = function(x) { url.suf <- paste0(.h2o.__JOBS, "/", job_key, "/cancel") .h2o.doSafePOST(conn, urlSuffix = url.suf) message(paste0("\nJob ", job_key, " was cancelled.\n")) return() }) 12: tryCatchList(expr, classes, parentenv, handlers) 13: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 14: doTryCatch(return(expr), name, parentenv, handler) 15: stop(m, call. = FALSE) 16: .handleSimpleError(function (e) { e$calls <- head(sys.calls()[-seq_len(frame + 7)], -2) signalCondition(e) }, "'null'", quote(NULL)). SEED used: 1274067324 [2015-06-19 09:32:31] [ERROR] : TEST FAILED No traceback available

    JIRA | 1 year ago | Neeraja Madabhushi
    java.lang.NullPointerException
  2. 0

    Failed tests : runit_GBM_one_node.R, runit_RF_one_node.R Terminated list: runit_v_3_apply.R, runit_v_4_createfunctions.R ========== runit_RF_one_node.R LOG =========== R version 3.2.0 (2015-04-16) -- "Full of Ingredients" Copyright (C) 2015 The R Foundation for Statistical Computing Platform: x86_64-unknown-linux-gnu (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. > setwd(normalizePath(dirname(R.utils::commandArgs(asValues=TRUE)$"f"))) > source('../../h2o-runit.R') Loading required package: R.oo Loading required package: R.methodsS3 R.methodsS3 v1.7.0 (2015-02-19) successfully loaded. See ?R.methodsS3 for help. R.oo v1.19.0 (2015-02-27) successfully loaded. See ?R.oo for help. Attaching package: ‘R.oo’ The following objects are masked from ‘package:methods’: getClasses, getMethods The following objects are masked from ‘package:base’: attach, detach, gc, load, save R.utils v2.0.0 (2015-02-28) successfully loaded. See ?R.utils for help. Attaching package: ‘R.utils’ The following object is masked from ‘package:utils’: timestamp The following objects are masked from ‘package:base’: cat, commandArgs, getOption, inherits, isOpen, parse, warnings [2015-06-19 09:31:52] [INFO]: ============== Setting up R-Unit environment... ================ [2015-06-19 09:31:52] [INFO]: Branch: * (no branch) [2015-06-19 09:31:52] [INFO]: Hash: b6205582c9d058bf33585ebdd22e0406e50f8337 [2015-06-19 09:31:52] [INFO]: Check if H2O R wrapper package is installed [2015-06-19 09:31:52] [INFO]: Check that H2O R package matches version on server Loading required package: RCurl Loading required package: bitops Attaching package: ‘RCurl’ The following object is masked from ‘package:R.utils’: reset The following object is masked from ‘package:R.oo’: clone Loading required package: rjson Loading required package: tools Loading required package: statmod ---------------------------------------------------------------------- Your next step is to start H2O and get a connection object (named 'localH2O', for example): > localH2O = h2o.init() For H2O package documentation, ask for help: > ??h2o After starting H2O, you can use the Web UI at http://localhost:54321 For more information visit http://docs.h2o.ai ---------------------------------------------------------------------- Successfully connected to http://127.0.0.1:41014/ R is connected to H2O cluster: H2O cluster uptime: 18 minutes 41 seconds H2O cluster version: 3.1.0.99999 H2O cluster name: H2O_runit_jenkins_1836819 H2O cluster total nodes: 1 H2O cluster total memory: 3.56 GB H2O cluster total cores: 8 H2O cluster allowed cores: 8 H2O cluster healthy: TRUE [2015-06-19 09:31:53] [INFO]: Checking Package dependencies for this test. [2015-06-19 09:31:53] [INFO]: Loading RUnit and testthat and R.utils Loading required package: RUnit Loading required package: testthat Attaching package: ‘testthat’ The following object is masked from ‘package:R.oo’: equals [2015-06-19 09:31:53] [INFO]: Loading other required test packages Loading required package: glmnet Loading required package: Matrix Loaded glmnet 1.9-8 Loading required package: gbm Loading required package: survival Loading required package: lattice Loading required package: splines Loading required package: parallel Loaded gbm 2.1.1 Loading required package: ROCR Loading required package: gplots Attaching package: ‘gplots’ The following object is masked from ‘package:stats’: lowess Creating a generic function for ‘sapply’ from package ‘base’ in the global environment [INFO]: Using SEED: 1274067324 [SEED] : 1274067324 Appending REST API transactions to log file ./Rsandbox_runit_RF_one_node.R/rest.log [1] 600 > > test.one.node.drf <- function(conn) { + Log.info("Loading data and building models...") + airs.hex <- h2o.importFile(locate("smalldata/airlines/allyears2k.zip")) + + drf.mult <- h2o.randomForest(x = 1:30, y = 31, training_frame = airs.hex, + build_tree_one_node = F, seed = 1234) + drf.sing <- h2o.randomForest(x = 1:30, y = 31, training_frame = airs.hex, + build_tree_one_node = T, seed = 1234) + + Log.info("Multi Node:") + print(paste("MSE:", h2o.mse(drf.mult))) + print(paste("AUC:", h2o.auc(drf.mult))) + print(paste("R^2:", h2o.r2(drf.mult))) + Log.info("Single Node:") + print(paste("MSE:", h2o.mse(drf.sing))) + print(paste("AUC:", h2o.auc(drf.sing))) + print(paste("R^2:", h2o.r2(drf.sing))) + + Log.info("MSE, AUC, and R2 should be the same...") + print((h2o.mse(drf.sing)-h2o.mse(drf.mult))/h2o.mse(drf.mult)) + expect_equal(h2o.mse(drf.sing), h2o.mse(drf.mult), tolerance = 0.01) + expect_equal(h2o.auc(drf.sing), h2o.auc(drf.mult), tolerance = 0.01) + expect_equal(h2o.r2(drf.sing), h2o.r2(drf.mult), tolerance = 0.01) + + testEnd() + } > > doTest("Testing One Node vs Multi Node Random Forest", test.one.node.drf) [2015-06-19 09:31:56] [INFO]: ======================== Begin Test =========================== [2015-06-19 09:31:56] [INFO]: Loading data and building models... | | | 0% Got exception 'class java.lang.NullPointerException', with msg 'null' java.lang.NullPointerException at hex.tree.Score.makeModelMetrics(Score.java:61) at hex.tree.SharedTree.doScoringAndSaveModel(SharedTree.java:412) at hex.tree.drf.DRF.access$2100(DRF.java:32) at hex.tree.drf.DRF$DRFDriver.buildModel(DRF.java:190) at hex.tree.SharedTree$Driver.compute2(SharedTree.java:195) at water.H2O$H2OCountedCompleter.compute(H2O.java:698) at jsr166y.CountedCompleter.exec(CountedCompleter.java:429) at jsr166y.ForkJoinTask.doExec(ForkJoinTask.java:263) at jsr166y.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:974) at jsr166y.ForkJoinPool.runWorker(ForkJoinPool.java:1477) at jsr166y.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:104) ######## ### #### ## ## ## ## ## ## ## ## ## ## ## ###### ## ## ## ## ## ######### ## ## ## ## ## ## ## ## ## ## #### ######## [2015-06-19 09:32:31] [ERROR] : Error: Test failed: 'Testing One Node vs Multi Node Random Forest' Not expected: 'null' 1: withCallingHandlers(eval(code, new_test_environment), error = capture_calls) 2: eval(code, new_test_environment) 3: eval(expr, envir, enclos) 4: withWarnings(test(conn)) 5: withCallingHandlers(expr, warning = wHandler) 6: test(conn) 7: h2o.randomForest(x = 1:30, y = 31, training_frame = airs.hex, build_tree_one_node = T, seed = 1234) 8: .h2o.createModel(training_frame@conn, "drf", parms) 9: h2o.getFutureModel(.h2o.startModelJob(conn, algo, params)) 10: .h2o.__waitOnJob(object@conn, object@job_key) 11: tryCatch({ while (keepRunning) { myJobUrlSuffix <- paste0(.h2o.__JOBS, "/", job_key) rawResponse <- .h2o.doSafeGET(conn, urlSuffix = myJobUrlSuffix) jsonObject <- .h2o.fromJSON(rawResponse) jobs <- jsonObject$jobs if (length(jobs) > 1) { stop("Job list has more than 1 entry") } else if (length(jobs) == 0) { stop("Job list is empty") } job = jobs[[1]] status = job$status stopifnot(is.character(status)) if (status == "FAILED") { cat("\n\n") cat(job$exception) cat("\n\n") m <- strsplit(jobs[[1]]$exception, "\n")[[1]][1] m <- gsub(".*msg ", "", m) stop(m, call. = FALSE) } if (status == "CANCELLED") { stop("Job key ", job_key, " cancelled by user") } key = job$key name = key$name if (name != job_key) { message <- sprintf("Job %s not found in job list", job_key) stop(message) } if (progressBar) { progress = job$progress if (is.numeric(progress)) { setTxtProgressBar(pb, progress) } } if ((status == "CREATED") || (status == "RUNNING")) { } else { stopifnot(status == "DONE") keepRunning <- FALSE } if (keepRunning) { Sys.sleep(pollInterval) } else { if (progressBar) { close(pb) } } } }, interrupt = function(x) { url.suf <- paste0(.h2o.__JOBS, "/", job_key, "/cancel") .h2o.doSafePOST(conn, urlSuffix = url.suf) message(paste0("\nJob ", job_key, " was cancelled.\n")) return() }) 12: tryCatchList(expr, classes, parentenv, handlers) 13: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 14: doTryCatch(return(expr), name, parentenv, handler) 15: stop(m, call. = FALSE) 16: .handleSimpleError(function (e) { e$calls <- head(sys.calls()[-seq_len(frame + 7)], -2) signalCondition(e) }, "'null'", quote(NULL)). SEED used: 1274067324 [2015-06-19 09:32:31] [ERROR] : TEST FAILED No traceback available

    JIRA | 1 year ago | Neeraja Madabhushi
    java.lang.NullPointerException
  3. 0

    Android: Saving Map State in Google map

    Stack Overflow | 11 months ago | Junie Negentien
    java.lang.RuntimeException: Unable to resume activity {com.ourThesis.junieNegentien2015/com.ourThesis.junieNegentien2015.MainActivity}: java.lang.NullPointerException
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. java.lang.NullPointerException

      No message provided

      at hex.tree.Score.makeModelMetrics()
    2. hex.tree
      SharedTree.doScoringAndSaveModel
      1. hex.tree.Score.makeModelMetrics(Score.java:61)
      2. hex.tree.SharedTree.doScoringAndSaveModel(SharedTree.java:412)
      2 frames
    3. hex.tree.drf
      DRF$DRFDriver.buildModel
      1. hex.tree.drf.DRF.access$2100(DRF.java:32)
      2. hex.tree.drf.DRF$DRFDriver.buildModel(DRF.java:190)
      2 frames
    4. hex.tree
      SharedTree$Driver.compute2
      1. hex.tree.SharedTree$Driver.compute2(SharedTree.java:195)
      1 frame
    5. water
      H2O$H2OCountedCompleter.compute
      1. water.H2O$H2OCountedCompleter.compute(H2O.java:698)
      1 frame
    6. jsr166y
      ForkJoinWorkerThread.run
      1. jsr166y.CountedCompleter.exec(CountedCompleter.java:429)
      2. jsr166y.ForkJoinTask.doExec(ForkJoinTask.java:263)
      3. jsr166y.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:974)
      4. jsr166y.ForkJoinPool.runWorker(ForkJoinPool.java:1477)
      5. jsr166y.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:104)
      5 frames