Blog post: Xarray Indexes

Together with @scottyhq , @dcherian and @keewis we published a few weeks ago a blog post on Xarray “Flexible Indexes: Exciting new ways to slice and dice your data!”.

TL;DR: After gradually refactoring Xarray internals over the last few years, flexible indexes are now alive and ready to use, finally! Xarray indexes make coordinate-based data selection and alignment customizable, enabling efficient handling of both traditional and more exotic data structures. In the blog post we highlight a few examples that take advantage of this new superpower!

The blog post comes also with a Gallery of Custom Index Examples as well as @dcherian ‘s great presentation at SciPy 2025 (video recording).

Other technical blog posts should follow up, focusing on how to create a custom index (i.e., describing how the Xarray Index API interacts with Xarray internals for a common set of operations like indexing and alignment).

Feedback welcome!

14 Likes

Truly amazing work @benbovy!

1 Like