Skip to content

Commit

Permalink
FIX remove classes modification
Browse files Browse the repository at this point in the history
  • Loading branch information
PSSF23 committed Aug 22, 2023
1 parent 01c1e55 commit 9b4ff1b
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions sktree/tree/_honest_tree.py
Original file line number Diff line number Diff line change
Expand Up @@ -423,9 +423,6 @@ def partial_fit(self, X, y, sample_weight=None, check_input=True, classes=None):

_sample_weight[self.honest_indices_] = 0

if classes is None:
classes = np.unique(y).tolist()

self.estimator_.partial_fit(
X,
y,
Expand Down Expand Up @@ -560,9 +557,6 @@ def _fit(
# XXX: maybe error out if the tree_estimator is already fitted
self.estimator_ = deepcopy(self.tree_estimator)

if classes is None:
classes = np.unique(y).tolist()

# Learn structure on subsample
self.estimator_._fit(
X,
Expand Down

0 comments on commit 9b4ff1b

Please sign in to comment.