Skip to content

Commit

Permalink
Fix
Browse files Browse the repository at this point in the history
Signed-off-by: Adam Li <adam2392@gmail.com>
  • Loading branch information
adam2392 committed Sep 9, 2024
1 parent 3b0426c commit 04d661b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions treeple/neighbors.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
from sklearn.base import BaseEstimator, MetaEstimatorMixin
from sklearn.exceptions import NotFittedError
from sklearn.neighbors import NearestNeighbors
from sklearn.utils.validation import check_is_fitted
from sklearn.utils.validation import check_is_fitted, validate_data

from treeple.tree._neighbors import _compute_distance_matrix, compute_forest_similarity_matrix

Expand Down Expand Up @@ -56,7 +56,7 @@ def fit(self, X, y=None):
self : object
Fitted estimator.
"""
X, y = self._validate_data(X, y, accept_sparse="csc")
X, y = validate_data(self, X, y, accept_sparse="csc")

self.estimator_ = copy(self.estimator)
try:
Expand Down

0 comments on commit 04d661b

Please sign in to comment.