From cbe04444f4beaec008581cad9291bb037f8894cb Mon Sep 17 00:00:00 2001 From: wendycwong Date: Sun, 27 Oct 2024 16:33:38 -0700 Subject: [PATCH] fix test error. --- h2o-algos/src/main/java/hex/hglm/ComputationStateHGLM.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/h2o-algos/src/main/java/hex/hglm/ComputationStateHGLM.java b/h2o-algos/src/main/java/hex/hglm/ComputationStateHGLM.java index 96b522bae393..e86727130cb1 100644 --- a/h2o-algos/src/main/java/hex/hglm/ComputationStateHGLM.java +++ b/h2o-algos/src/main/java/hex/hglm/ComputationStateHGLM.java @@ -79,7 +79,7 @@ void initComputationStateHGLM(HGLMTask.ComputationEngineTask engineTask) { throw new IllegalArgumentException("initial_t_matrix must be symmetric but is not!"); // make sure matrix is semi positive definite Matrix tMat = new Matrix(_T); - if (!tMat.chol().isSPD()) + if ((_parms._max_iterations > 0) && !tMat.chol().isSPD()) // only check this when we actually build the model throw new IllegalArgumentException("initial_t_matrix must be positive semi definite but is not!"); } else { if (_parms._tau_u_var_init > 0.0) {