Closed JamiePringle closed 1 year ago
Thanks @JamiePringle . it works for me with maxNumObs=1
(I assume the problem is not sensitive to this?) and
dask : 2022.3.0
zarr : 2.10.3
numpy : 1.21.5
xarray: main
Can you try downgrading zarr to 2.10.3
? Does it still fail for you with maxNumObs=1
? I don't see a commit that would've fixed this on xarray main... And I don't think dask is involved here.
My apologies @dcherian, in commenting the code, I switched "FAILS" and "WORKS" -- the size that fails is numberOfDrifters=120067029
I have edited the example code above, and it should fail when run. I have made a test environment with the versions you suggested, and with maxNumObs=1, and it still fails with the same error.
Jamie
Thanks Jamie.
Yes it now fails here with maxNumObs=1 and xarray main.
It looks like self._chunks
is wrong but I don't know why.
I have had a few other odd indexing issues with large arrays. It almost feels as if somewhere, the sizes are forced to be a fixed size integer or something.
On Tue, May 31, 2022 at 3:34 PM Deepak Cherian @.***> wrote:
CAUTION: This email originated from outside of the University System. Do not click links or open attachments unless you recognize the sender and know the content is safe.
CAUTION: This email originated from outside of the University System. Do not click links or open attachments unless you recognize the sender and know the content is safe.
Thanks Jamie.
Yes it now fails here with maxNumObs=1 and xarray main.
It looks like self._chunks is wrong but I don't know why.
— Reply to this email directly, view it on GitHub https://github.com/pydata/xarray/issues/6640#issuecomment-1142565607, or unsubscribe https://github.com/notifications/unsubscribe-auth/ADBZR27HXRATD7CDBZR7GBDVMZSTFANCNFSM5XBK4B2A . You are receiving this because you were mentioned.Message ID: @.***>
This seems to pass on latest! So I'll close, but please reopen if there's still a failure on a different system
What happened?
Using dask 2022.05.0, zarr 2.11.3 and xarray 2022.3.0, When creating a large empty dataset and trying to save it in the zarr data format with to_zarr, it fails with the following error. Frankly, I am not sure if the problem is with Xarray or Zarr, but as documented in the attached code, when I create the same dataset with Zarr, it works just fine.
To show that this is not a zarr issue, I have made the same output directly with zarr in the example code below. It is in the "else" clause in the code.
Note well: I have included a value of numberOfDrifters that has the problem, and one that does not. Please see the comments where numberOfDrifters is defined.
What did you expect to happen?
I expected a zarr dataset to be created. I cannot solve the problem with a chunk size of 1 for memory issues. I would prefer to create the zarr dataset with xarray so it has the metadata to be easily loaded into xarray.
Minimal Complete Verifiable Example
MVCE confirmation
Relevant log output
Anything else we need to know?
No response
Environment