Running 'testthat.R' [1s/1s]
Running the tests in 'tests/testthat.R' failed.
Complete output:
  > library(testthat)
  > library(IGP)
  
  Initialize Python Version 2.7.16 (default, Mar  4 2019, 15:29:09) 
  [GCC 8.3.0]
  
  > 
  > test_check("IGP")
  [1] "laGP"
  [1] "mlegp"
  -- 1. Error: 1D data works (@test_IGP.R#11)  -----------------------------------
  BLAS/LAPACK routine 'DPPTRS' gave error code -1
  1: IGP(package = package, X = X1, Z = Z1) at testthat/test_IGP.R:11
  2: IGP_mlegp$new(X = X, Z = Z, ...)
  3: .subset2(public_bind_env, "initialize")(...)
  4: self$init(...)
  5: self$.init(...)
  6: capture.output(m <- do.call(mlegp::mlegp, argss))
  7: evalVis(expr)
  8: withVisible(eval(expr, pf))
  9: eval(expr, pf)
  10: eval(expr, pf)
  11: do.call(mlegp::mlegp, argss)
  12: (function (X, Z, constantMean = 1, nugget = NULL, nugget.known = 0, min.nugget = 0, 
         param.names = NULL, gp.names = NULL, PC.UD = NULL, PC.num = NULL, PC.percent = NULL, 
         simplex.ntries = 5, simplex.maxiter = 500, simplex.reltol = 1e-08, BFGS.maxiter = 500, 
         BFGS.tol = 0.01, BFGS.h = 1e-10, seed = 0, verbose = 1, parallel = FALSE) 
     {
         X = as.matrix(X)
         orig.X = X
         Z = as.matrix(Z)
         reps = NULL
         un.sum = NULL
         if (nrow(X) == 1) {
             stop("error: there must be at least two input values")
         }
         if (!is.null(param.names) && length(param.names) != dim(X)[2]) {
             stop("length of param.names must match number of columns of X")
         }
         if (!is.null(PC.percent)) 
             PC.num = numSingularValues(Z, PC.percent)
         if (!is.null(PC.num)) {
             weights = pcweights(Z, weights.num = PC.num)
             Z = t(weights$Vprime)
             if (PC.num == 1) {
                 stop("error: currently not implemented for PC.num = 1 (set PC.num directly)")
             }
             PC.UD = weights$UD
         }
         if (!is.null(dim(Z))) {
             numGPs = dim(Z)[2]
         }
         else {
             numGPs = 1
             Z = matrix(Z)
         }
         if (length(seed) != 1 && length(seed) != ncol(Z)) {
             stop("error: seed length must equal dimensions of Z, or 1")
         }
         if (is.null(gp.names)) {
             gp.names = paste("gp #", 1:numGPs)
         }
         if (length(gp.names) != numGPs) {
             stop("length of gp.names must match number of GPs")
         }
         if (dim(X)[1] != dim(Z)[1]) {
             stop("error: X matrix and output matrix must have same number of rows; \n\tfor PC weights, make sure each column of Z is a computer model run")
         }
         if (min(diag(var(Z))) <= 0) {
             stop("error: Z does not vary for at least one column")
         }
         if (dim(Z)[2] > 1 && !is.null(nugget) && length(nugget) > 1) {
             stop("error: cannot handle nugget matrix with multiple field observations; try fitting 1 gp at a time")
         }
         if (!is.null(nugget) && length(nugget) > dim(Z)[1]) {
             stop("length of nugget matrix must match number of observations")
         }
         if (min(apply(X, 2, max) - apply(X, 2, min)) == 0) {
             stop("error: at least one parameter does not vary in design")
         }
         if (constantMean != 1) {
             ones = rep(1, dim(X)[1])
             dX = cbind(ones, X)
             t = try(solve(t(dX) %*% dX), TRUE)
             if (class(t) == "try-error") {
                 stop("error: design matrix with intercept is not full rank; set constantMean = 1")
             }
         }
         if (nugget.known == 1) {
             if (!is.null(nugget) && length(nugget) > 1 && length(nugget) != nrow(X)) {
                 stop("error: for nugget.known = 1, length of nugget matrix must be nrow(X) or 1")
             }
             un.sum = uniqueSummary(X, Z)
             orig.X = X
             X = un.sum$uniqueX
             Z = un.sum$uniqueMeans
             reps = un.sum$reps
         }
         if (!is.null(nugget) && length(nugget) == 1 && nugget <= 0) {
             if (anyReps(X)) 
                 stop("at least 2 or more inputs are identical...must use nugget!")
         }
         if (is.null(nugget)) {
             if (!anyReps(X)) {
                 if (verbose > 0) 
                     cat("no reps detected - nugget will not be estimated\n")
             }
             else {
                 if (verbose > 0 && nugget.known == 0) 
                     cat("reps detected - nugget will be estimated\n")
             }
         }
         numEstimates = dim(X)[2] + 1
         if (anyReps(X) || !is.null(nugget) || length(nugget) > 1) 
             numEstimates = numEstimates + 1
         if (constantMean == 1) {
             numEstimates = numEstimates + 1
         }
         else {
             numEstimates = numEstimates + dim(X)[2] + 1
         }
         estimates = rep(0, numEstimates)
         if (verbose > 0) 
             cat("\n")
         l = NULL
         Zlist = list()
         if (length(seed) == 1) 
             seed = rep(seed, ncol(Z))
         for (i in 1:ncol(Z)) {
             Zlist[[i]] = list()
             Zlist[[i]]$Z = matrix(Z[, i])
             Zlist[[i]]$i = i
             Zlist[[i]]$seed = seed[i]
         }
         if (!parallel) {
             l = lapply(Zlist, mlegp2, XX = X, orig.XX = orig.X, nugget = nugget, nugget.known = nugget.known, 
                 reps = reps, un.sum = un.sum, numEstimates = numEstimates, constantMean = constantMean, 
                 simplex.ntries = simplex.ntries, simplex.maxiter = simplex.maxiter, simplex.reltol = simplex.reltol, 
                 BFGS.maxiter = BFGS.maxiter, BFGS.tol = BFGS.tol, BFGS.h = BFGS.h, min.nugget = min.nugget, 
                 verbose = verbose, param.names = param.names)
         }
         if (parallel) {
             if (requireNamespace("snowfall", quietly = TRUE)) {
                 cat("fitting ")
                 cat(length(Zlist))
                 cat(" GPs in parallel mode...\n")
                 l = snowfall::sfLapply(Zlist, mlegp2, XX = X, orig.XX = orig.X, nugget = nugget, 
                     nugget.known = nugget.known, reps = reps, un.sum = un.sum, numEstimates = numEstimates, 
                     constantMean = constantMean, simplex.ntries = simplex.ntries, simplex.maxiter = simplex.maxiter, 
                     simplex.reltol = simplex.reltol, BFGS.maxiter = BFGS.maxiter, BFGS.tol = BFGS.tol, 
                     BFGS.h = BFGS.h, min.nugget = min.nugget, verbose = verbose, param.names = param.names)
                 cat("...done\n")
             }
             else {
                 cat("Error: the package \"snowfall\" is required when parallel = TRUE")
             }
         }
         if (numGPs == 1) {
             return(l[[1]])
         }
         return(gp.list(l, UD = PC.UD, param.names = param.names, gp.names = gp.names))
     })(X = structure(c(0.444965244038031, 0.689071608707309, 0.949970785761252, 0.313479960430413, 
     0.524009309941903, 0.918911641463637, 0.10779749811627, 0.523432375164703, 0.323164598084986, 
     0.642391991103068, 0.539085096679628, 0.643379463814199, 0.345565312774852, 0.39323182287626, 
     0.648016896564513, 0.212344998959452, 0.779509091982618, 0.143103838665411, 0.252454395405948, 
     0.855546741513535, 0.214810189325362, 0.364315679064021, 0.655942913843319, 0.183863234473392, 
     0.937780328094959, 0.694520567776635, 0.182326908921823, 0.267595262266695, 0.450197771191597, 
     0.741638603853062, 0.396525748306885, 0.983998529380187, 0.567753690760583, 0.298461664933711, 
     0.0654860003851354, 0.00661466084420681, 0.305523191811517, 0.738616759888828, 0.971062410622835, 
     0.174885828746483, 0.102847223868594, 0.211838155053556, 0.290524825453758, 0.972947504138574, 
     0.395913669141009, 0.940073811914772, 0.323087853612378, 0.571853089611977, 0.486229422269389, 
     0.161032371921465, 0.545740228379145, 0.811077271588147, 0.38625259953551, 0.372092407895252, 
     0.341591710224748, 0.86095333006233, 0.390336061827838, 0.922532302793115, 0.252385725500062, 
     0.960426599252969, 0.851171066053212, 0.575170215219259, 0.88751499610953, 0.961475529475138, 
     0.176693992922083, 0.100540133425966, 0.0466898733284324, 0.60903268144466, 0.382667799247429, 
     0.234747709706426, 0.0566577576100826, 0.787745704175904, 0.0103422845713794, 0.564280538354069, 
     0.733604051172733, 0.400836800923571, 0.59824600815773, 0.175244046840817, 0.397786116926, 
     0.742534992750734), .Dim = c(40L, 2L)), Z = c(0.941156179217861, 0.0450877389183256, 
     0.656245488800131, 0.751938541206639, 0.458455941242436, -0.856058294964424, 1.52356734413559, 
     -0.582594244964671, 0.98176443036378, 0.0665737365840687, -0.525980875020083, -1.71187099302186, 
     1.48120261850424, 1.34224226344681, 0.0395298172322295, 0.205686452322994, -0.346758040742225, 
     0.31476016516766, 1.99848374081115, -1.03540781830077, 0.170458892841255, 0.298991166454338, 
     -1.48126197220808, 0.675419873608059, 0.513600845919278, -0.34784231939251, 1.19996923269077, 
     0.360760743605319, 0.979981761271056, -0.00275063596912043, 0.952812446308196, -1.07305717411148, 
     -0.348876489945074, 0.562323081984348, -0.593811183227969, 0.624210748038998, 0.359905479989176, 
     -0.106102940709186, 0.418074863904403, -0.107847198643153), verbose = 0, nugget = 1e-08, 
         nugget.known = 1e-08)
  13: lapply(Zlist, mlegp2, XX = X, orig.XX = orig.X, nugget = nugget, nugget.known = nugget.known, 
         reps = reps, un.sum = un.sum, numEstimates = numEstimates, constantMean = constantMean, 
         simplex.ntries = simplex.ntries, simplex.maxiter = simplex.maxiter, simplex.reltol = simplex.reltol, 
         BFGS.maxiter = BFGS.maxiter, BFGS.tol = BFGS.tol, BFGS.h = BFGS.h, min.nugget = min.nugget, 
         verbose = verbose, param.names = param.names)
  14: FUN(X[[i]], ...)
  
  == testthat results  ===========================================================
  OK: 11 SKIPPED: 0 FAILED: 1
  1. Error: 1D data works (@test_IGP.R#11) 
  
  Error: testthat unit tests failed
  Execution halted