Skip to content

Formalise compression and filters arguments in reduce_chunk, avoid numcodecs.Codec objects #125

Description

@markgoddard

Currently we pass numcodecs.Codec objects as the compression and filters arguments to reduce_chunk. This is convenient for the local storage implementation, but does leave us reliant on the numcodecs library in what might be considered our internal "storage backend API".

It would be better to describe these algorithms using a Plain Old Data (POD) type, such as a dict.

See the original discussion.

As outlined in my proposal, I suggest we use arguments in the following format:

reduce_chunk(
    compression={"compression": {"id": "zlib"}},
    filters=[{"id": "shuffle", "dtype": "uint32"}]),
    ...
)

This aligns with the format used in the S3 active storage server API.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions