-
Notifications
You must be signed in to change notification settings - Fork 4k
[python-package] add PyArrow Table support to get_data and add_features_from methods #6892
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
Draft
suk1yak1
wants to merge
23
commits into
microsoft:master
Choose a base branch
from
suk1yak1:fix/6891-pyarrow-table-add-features
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+220
−2
Draft
Changes from all commits
Commits
Show all changes
23 commits
Select commit
Hold shift + click to select a range
cf13aad
[python-package]add_features_from with PyArrow Table incorrectly free…
suk1yak1 99ee66f
[python-package] add PyArrow Table case to test_add_features_from_dif…
suk1yak1 a3256a3
[python-package] fix handling and tests for PyArrow Table input in ad…
suk1yak1 9de2650
Merge branch 'master' into fix/6891-pyarrow-table-add-features
suk1yak1 01bc668
delete unnecessary-else
suk1yak1 27e2545
Merge branch 'master' of https://github.com/microsoft/LightGBM into f…
suk1yak1 219e61c
[python-package]add test for pyarrow table in Dataset.get_data()
suk1yak1 d4de309
[python-package]add test for add_features_from with pyarrow tables
suk1yak1 6686a60
Merge branch 'master' into fix/6891-pyarrow-table-add-features
suk1yak1 22ec314
[python-package] add PyArrow Table to get_data
suk1yak1 c7594c8
[python-package] add test for subset of PyArrow table dataset
suk1yak1 e0fce82
Merge branch 'master' into fix/6891-pyarrow-table-get-data
StrikerRUS 1af15c6
Merge branch 'master' into fix/6891-pyarrow-table-get-data
suk1yak1 b5395a0
[python-package] improve PyArrow table subset tests for null values a…
suk1yak1 5f067ec
Merge branch 'master' into fix/6891-pyarrow-table-get-data
jameslamb eaf9510
Merge branch 'master' into fix/6891-pyarrow-table-get-data
suk1yak1 04db4aa
Merge branch 'master' into fix/6891-pyarrow-table-get-data
suk1yak1 e569ac5
[python-package]avoid TypeError: ChunkedArray.to_numpy() takes no key…
suk1yak1 5b4b197
Merge branch 'master' into fix/6891-pyarrow-table-get-data
suk1yak1 e826a4f
[python-package]Move final assertion before for loop to fail faster a…
suk1yak1 17dbc43
[python-package]Rename test helper and add docstring to clarify purpose
suk1yak1 8135e92
[python-package]Rename test helper
suk1yak1 71a65e5
Merge branch 'fix/6891-pyarrow-table-get-data' of github.com:suk1yak1…
suk1yak1 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
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.
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.
Thanks! This was definitely just something we'd missed.
Can you please add a test in https://github.com/microsoft/LightGBM/blob/master/tests/python_package_test/test_arrow.py just for this change to
get_data()? The other changes you made intest_basic.pydo not cover these changes.When you do that, please check that the content of
self.dataAND the returned value are correct (e.g., contain exactly the expected values and data types).If you'd like, I'd even support opening a new pull request that only has the
get_data()changes + test (and then making this PR only aboutadd_features_from()). Totally your choice, I want to be respectful of your time.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.
Thanks for the suggestion!
I added tests for both get_data() and add_features_from() directly in
test_arrow.pyas part of this PR.Please let me know if there’s anything else you’d like me to adjust!
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.
@jameslamb
I’ve opened a new pull request(#6911) that includes only the changes to get_data() along with the corresponding test. This should help keep things focused. I’d appreciate it if you could take a look when you have time.
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.
Thanks! I'll focus there.