From d4ff152447282bd0ed0a7f80d591993dec73f88d Mon Sep 17 00:00:00 2001 From: Rory Mitchell Date: Wed, 14 Jan 2026 02:31:38 -0800 Subject: [PATCH 1/2] Add test logging --- legateboost/models/tree.py | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/legateboost/models/tree.py b/legateboost/models/tree.py index 38cfda93..f009e77a 100644 --- a/legateboost/models/tree.py +++ b/legateboost/models/tree.py @@ -119,14 +119,21 @@ def fit( h_ = get_store(h).promote(1, X.shape[1]) task.add_scalar_arg(self.max_depth, types.int32) + print("self.max_depth:", self.max_depth) max_nodes = 2 ** (self.max_depth + 1) - 1 task.add_scalar_arg(max_nodes, types.int32) + print("max_nodes:", max_nodes) task.add_scalar_arg(self.split_samples, types.int32) + print("self.split_samples:", self.split_samples) task.add_scalar_arg(self.random_state.randint(0, 2**31), types.int32) task.add_scalar_arg(X.shape[0], types.int64) + print("X.shape[0]:", X.shape[0]) task.add_scalar_arg(self.l1_regularization, types.float64) + print("self.l1_regularization:", self.l1_regularization) task.add_scalar_arg(self.l2_regularization, types.float64) + print("self.l2_regularization:", self.l2_regularization) task.add_scalar_arg(self.min_split_gain, types.float64) + print("self.min_split_gain:", self.min_split_gain) task.add_input(X_) task.add_broadcast(X_, 1) @@ -135,6 +142,9 @@ def fit( task.add_input(h_) task.add_alignment(g_, h_) task.add_alignment(g_, X_) + print("X_:", X_) + print("g_:", g_) + print("h_:", h_) # sample features if callable(self.feature_fraction): From 2c0d7aca760795d5819ad8109ce57158019de8d7 Mon Sep 17 00:00:00 2001 From: Rory Mitchell Date: Wed, 14 Jan 2026 06:57:55 -0800 Subject: [PATCH 2/2] Modify print statements --- legateboost/models/tree.py | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/legateboost/models/tree.py b/legateboost/models/tree.py index f009e77a..23974fd7 100644 --- a/legateboost/models/tree.py +++ b/legateboost/models/tree.py @@ -117,6 +117,9 @@ def fit( X_ = get_store(X).promote(2, g.shape[1]) g_ = get_store(g).promote(1, X.shape[1]) h_ = get_store(h).promote(1, X.shape[1]) + print("X.shape:", X.shape) + print("g.shape:", g.shape) + print("h.shape:", h.shape) task.add_scalar_arg(self.max_depth, types.int32) print("self.max_depth:", self.max_depth) @@ -136,15 +139,15 @@ def fit( print("self.min_split_gain:", self.min_split_gain) task.add_input(X_) + print("X_:", X_) task.add_broadcast(X_, 1) task.add_broadcast(X_, 2) task.add_input(g_) + print("g_:", g_) task.add_input(h_) + print("h_:", h_) task.add_alignment(g_, h_) task.add_alignment(g_, X_) - print("X_:", X_) - print("g_:", g_) - print("h_:", h_) # sample features if callable(self.feature_fraction):