-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
refactor indexing.py: introduce .oindex for Explicitly Indexed Arrays
#8750
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
Conversation
.oindex and .vindex for Explicitly Indexed Arraysindexing.py: introduce .oindex and .vindex for Explicitly Indexed Arrays
indexing.py: introduce .oindex and .vindex for Explicitly Indexed Arraysindexing.py: introduce .oindex for Explicitly Indexed Arrays
| return self.func(key) | ||
|
|
||
|
|
||
| class BasicIndexer(ExplicitIndexer): |
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.
drive-by comment: Our TODO list should include migrating these indexer objects to namedarray/indexer.py or something (eventually)
|
Do you know why there are no changes to the backend arrays yet? Those too use |
after taking a look at the respective repos, it's my understanding both the rioxarray and cfrib projects use the on the other hand, TileDB-CF-Py seems to bypass this pattern, handling the getitem method differently by using its unique logic for processing the underlying tuple. It still wraps its cc @dcherian |
dcherian
left a comment
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 generally seems like a step in the right direction
Co-authored-by: Deepak Cherian <dcherian@users.noreply.github.com>
for more information, see https://pre-commit.ci
this pull request represents an initial effort to refactor the indexing logic within
indexing.pyby separating it fromvariable.py. to enhance the flexibility of explicitly indexed array classes, this PR introduces orthogonaland vectorizedindexing methods—.oindex[key]and. these changes are a part of a broader initiative aimed at enabling indexing support for namedarray.vindex[key[whats-new.rstapi.rstedit 1:
oindex[key]method in this PR. i intend to introducevindex[key]in a separate PRTODO:
indexing.py: introduce.oindexfor Explicitly Indexed Arrays #8750 (comment)