10000 FIX Adds requires_y tag to TargetEncoder (#25917) · Veghit/scikit-learn@8198995 · GitHub
[go: up one dir, main page]

Skip to content

Commit 8198995

Browse files
thomasjpfanItay
authored andcommitted
FIX Adds requires_y tag to TargetEncoder (scikit-learn#25917)
1 parent 41e211c commit 8198995

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

sklearn/preprocessing/_target_encoder.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -339,3 +339,6 @@ def _transform_X_ordinal(
339339
for f_idx, encoding in enumerate(encodings):
340340
X_out[indices, f_idx] = encoding[X_ordinal[indices, f_idx]]
341341
X_out[X_unknown_mask[:, f_idx], f_idx] = y_mean
342+
343+
def _more_tags(self):
344+
return {"requires_y": True}

0 commit comments

Comments
 (0)
0