-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Enable numbagg for reductions #8316
Conversation
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.
Awesome, thanks @dcherian !
Are there any other functions that would be helpful?
Do we need to capitulate on the ddof
?
xarray/core/nputils.py
Outdated
except ImportError: | ||
# use numpy methods instead | ||
numbagg = np | ||
_NUMBAGG_AVAILABLE = False |
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.
FYI there's a version of this at
xarray/xarray/core/rolling_exp.py
Lines 16 to 17 in dafd726
has_numbagg = numbagg.__version__ |
(though I'm not sure my approach is that good! Open to feedback...)
Waiting on numbagg/numbagg#162 to be released so I can add a version check and only defer to numbagg when |
Done! |
Should work whenever the CI environment updates. |
Uses the approach in pydata#8316, a bit nicer. Only internal.
Uses the approach in pydata#8316, a bit nicer. Only internal.
* internal: Improve version handling for numbagg Uses the approach in #8316, a bit nicer. Only internal. * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Update xarray/core/rolling_exp.py --------- Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
whats-new.rst