Skip to content

Allow cubed arrays to be passed to flox groupby - #7941

Merged
TomNicholas merged 2 commits into
pydata:mainfrom
TomNicholas:cubed_groupby
Jun 26, 2023
Merged

Allow cubed arrays to be passed to flox groupby#7941
TomNicholas merged 2 commits into
pydata:mainfrom
TomNicholas:cubed_groupby

Conversation

@TomNicholas

@TomNicholasTomNicholas commented Jun 25, 2023

Copy link
Copy Markdown
Member

Generalizes a small check for chunked arrays in groupby so it now allows cubed arrays through to flox rather than just dask arrays. Does not actually mean that flox groupby will work with cubed yet though, see cubed-dev/cubed#223 and xarray-contrib/flox#224

  • Should have been done in Generalize handling of chunked array types #7019
  • Tests added (The place to test this would be in [cubed-xarray]
  • User visible changes (including notable bug fixes) are documented in whats-new.rst
  • New functions/methods are listed in api.rst

@TomNicholasTomNicholas added the topic-chunked-arrays Managing different chunked backends, e.g. dask label Jun 25, 2023
@TomNicholasTomNicholas changed the title fix error raised by ruffAllow cubed arrays to be passed to groupbyJun 25, 2023
Comment on lines +25 to +26
from collections.abc import Sequence
from typing import TYPE_CHECKING, Any, Callable

Copy link
Copy Markdown
MemberAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This change was supposed to be a separate commit, but this was only because ruff raised an error after regenerating the _aggregations.py file.

@TomNicholasTomNicholas changed the title Allow cubed arrays to be passed to groupbyAllow cubed arrays to be passed to flox groupbyJun 25, 2023
@TomNicholas
TomNicholas merged commit e5071aa into pydata:mainJun 26, 2023
@TomNicholas
TomNicholas deleted the cubed_groupby branch June 26, 2023 15:28
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

topic-chunked-arraysManaging different chunked backends, e.g. dask

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

@TomNicholas@dcherian