From 27e4210a7546cb72a0df1c0d54c7c09fed628e12 Mon Sep 17 00:00:00 2001 From: Birte Kristina Friesel Date: Thu, 25 Jan 2024 11:57:16 +0100 Subject: XGB: switch to XGBoost defaults --- lib/functions.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'lib/functions.py') diff --git a/lib/functions.py b/lib/functions.py index 32f777b..d18477e 100644 --- a/lib/functions.py +++ b/lib/functions.py @@ -763,7 +763,12 @@ class XGBoostFunction(SKLearnRegressionFunction): def hyper_to_dref(self): return { "xgb/n estimators": self.regressor.n_estimators, - "xgb/max depth": self.regressor.max_depth, + "xgb/max depth": self.regressor.max_depth == 0 + and "infty" + or self.regressor.max_depth, + "xgb/max leaves": self.regressor.max_leaves == 0 + and "infty" + or self.regressor.max_leaves, "xgb/subsample": self.regressor.subsample, "xgb/eta": self.regressor.learning_rate, "xgb/gamma": self.regressor.gamma, -- cgit v1.2.3