-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
interp on chunked dimension can fail (oom) #10130
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
Comments
I believe this is dask/dask#11613 and has been fixed, but not released. I don't understand why your trick works on the older versions. |
Thank you, @dcherian . I can only make it work by manual rechunking, which is a bit cumbersome. With Test 1Fails both on
Test 2Manual rechunking works (both on
Profile looks fine, I think. |
I can reproduce with Dask @phofl what do you think about this issue? Thank you! |
What is your issue?
Hi,
I am using
interp
withlinear
method along a sorted chunked dimension.From the Dask dashboard I see workers failing and restarting, till it fails, with messages along the lines of:
I allocated 8GB per worker with the distributed scheduler, but you can reproduce the issue even with the default one.
Up to
xarray<=2024.11.0
I was able to make it work using a trick (below).I can successfully run with 2024.11.0 and
dask[distributed]<=2025.2.0
, so it is "independent" from Dask versions.I have seen a few discussions in PRs and Issues, but failed to get closure on what would be the best approach in this case. Since my time axis is sorted, interpolation is linear, it should be possible to not have to load in memory all chunks along that axis. Any suggestions? Common ways of dealing with this?
1. Generate data
Interp
Now the following does NOT work (regardless of the xarray version), memory issues.
Interp with trick to maintain dask indexer
The following DOES work in xarray 2024.11.0, but not with 2025.1.2, I suspect because of the
apply_ufunc
change tointerp
.Sanity check vs scipy
Sanity check the results I got with 2024.11.0 were indeed the expected ones:
The text was updated successfully, but these errors were encountered: