-
Notifications
You must be signed in to change notification settings - Fork 79
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
flexible codecs cannot handle compound dtypes containing objects #333
Comments
Any update here? |
None from me. I have a plausible fix, above, which could be added now, but I was hoping someone would come up with something cleaner. |
I am getting this from the test suite:
|
I don't know if my diff would fix that. If yes, let's include it! I wonder what changed that this is showing up now but not before. |
Unfortunately not. I tried to apply the patch just now. The |
The difference is an updated numpy 1.24.1 |
This is missing, but reasonably expectable, functionality. If you have a zarr array with a compound dtype (i.e., records) and any of the fields are object type (i.e., strings), then you cannot roundtrip the data even though JSON/msgpack/pickle are capable of converting the array.
Minimal, reproducible code sample, a copy-pastable example if possible
(without fill_value, this errors earlier sue to the use of
np.zeros
to guess a fill; with an appropriate fill_value=("", 0, 0.), it fails at array creation too)Problem description
JSON and similar codecs store only the dtype.str, which is a "Vxx" in these cases, which means a suitable empty array cannot be made at load time.
The following fixes this for JSON, but looks ugly.
Version and installation information
Please provide the following:
numcodecs.__version__
0.10.0The text was updated successfully, but these errors were encountered: