Skip to content
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

Add numpy2 support #2449

Open
wants to merge 46 commits into
base: master
Choose a base branch
from
Open

Add numpy2 support #2449

wants to merge 46 commits into from

Conversation

2maz
Copy link

@2maz 2maz commented Jan 16, 2025

This pull request intends to enable the use of numpy2 (#2446 #2425) with vaex.
In addition it applies some other fixes.

An (incomplete) summary:

Note, that I encountered some broken test(s) in cmodule.py test_interpolate and those related to Webserver:

  • this looked like it was in a broken state already, so left it for now
    Some format changes from tab to space indent have been applied.

Please let me know if (further) changes are required - only validated on Linux system right now.
I ran tests in vaex-core/vaex/test - any more instructions on how to run you full test-suite (apart from ci)?

Thx.

@maartenbreddels @ddelange

@2maz
Copy link
Author

2maz commented Jan 17, 2025

2maz added 3 commits January 17, 2025 15:03
Handling: ValueError: Unable to avoid copy while creating an array as requested
…alue to int8

Note, that this might need deeper investigation and handling in the hash classes.
However, for the masking when comparing to legacy behaviour,
it looks as if null_index will be converted to -1.
@ddelange
Copy link
Contributor

ddelange commented Jan 18, 2025

Great progress! ❤️ Is the plan to also maintain numpy v1 runtime support?

@2maz
Copy link
Author

2maz commented Jan 20, 2025

Great progress! ❤️ Is the plan to also maintain numpy v1 runtime support?

For now, yes, should still run with v1, and so far it does considering ci and 3.9 (uses numpy==1.26.4)

2maz added 4 commits January 21, 2025 15:08
…find_edges

percentile_approx_test fails with nan in the result array, caused by vaex.vaexfast.grid_find_edges returning
edges_floor / edges_ceil with [from, to] where from == to
@2maz
Copy link
Author

2maz commented Jan 23, 2025

All outstanding issues related to numpy v2 (and some not) are resolved - only catboost dependent functionality is conditionally disabled.

All pipelines run fine - even some previously skipped tests.
Any comments: @ddelange @maartenbreddels @JovanVeljanoski

@ddelange
Copy link
Contributor

awesome work! ❤️

@maartenbreddels if we get lucky, the pybind submodule update in this PR will also solve #2442

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants