FIX warning using polars DataFrames in DecisionBoundaryDisplay.from_estimator#28718
Merged
jeremiedbb merged 12 commits intoApr 10, 2024
Merged
Conversation
bcbc83a to
b5c5044
Compare
b5c5044 to
e729040
Compare
jeremiedbb
reviewed
Mar 29, 2024
jeremiedbb
left a comment
Member
There was a problem hiding this comment.
Thanks for the PR @patrickkwang. ping @glemaitre who made the fix for pandas dataframes for another review.
yuanx749
reviewed
Mar 31, 2024
jeremiedbb
approved these changes
Apr 3, 2024
jeremiedbb
left a comment
Member
There was a problem hiding this comment.
Please add an entry in the v1.4.rst change log. Otherwise LGTM. Thanks @patrickkwang.
Contributor
Author
Done. |
jeremiedbb
reviewed
Apr 4, 2024
2306fb0 to
3593d79
Compare
Member
|
We've decided that the 1.4.2 release will only be about numpy 2 support, so I moved the changelog entry into |
glemaitre
reviewed
Apr 9, 2024
Co-authored-by: Guillaume Lemaitre <guillaume@probabl.ai>
Member
|
Thanks @patrickkwang |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Reference Issues/PRs
Fixes #28717, which is analogous to #23311, but for polars.
See also #25896.
What does this implement/fix? Explain your changes.
This fix is analogous to #23318. We identify when the predictors passed to
DecisionBoundaryPlot.from_estimatoris a polars DataFrame and refrain from converting it to a numpy array and stripping the column names.Any other comments?
The way we do this is a bit awkward because we want to avoid importing polars. A nicer way to do this would be something like the following:
... but that would require
import polars as pl.Instead we drop the existing columns and add columns with the same names and the data from
meshgrid.