File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change 7272 ZDTypeLike ,
7373 parse_data_type ,
7474)
75- from zarr .core .dtype .common import HasItemSize
75+ from zarr .core .dtype .common import HasEndianness , HasItemSize
7676from zarr .core .indexing import (
7777 BasicIndexer ,
7878 BasicSelection ,
@@ -4731,7 +4731,7 @@ def _parse_chunk_encoding_v3(
47314731 # TODO: ensure that the serializer is compatible with the ndarray produced by the
47324732 # array-array codecs. For example, if a sequence of array-array codecs produces an
47334733 # array with a single-byte data type, then the serializer should not specify endiannesss.
4734- if isinstance (out_array_bytes , BytesCodec ) and dtype . to_dtype (). itemsize == 1 :
4734+ if isinstance (out_array_bytes , BytesCodec ) and not isinstance ( dtype , HasEndianness ) :
47354735 # The default endianness in the bytescodec might not be None, so we need to replace it
47364736 out_array_bytes = replace (out_array_bytes , endian = None )
47374737 return out_array_array , out_array_bytes , out_bytes_bytes
You can’t perform that action at this time.
0 commit comments