-
-
Notifications
You must be signed in to change notification settings - Fork 26.5k
FIX Add validation for FeatureUnion transformer outputs (#31318) #31559
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
Thanks for the PR @gguiomar. I directly pushed a commit with some nitpicks and small simplifications. I also removed the check for |
jeremiedbb
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
thomasjpfan
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
…#31318) (scikit-learn#31559) Co-authored-by: Jérémie du Boisberranger <[email protected]>
…#31318) (scikit-learn#31559) Co-authored-by: Jérémie du Boisberranger <[email protected]>
) Co-authored-by: Jérémie du Boisberranger <[email protected]>
Description
Fixes #31318
This PR adds validation to
FeatureUnion._hstack()to prevent silent failures when transformers return 1D arrays instead of the expected 2D arrays.Changes Made
FeatureUnion._hstack()to validate transformer outputs are 2Dtransform()method to pass transformer names for better error messagesBefore