Open
Description
What is your issue?
assume_sorted
is False, so for vectorized interpolation across multiple dimensions, we end up lexsorting the coordinates all the time. For some reason, this can be quite slow with dask.
Line 4081 in 6df8bd6
Instead we should be able to do
obj = self
# sort by slicing if we can
for coord in set(indexers) and set(self._indexes):
# TODO: better check for PandasIndex
if self.indexes[coord].is_monotonic_decreasing:
obj = obj.isel(coord: slice(None, None, -1))
# TODO: make None the new default
if assume_sorted is None:
# TODO: dims without coordinates are fine too
assume_sorted = all(self.indexes[coord].is_monotonic_increasing for coord in indexers)
I'll add a reproducible example later, but the problem I've been playing gets much faster for graph construction:
xref #6799