Skip to content

Support for Unicode string arrays #74

Description

@ksugar

Hi @bogovicj , it would be great to support Unicode string arrays.
Here is the minimal example:

import zarr
import numpy as np

za = zarr.open("string_test.zarr", mode="w", zarr_format=2)
za["string"] = np.array(["string"])
za.info
# Name        :
# Type        : Group
# Zarr format : 2
# Read-only   : True
# Store type  : LocalStore
za["string"]
# <Array file://test.zarr/string shape=(1,) dtype=<U6>
za["string"].info
# Type               : Array
# Zarr format        : 2
# Data type          : FixedLengthUTF32(length=6, endianness='little')
# Fill value         :
# Shape              : (1,)
# Chunk shape        : (1,)
# Order              : C
# Read-only          : True
# Store type         : LocalStore
# Filters            : ()
# Compressors        : (Zstd(level=0),)
# No. bytes          : 24

Thanks in advance.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions