Skip to content

Commit cd49d8a

Browse files
jjerphanjeremiedbb
andcommitted
MAINT Simply use python class for dispatchers
Co-authored-by: Jérémie du Boisberranger <[email protected]>
1 parent 470f231 commit cd49d8a

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

sklearn/metrics/_pairwise_distances_reduction.pyx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -187,7 +187,7 @@ cpdef DTYPE_t[::1] _sqeuclidean_row_norms(
187187
#####################
188188
# Dispatchers
189189

190-
cdef class PairwiseDistancesReduction:
190+
class PairwiseDistancesReduction:
191191
"""Abstract base dispatcher for pairwise distance computation & reduction.
192192
193193
Each dispatcher extending the base :class:`PairwiseDistancesReduction`
@@ -236,7 +236,7 @@ cdef class PairwiseDistancesReduction:
236236
metric in cls.valid_metrics())
237237

238238

239-
cdef class PairwiseDistancesArgKmin(PairwiseDistancesReduction):
239+
class PairwiseDistancesArgKmin(PairwiseDistancesReduction):
240240
"""Compute the argkmin of row vectors of X on the ones of Y.
241241
242242
For each row vector of X, computes the indices of k first the rows
@@ -360,7 +360,7 @@ cdef class PairwiseDistancesArgKmin(PairwiseDistancesReduction):
360360
)
361361

362362

363-
cdef class PairwiseDistancesRadiusNeighborhood(PairwiseDistancesReduction):
363+
class PairwiseDistancesRadiusNeighborhood(PairwiseDistancesReduction):
364364
"""Compute radius-based neighbors for two sets of vectors.
365365
366366
For each row-vector X[i] of the queries X, find all the indices j of

0 commit comments

Comments
 (0)