From 5c13aa0a8a5628c66ef1dfbc46deb4f223655594 Mon Sep 17 00:00:00 2001 From: Laurae Date: Fri, 24 Mar 2017 16:54:39 +0100 Subject: [PATCH] GLM test unit: make run deterministic (#2147) --- tests/python/test_basic_models.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/python/test_basic_models.py b/tests/python/test_basic_models.py index 80fae40d7..0b12ce4c3 100644 --- a/tests/python/test_basic_models.py +++ b/tests/python/test_basic_models.py @@ -12,7 +12,7 @@ rng = np.random.RandomState(1994) class TestModels(unittest.TestCase): def test_glm(self): param = {'silent': 1, 'objective': 'binary:logistic', - 'booster': 'gblinear', 'alpha': 0.0001, 'lambda': 1} + 'booster': 'gblinear', 'alpha': 0.0001, 'lambda': 1, 'nthread': 1} watchlist = [(dtest, 'eval'), (dtrain, 'train')] num_round = 4 bst = xgb.train(param, dtrain, num_round, watchlist)