All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
0.19.0 - 2025-01-10
zarr-python
3.0.0 has been released today!- The focus of this release has been in maximising compatibility with unstandardised extensions in
zarr-python
(e.g. experimental codecs, consolidated metadata, etc.)
- Add
ArrayShardedReadableExt::retrieve_encoded_inner_chunk
- Add
ArrayShardedReadableExt::inner_chunk_byte_range
- Add
ArrayShardedExt::is_exclusively_sharded
- Add
ArrayShardedReadableExtCache::array_is_exclusively_sharded
- Add
Vlen{Array,Bytes,Utf8}Codec
, replacingVlenV2Codec
- Add
ZstdCodecConfigurationNumCodecs
- Adds support for Zarr V2
zstd
encoded data created withnumcodecs
< 0.13
- Adds support for Zarr V2
- Add support for pcodec
Auto
,None
, andTryLookback
delta specs - Add
Group::[set_]consolidated_metadata
- Add
Node::consolidate_metadata
- Consolidated metadata is not currently used to optimise node hierarchy requests
- Add experimental
fletcher32
checksum codec based on the numcodecs implementation- Adds
fletcher32
feature flag
- Adds
- Add ecosystem compatibility notes in the experimental codecs docs
- Breaking: Seal
Array
extension traits:ArraySharded[Readable]Ext
andArrayChunkCacheExt
- Breaking: Make
{Array,Bytes}PartialDecoderCache
private - Breaking: Make
Any
a supertrait of partial encoder/decoder traits - Breaking: Add
ArrayError::UnsupportedMethod
- Breaking: Rename
DataType::Binary
toBytes
for compatibility withzarr-python
- Breaking: Make
array::codec::array_to_bytes::bytes::reverse_endianness
private - Breaking: Make
VlenV2Codec
private - Bump
itertools
to 0.14 - Indicate that
zfp
/zfpy
codecs have different metadata in codec table - Use
zarr-python
3.0.0 in compatibility tests - Breaking: Bump MSRV to 1.82 (17 October, 2024)
- Remove support for pcodec
Try{FloatMult,FloatQuant,IntMult}
mode specs- These may be reimplemented when supported by
zarr-python
/numcodecs
- These may be reimplemented when supported by
- Cleanup unnecessary lifetime constraints in partial decoders
- Fix
clippy::useless_conversion
lint
0.18.3 - 2024-12-30
- impl
From<Node>
forNodePath
(#112 by @niklasmueboe) - Add
Group::child[_{group,array}]_paths
(#112 by @niklasmueboe)
0.18.2 - 2024-12-25
- functions to get children of Group (#104 by @niklasmueboe)
- adds
Group::[async_]children
,Group::[async_]child_groups
,Group::[async_]child_arrays
- adds
- Impl
From<Node>
forNodeMetadata
- Reduce metadata code duplication in the
Node
module
0.18.1 - 2024-12-17
- Bump
zfp-sys
to 0.3.0 - Bump
bzip2
to 0.5.0 - Minor readme/ecosystem updates
- Fix
unsafe_op_in_unsafe_fn
lint - Clarify that the
zstd
codec is draft in docs - Clarify that the
gdeflate
codec is experimental in docs
0.18.0 - 2024-11-23
zarrs-python
was recently released- It implements a high-performance codec pipeline for the reference
zarr-python
implementation - It is supported by downstream libraries like
dask
- See zarr_benchmarks for benchmarks
- It implements a high-performance codec pipeline for the reference
- The
zarrs
Book has been created and is under construction
- Experimental partial encoding support (enabling writing shards incrementally)
- Improve Zarr V2 interoperability and conversion
- Add a
makefile
and simplifyBUILD.md
- Add chunk-by-chunk update example in
Array
docs - Add
array::copy_fill_value_into()
- Add experimental partial encoding support (sync only):
- Enables writing shards incrementally
- With
{CodecOptions,Config}::experimental_partial_encoding
enabled,Array::store_{array,chunk}_subset
will use partial encoding - This is an experimental feature for now until it has more comprehensively tested and support is added in the async API
- Adds
ArrayPartialEncoderTraits
,BytesPartialEncoderTraits
,StoragePartialEncoder
,ArrayPartialEncoderDefault
,BytesPartialEncoderDefault
- Breaking: Add
{ArrayToArray,ArrayToBytes,BytesToBytes}CodecTraits::partial_encoder
- Add
with_
methods to{Array,Group}MetadataOptions
- Add
zarr_v2_to_v3
example - Add
{Array,Group}::to_v3()
- Add
ShardingCodecBuilder::build_arc()
- Add
zarrs::version::version_{str,pre}
- Add "The zarrs Book" and
zarrs-python
to docs
- Bump
unsafe_cell_slice
to 0.2.0 - Breaking: Change
output
parameter ofdecode_into
codec trait methods to&UnsafeCellSlice<u8>
- Breaking: Add
dynamic()
to allCodecTraits
- Breaking: Add
options
parameter to[Async]ArrayPartialDecoderTraits::partial_decode
and removepartial_decode_opt
- Make
array::update_array_bytes()
public - Breaking: Bump MSRV to 1.77 (21 March, 2024)
- Bump
zfp-sys
to 0.2.0 - Display
ArraySubset
as a list of ranges - Relax
output_subset
requirements onArrayToBytesCodecTraits::decode_into
andArrayPartialDecoderTraits::partial_decode_into
- The subset shape and dimensionality no longer has to match, only the number of elements
- Bump
pco
(pcodec) to 0.4 - Breaking: Change
experimental_codec_names
config hashmap toHashMap<String, String>
fromHashMap<&'static str, String>
- Breaking: Add
name
parameter tovlen_v2
codec constructors - Register
vlen-array
,vlen-bytes
, andvlen-utf8
codecs - Bump
zarrs_metadata
to 0.2.0 - Bump
zarrs_storage
to 0.3.0 - Bump
zarrs_filesystem
to 0.2.0 - Make
zarrs::version::version_{,major,minor,patch}
const
- Remove
async-recursion
dependency - Breaking: Remove
Default
implementation forVlenV2Codec
- Fix panics that could occur with with empty byte ranges / empty array subsets in
Array
,ByteRange
and codec methods
0.18.0-beta.0 - 2024-11-15
0.17.1 - 2024-10-18
- Add
zarrs_icechunk
to ecosystem docs
- Fix
data_key
encoding on windows (it contained '//') - Fix
clippy::needless_lifetimes
lint
0.17.0 - 2024-10-02
zarrs
has been split into 3 core crates:zarrs
,zarrs_metadata
, andzarrs_storage
zarrs_storage
andzarrs_metadata
are re-exported as thestorage
andmetadata
modules
- Store implementations have been moved into separate crates:
zarrs_{filesystem,http,object_store,opendal,zip}
zarrs_filesystem
is re-exported as thefilesystem
module with thefilesystem
feature (enabled by default)
- Direct IO support for Linux in
FilesystemStore
- Implicit groups are no longer supported
- It is the responsibility of the
zarrs
consumer to explicitly write group metadata when creating a hierarchy
- It is the responsibility of the
- Codecs must now be
Arc
'd instead ofBox
'd - Fixes a performance regression introduced in 0.16 when reading sharded arrays
- Check the full release notes for all changes. This release has many breaking changes due to items being removed, moved, renamed, and deprecated.
- Add
ChunkGridTraits::chunks_in_array_subset()
- Add chunk cache support
- Add
ArrayChunkCacheExt
extension trait forArray
- Add traits:
ChunkCache
,ChunkCacheType
(implemented byChunkCacheType{Encoded,Decoded}
) - Add chunk cache implementations:
ChunkCache{En,De}codedLru{Size,Chunk}Limit[ThreadLocal]
- Add
- #58 Add direct I/O support in
FilesystemStore
by @sk1p- Adds
FilesystemStoreOptions
andFilesystemStore::new_with_options
- Adds
- #64 Add
Array::[async_]store_encoded_chunk
for writing already-encoded chunks by @sk1p - Add
key()
,start()
,value()
toStoreKeyStartValue
- Add
StorageError::MissingMetadata
now that implicit groups are not supported - Add
ChunkShape::to_array_shape()
- Add
DataTypeMetadataV3
- Add
ArrayShardedExt::effective_inner_chunk_shape
- This is the effective inner chunk shape (i.e. read granularity) of a sharded array
- It is equal to the inner chunk shape unless the
transpose
codec precedessharding_indexed
- Breaking: Add
ArrayToArrayCodecTraits::compute_decoded_shape()
- Needed for
ArrayShardedExt::effective_inner_chunk_shape
- Needed for
- Add
ArrayToBytesCodecTraits::decode_into
and[Async]ArrayPartialDecoderTraits::partial_decode_into
- This revisits the array view API that was removed in 0.16 #39, but simpler and less public
- Resolves a performance regression introduced in 0.16 when decoding sharded arrays with
Array::[async_]retrieve_array_subset_opt
.
- Add
Array::subset_all()
- Add
ArraySubset::to_ranges()
- Breaking:
Arc
instead ofBox
partial decoders - Expand
set_partial_values
tests - Specialise
set_partial_values
forMemoryStore
- Bump maximum supported
ndarray
version from 0.15 to 0.16 - Breaking: Make
create_chunk_grid_{regular,rectangular}
pub(crate)
in alignment with other internal create from metadata methods - Breaking: Bump MSRV to 1.76 (8 February, 2024)
- #59 Add
ReadableWritableStorageTraits
automatically for all implementations by @dustinlagoy - Remove implicit group support
- This is a post-acceptance change of Zarr V3: zarr-developers/zarr-specs#292
- #63 Make
StoreKeysPrefixes
constructible by @sk1p - Breaking: Use values of
Metadata{Convert,Erase}Version
instead of references in parameters/return values - Restructure
metadata
module- Move conversion to
metadata::v2_to_v3
- Breaking: Remove many re-exports to the root of
metadata
- Move various items to the
metadata
module, keeping re-exports in thearray
module{Array,Chunk}Shape
Endianness
ZARR_NAN_{F16, BF16, F32, F64}
ChunkKeySeparator
DimensionName
- Split
DataType
intoarray::DataType
andmetadata::_::DataTypeMetadataV3
- Move conversion to
- Breaking:
data_key
inzarrs::storage
now take achunk_key
instead of achunk_key_encoding
andchunk_indices
- Breaking: Move
metadata::{v2,v3}::{codec,chunk_grid,chunk_key_encoding}
tometadata::{v2,v3}::array::
- Breaking: Rename
ArrayMetadataV2DataType
toDataTypeMetadataV2
- Breaking: Rename
FillValueMetadata
toFillValueMetadataV3
- Move
crate::byte_range
intocrate::storage::byte_range
module, add re-export - Add
impl TryInto<StorePrefix> for &NodePath
- Removes
TryFrom<&NodePath> for StorePrefix
- Removes
- Breaking: Move
extract_byte_ranges_read[_seek]
fromarray::codec
tostorage::byte_range
- Breaking: Move
storage::[async_]{get_child_nodes,node_exists,node_exists,listable}
tonode
module - Breaking: Move
storage::{meta_key*,data_key}
intonode
module - Split the crate into multiple crates:
zarrs
zarrs_storage
(re-exported asstorage
module)zarrs_metadata
(re-exported asmetadata
module)zarrs_filesystem
(re-exported asfilesystem
module withfilesystem
feature, enabled by default)zarrs_http
zarrs_object_store
zarrs_opendal
zarrs_zip
- Breaking: Codecs no longer need to implement
Clone
but must be inArc
instead ofBox
- Breaking: Change
Contiguous[Linearised]Indices
iterators to return indices only - Breaking: Remove lifetime constraints in partial decoder API by utilising
Arc
'd codecs - Breaking:
ShardingCodec::new
CodecChain
parameters now must be in anArc
- Breaking: Change
UsageLogStorageTransformer
toUsageLogStorageAdapter
and move tozarrs_storage
- Breaking: Change
PerformanceMetricsStorageTransformer
toPerformanceMetricsStorageAdapter
and move tozarrs_storage
- Breaking: Storage transformer refactor:
- Add
StorageTransformerPlugin
for storage transformer registration instead of genericPlugin
- Remove several
StorageTransformerExtension
trait methods no longer needed - Change
StorageTransformerExtension::create_metadata
to returnMetadataV3
instead of anOption
StorageTransformerExtension::[async_]create_*_transformer
methods are now fallibleStorageTransformerExtension::async_create_*_transformer
methods are now asyncStorageTransformerChain::from_metadata
andtry_create_storage_transformer
now has apath: &NodePath
parameter
- Add
- Breaking: Remove
array::NonZeroError
, usestd::num::TryFromIntError
instead - Breaking: Move storage transformers from the
storage
to thearray
module - Breaking: Remove many functions in the storage module:
[async_]create_{array, group}
[async_]erase_{chunk,metadata}
,[async_]{retrieve,store}_chunk
[async_]retrieve_partial_values
[async_]discover_nodes
- Breaking: Remove
Default
implementation forMetadata{Convert,Erase}Version
- Explicitly use
global_config()
instead
- Explicitly use
- Breaking: Remove
array::UnsafeCellSlice
- Replaced by
UnsafeCellSlice
in theunsafe_cell_slice
crate
- Replaced by
- Breaking: Remove
NATIVE_ENDIAN
, useEndianness::native()
- Breaking: Remove unused
DataTypeExtension
- Remove remnants of old synchronisation API
[async_]store_set_partial_values
no longer truncates- this could corrupt values depending on the order of
set_partial_values
calls
- this could corrupt values depending on the order of
- Fix
FilesystemStore::fspath_to_key
on windows - Make
ArrayRepresentationBase
pub so that{Array,Chunk}Representation
are not opaque - Fix
ArrayShardedExt::inner_chunk_grid
when applied on a sharded array with thetranspose
codec precedingsharding_indexed
- Fix
ZipStorageAdapter
on windows - Fixed an unnecessary copy in
Array::[async_]retrieve_chunk_if_exists_opt
- Fixed
CodecOptions
not being forwarded inArray::retrieve_chunk_subset_opt
on the fast path - Fixed missing fast path in
Array::[async_]retrieve_chunk_subset_opt
- Fixed
blosc
codec partial decoding withnoshuffle
0.17.0-beta.3 - 2024-09-26
0.17.0-beta.2 - 2024-09-23
0.17.0-beta.1 - 2024-09-16
0.17.0-beta.0 - 2024-09-06
0.16.4 - 2024-08-22
- Reduce maximum supported
opendal
version from 0.49 to 0.48- This reverts a change in 0.16.3 that was not semver compatible
0.16.3 - 2024-08-14
This release was yanked.
- Bump
derive_more
to 1.0.0 - Bump maximum supported
opendal
version from 0.48 to 0.49 - Box the metadata in
PluginMetadataInvalidError
- Fix
cargo test
with--no-default-features
- Fix new clippy warnings in nightly
0.16.2 - 2024-08-05
- Add the experimental
gdeflate
bytes-to-bytes codec - Add
Array::chunk_key()
- Add
ArrayShardedExt::inner_chunk_grid_shape()
0.16.1 - 2024-07-30
- Bump maximum supported
opendal
version from 0.47 to 0.48
- Fixed handling of empty shards with a variable length data type with sharding partial decoder
0.16.0 - 2024-07-28
- Add experimental support for the
string
andbinary
data types and thevlen
andvlen_v2
codecs - Cleanup the
Array
API for retrieving elements (Vec<T>
) andndarray
s - Support more Zarr V2 array configurations and make various experimental codecs
numcodecs
compatible
- Add
ArrayBytes
,RawBytes
,RawBytesOffsets
, andArrayBytesError
- These can represent array data with fixed and variable length data types
- Add
array::Element[Owned]
traits representing array elements- Supports conversion to and from
ArrayBytes
- Supports conversion to and from
- Add
array::ElementFixedLength
marker trait - Add experimental
vlen
andvlen_v2
codec for variable length data typesvlen_v2
is for legacy support of Zarr V2vlen-utf8
/vlen-bytes
/vlen-array
codecs
- Add
DataType::{String,Binary}
data types- These are likely to become standardised in the future and are not feature gated
- Add
ArraySubset::contains()
- Add
FillValueMetadata::{String,Unsupported}
ArrayMetadata
can be serialised and deserialised with an unsupportedfill_value
, butArray
creation will fail.
- Implement
From<{[u8; N],&[u8; N],String,&str}>
forFillValue
- Add
ArraySize
andDataTypeSize
- Add
DataType::fixed_size()
that returnsOption<usize>
. ReturnsNone
for variable length data types. - Add
ArrayError::IncompatibleElementType
(replacesArrayError::IncompatibleElementSize
) - Add
ArrayError::InvalidElementValue
- Add
ChunkShape::num_elements_u64
- Add global
Config
option for manipulating experimental codec names - Add
metadata::v2::codec::ZfpyCodecConfigurationNumcodecs
and associated structures
- Use
[async_]retrieve_array_subset_opt
internally inArray::[async_]retrieve_chunks_opt
- Breaking: Replace
[Async]ArrayPartialDecoderTraits::element_size()
withdata_type()
- Array
_store
methods now useimpl Into<ArrayBytes<'a>>
instead of&[u8]
for the input bytes - Breaking: Array
_store_{elements,ndarray}
methods now useT: Element
instead ofT: bytemuck::Pod
- Breaking: Array
_retrieve_{elements,ndarray}
methods now useT: ElementOwned
instead ofT: bytemuck::Pod
- Breaking: Simplify array store
_ndarray
methods to 2 generic type parameters - Optimised
Array::[async_]store_array_subset_opt
when the subset is a subset of a single chunk - Make
transmute_to_bytes
public - Relax
ndarray_into_vec
fromT: bytemuck:Pod
toT: Clone
- Breaking:
DataType::size()
now returns aDataTypeSize
instead ofusize
- Breaking:
ArrayCodecTraits::{encode/decode}
have been specialised intoArrayTo{Array,Bytes}CodecTraits::{encode/decode}
- Various changes to the experimental
zfp
codec- Breaking: Remove
Zfp{Expert,FixedAccuracy,FixedPrecision,FixedRate}Configuration
and just embed these structures directly inZfpMode
- Breaking:
ZfpCodec::new_expert
now takesminbits
,maxbits
,maxprec
, andminexp
instead ofZfpExpertConfiguration
- Breaking: All
ZfpCodec::new_*
methods now take awrite_header: bool
parameter
- Breaking: Remove
- Breaking: Add
ArrayMetadataV2ToV3ConversionError::Other
- Make all v2 metadata available even without experimental codec features
- Breaking: Change pcodec
max_page_n
configuration toequal_pages_up_to
to match numcodecs - Improve the
Array
docs
- Breaking: Remove
into_array_view
array and codec API- This was not fully utilised, not applicable to variable sized data types, and quite unsafe for a public API
- Breaking: Remove internal
ChunksPerShardError
and just useCodecError::Other
- Breaking: Remove
array_subset::{ArrayExtractBytesError,ArrayStoreBytesError}
- Breaking: Remove
ArraySubset::{extract,store}_bytes[_unchecked]
, they are replaced by methods inArrayBytes
- Breaking: Remove
array::validate_element_size
andArrayError::IncompatibleElementSize
- The internal validation in array
_element
methods is now more strict than just matching the element size - Example:
u16
must matchuint16
data type and will not matchint16
orfloat16
- The internal validation in array
- Fix an unnecessary copy in
async_store_set_partial_values
- Fix error when
bytes
metadata is encoded without a configuration, even if empty - Fix an error in
ChunkGrid
docs - Fixed
[async_]store_set_partial_values
andMemoryStore::set
to correctly truncate the bytes of store value if they shrink
0.15.1 - 2024-07-11
- Add
CITATION.cff
- Implement
From<&String>
forDimensionName
- Cleanup macro usage in array
- Fix unnecessary allocations in
_elements
variants of array store methods
0.15.0 - 2024-07-07
- Zarr V2 support (a Zarr V3 compatible subset)
- Codec and array optimisations
- Array store methods previously taking
Vec<u8>
now take&[u8]
- Codec methods previously taking
Vec<u8>
now takeCow<'_, [u8]>
- Array store methods previously taking
AsyncToSyncStorageAdapter
: use an async store (e.g. HTTP, S3, etc.) in a sync context- Snappy codec support for the
blosc
codec
- Add support for a V3 compatible subset of Zarr V2
- Compatible subset: Zarr V2 data that is Zarr V3 compatible with only a metadata change
- Zarr V2 metadata (
.zarray
/.zgroup
/.zattrs
) can be transformed to V3 (zarr.json
)
- Add
ArrayBuilder::build_arc
method - Add
Array::[async_]retrieve_encoded_chunk[s]
method - Add
Group::metadata_opt
method - Add
{Array,Group}::{store,erase}_metadata_opt
methods - Add
metadata::Metadata{Retrieve,Convert,Erase}Version
enums - Add
Config::[set_]metadata_{convert,erase}_version
methods - Add
{Array,Group}MetadataOptions::[set_]metadata_convert_version
methods - Add
{Config,ArrayMetadataOptions}::[set_]include_zarrs_metadata
methods - Add
Array::set_dimension_names
- Add
storage::[Maybe]AsyncBytes
- Add
array::{convert_from_bytes_slice,convert_to_bytes_vec}
- Add
AdditionalField
- Add
AsyncToSyncStorageAdapter
andAsyncToSyncBlockOn
- Add internal
fill_array_view_with_fill_value
function
- Breaking: Deprecate
{Array,Group,Node}::[async_]new
for[async_]open
, and addopen_opt
- Breaking:
Array
store methods now take slices instead ofVec
s - Breaking: Change various store methods to take
&Arc<TStorage>
instead of&TStorage
- Breaking: Sync and async stores now consume and return
bytes::Bytes
instead ofVec<u8>
- Breaking:
{Array,Group}::metadata()
now return references instead of values - Breaking:
AdditionalFields
is now an alias forBTreeMap<String, AdditionalField>
instead of an opaque struct - Breaking: Move
[Async]ReadableStorageTraits::{size[_prefix]}
to[Async]ListableStorageTraits
and add default implementation forsize
- Use
monostate
forzarr_format
,node_type
, andmust_understand
in unknown fields in array and group metadata- These fields must be be valid on deserialisation rather than array/group initialisation
- Breaking: Remove associated field validation functions
- Support
object_store
0.9-0.10 - Breaking: Support
opendal
0.46-0.47, drop support for 0.45 - Bump
rayon
to 1.10.0 - Bump
itertools
to 0.13 - Bump
reqwest
to 0.12 - Bump
zip
to 2.1 - Bump
blosc-src
to 0.3.4- Adds
snappy
codec support
- Adds
- Bump minimum supported
flate2
to 1.0.30 andthiserror
to 1.0.61 - Add default implementations for
[Async]ReadableStorageTraits::{get,get_partial_values}
- Use
futures::TryStreamExt::try_for_each_concurrent
instead ofFuturesUnordered
where appropriate - Move all metadata/configuration structures into the metadata module (non breaking with re-exports)
- Rename
Metadata
toMetadataV3
, an alias is retained - Improve various docs
- Breaking: Add
MissingMetadata
toGroupCreateError
enum - Change internal structure of various iterators to use
std::ops::Range
and remove redundantlength
- Breaking:
Indices::new_with_start_end
now takes arange
rather than astart
andend
RecommendedConcurrency::new
takesimpl std::ops::RangeBounds<usize>
instead ofstd::ops::Range
- Breaking: Move
array::MaybeBytes
tostorage::MaybeBytes
- Breaking: Move
storage::storage_adapter::ZipStorageAdapter[CreateError]
tostorage::storage_adapter::zip::
- The
{async,sync}_http_array_read
examples now demonstrate usage ofopendal
andobject_store
storage backends - Bump
pcodec
to 0.3- Adds support for
uint16
,int16
andfloat16
data types to the experimentalpcodec
codec - Breaking: The schema for
PcodecCodecConfigurationV1
has changed
- Adds support for
- Exclude integration tests and data from published package
- Breaking: Remove re-exports of public dependencies
- Breaking: Remove
Array::set_include_zarrs_metadata
. Use{Config,ArrayMetadataOptions}::set_include_zarrs_metadata
- Breaking: Remove
ArrayMetadataV2ToV3ConversionError::InvalidZarrFormat
- Breaking: Remove
{Array,Group}CreateError::{InvalidZarrFormat,InvalidNodeType}
- Breaking: Change
ZfpExpertParams
toZfpExpertConfiguration
replacing existingZfpExpertConfiguration
- The previous
ZfpExpertConfiguration
was incorrect and was identical toZfpFixedRateConfiguration
- The previous
- Fix
FilesystemStore::list_prefix
with an empty prefix - Fix
storage::[async_]discover_nodes
and add tests
0.14.0 - 2024-05-16
- Breaking: Remove
store_locks
module,[Async]ReadableWritableStorageTraits::mutex()
, andnew_with_locks
constructors from storesDefaultStoreLocks
could result in a deadlock- It is now the responsibility of zarrs consumers to ensure that:
Array::store_chunk_subset
is not called concurrently on the same chunkArray::store_array_subset
is not called concurrently on regions sharing chunks
- Chunk locking may be revisited in a future release
0.13.3 - 2024-05-16
This release was yanked and changes reverted.
0.13.2 - 2024-05-08
- Make the
bz2
andpcodec
codecs public - The
"name"
of experimental codecs in array metadata now points to a URI to avoid potential future incompatibilities with other implementations - Improve docs of several experimental codecs
0.13.1 - 2024-05-06
- Added the
array_sharded_ext::{ArrayShardedExt,ArrayShardedReadableExt}
extension traits forArray
to simplify working with sharded arrays- Abstracts the chunk grid to an "inner chunk grid" to simplify inner chunk retrieval.
- Shard indexes are cached in a
ArrayShardedReadableExtCache
- Retrieval and chunk grid methods have fallbacks for unsharded arrays. For example, an inner chunk in an unsharded array is just a chunk
- Sync API only,
AsyncArrayShardedReadableExt
andAsyncArrayShardedReadableExtCache
are planned for a future release
- Added
ChunkGridTraits::chunks_subset()
with default implementation
- Allow float fill values to be created from int fill value metadata
- Make
chunk_grid::{regular,rectangular}
public - Support 8 and 16 bit integer data types with zfp codec by promoting to 32 bit
- Fix
compute_encoded_size()
forBitroundCodec
incorrectly indicating various data types were unsupported - Fix a link in chunk grid docs
- Fix incorrect minimum dependency versions and add CI check
- Fix clippy
unexpected_cfgs
warning with recent nightly
0.13.0 - 2024-04-20
- Add "experimental codec store metadata if encode only" option to global config
- Add "store empty chunks" option to global config and
CodecOptions
- Add
ArrayMetadataOptions
- Add small example to
README.md
and crate root documentation - Add
uint8
/int8
support to the bitround codec - Add
len()
andis_empty()
methods to array subset iterator producers - Add
Array::chunk_origin()
- Breaking: Bump MSRV to 1.75 (28 December, 2023)
- Bump
pco
(pcodec) to 0.2.1 - Breaking: Add
CodecTraits::create_metadata_opt()
- Breaking: Rename
data_type::IncompatibleFillValueErrorMetadataError
toIncompatibleFillValueMetadataError
- Add a useful warning if the shard index references out-of-bounds bytes in a chunk encoded with the sharding codec
- Breaking: Require
ndarray::Array
parameters in various async array methods to implementSend
- Fix implementation of
from_chunkgrid_regular_configuration
macro leading to recursion - Fix arithmetic overflow possible with the bitround codec with integer data types
- Address
todo!()
s inretrieve_chunks_into_array_view_opt
methods
0.12.5 - 2024-03-17
- Implement
TryFrom<&str>
for{Array,Group}Metadata
- Make
array::codec::array_to_bytes::bytes::{Endianness::is_native(),NATIVE_ENDIAN,reverse_endianness}
public
0.12.4 - 2024-03-09
- Remove unnecessary copy in
OpendalStore::set
- Fixed
zfp
codec encode not truncating compressed data zfp
codeccompute_encoded_size()
now correctly outputs a bounded size instead of an unbounded size
0.12.3 - 2024-03-07
- Implement
Deserialize
forDataType
- A convenience for
zarrs
consumers.ArrayMetadata
continues to useMetadata
to parse unknown data types.
- A convenience for
- Add
{Array,Group}::{async_}erase_metadata()
andstorage::{async_}erase_metadata()
- Fixed various errors in storage docs
- Blosc codec config allow deserialization with missing
typesize
/shuffle
- Blosc codec encoding with
typesize
of 0 with shuffling
0.12.2 - 2024-02-26
- Added "Getting Started" in root documentation
- Disabled
blosc
codec partial decoding pending a faster implementation
- Remove an unnecessary allocation in
IndicesIterator
0.12.1 - 2024-02-24
- Add
byte_range::extract_byte_ranges_concat()
- Add
{Async}BytesPartialDecoderTraits::partial_decode_concat()
with default implementation - Add
ArrayCodecTraits::partial_decode_granularity()
with default implementation
- Cleanup "Implementation Status" and "Crate Features" in root documentation
- Minor changes to docs
0.12.0 - 2024-02-22
- This release targeted:
- Improving performance and reducing memory usage
- Increasing test coverage (82% from 66% in v0.11.6)
- There are a number of breaking changes, the most impactful user facing changes are
Array
par_
variants have been removed and the default variants are now parallel instead of serialArray
_opt
variants use newCodecOptions
instead ofparallel: bool
ArraySubset
iter_
methods have had theiter_
prefix removed. Returned iterators now implementinto_iter()
and some also implementinto_par_iter()
Array::{set_}parallel_codecs
andArrayBuilder::parallel_codecs
have been removed. New methods supportingCodecOptions
offer far more concurrency controlDimensionName
s can now be created less verbosely. E.g.array_builder.dimension_names(["y", "x"].into())
. Type inference will fail on old syntax like.dimension_names(vec!["y".into(), "x".into()].into())
Array
store_ndarray
variants now take any type implementingInto<ndarray::Array<T, D>>
instead of&ndarray::ArrayViewD<T>
.
- Add
array::concurrency::RecommendedConcurrency
- Add
array::ArrayView
- Add array
into_array_view
methodsArray::{async_}retrieve_chunk{_subset}_into_array_view{_opt}
Array::{async_}retrieve_chunks_into_array_view{_opt}
Array::{async_}retrieve_array_subset_into_array_view{_opt}
- Add
Array::{async_}retrieve_chunk_if_exists{_elements,_ndarray}_{opt}
- Add
_opt
variants to various array store/retrieve methods - Add
Array::dimensionality()
- Add
Array::chunk_shape_usize()
- Add
codec::CodecOptions{Builder}
- Add
ArrayCodecTraits::decode_into_array_view
with default implementation - Add
{Async}ArrayPartialDecoderTraits::partial_decode_into_array_view{_opt}
with default implementation - Add
TestUnbounded
codec for internal testing
- Add
Contiguous{Linearised}IndicesIterator::contiguous_elements{_usize}()
- Implement
DoubleEndedIterator
for{Indices,LinearisedIndices,ContiguousIndices,ContiguousLinearisedIndicesIterator}Iterator
- Add
ParIndicesIterator
andParChunksIterator
- Add
Default Codec Concurrent Target
andDefault Chunk Concurrency Minimum
global configuration options toConfig
- Add
{Async}ReadableWritableListableStorageTraits
and{Async}ReadableWritableListableStorage
- Add
{Chunk,Array}Representation::shape_u64
- Implement
AsyncBytesPartialDecoderTraits
forstd::io::Cursor<{&[u8],Vec<u8>}>
- Implement
From<ChunkShape>
forVec<NonZeroU64>
- Add
ChunkShape::num_elements()
- Implement
From<String>
forDimensionName
- Add
array::unsafe_cell_slice::UnsafeCellSlice::len()
- Add
{Array,Chunk}Representation::dimensionality()
- Add
ArraySubset::new_empty()
andArraySubset::is_empty()
- Add missing
IncompatibleArraySubsetAndShapeError::new()
- Add
--usage-log
argument to examples to useUsageLog
storage transformer - Add more tests for
Array
, codecs, store locks, and more - Add
array_write_read_ndarray
example - Add
array::bytes_to_ndarray()
and makearray::elements_to_ndarray()
public - #13 Add
node::Node::path()
,metadata()
, andchildren()
by @lorenzocerrone - #13 Derive
Clone
fornode::Node
andnode::NodeMetadata
by @lorenzocerrone - Add
bytemuck
feature to thehalf
dependency (public)
- Breaking:
Array
_opt
methods now use acodec::CodecOptions
parameter instead ofparallel: bool
- Behaviour change: default variants without
_opt
are no longer serial but parallel by default - Breaking:
Array
store_ndarray
variants now take any type implementingInto<ndarray::Array<T, D>>
instead of&ndarray::ArrayViewD<T>
- This is to reflect that these methods consume the underlying
Vec
in the ndarray - It also removes the constraint that arrays have a dynamic dimension
- This is to reflect that these methods consume the underlying
- Breaking: remove
par_
variants and many_opt
variants in favor of a single method with acodec::CodecOptions
parameterpartial_decode
andpartial_decode_opt
remain- Behaviour change:
partial_decode
is no longer serial but parallel by default
- Breaking: add
{ArrayCodecTraits,BytesToBytesCodecTraits}::recommended_concurrency()
- Breaking: add
ArrayPartialDecoderTraits::element_size()
- Breaking:
ArraySubset::iter_
methods no longer have aniter_
prefix and return structures implementingIntoIterator
includingIndices
,LinearisedIndices
,ContiguousIndices
,ContiguousLinearisedIndices
,Chunks
Indices
andChunks
also implementIntoParallelIter
- Array subset iterators are moved into public
array_subset::iterators
and no longer in thearray_subset
namespace
- Breaking: Storage transformers must be
Arc
wrapped asStorageTransformerExtension
trait methods now takeself: Arc<Self>
- Breaking:
Group
andArray
methods generic on storage now require the storage have a'static
lifetime - Removed lifetimes from
{Async}{Readable,Writable,ReadableWritable,Listable,ReadableListable}Storage
- Breaking:
ArrayBuilder::dimension_names()
generalised to acceptOption<I>
whereI: IntoIterator<Item = D>
andD: Into<DimensionName>
- Can now write
builder.dimension_names(["y", "x"].into())
instead ofbuilder.dimension_names(vec!["y".into(), "x".into()].into())
- Can now write
- Breaking: Remove
Array::{set_}parallel_codecs
andArrayBuilder::parallel_codecs
- Breaking: Add
ChunkGridTraits::chunk_shape_u64{_unchecked}
toChunkGridTraits
- Breaking: Add
create{_async}_readable_writable_listable_transformer
toStorageTransformerExtension
trait - Breaking: Rename
IncompatibleArrayShapeError
toIncompatibleArraySubsetAndShapeError
- Breaking: Use
IncompatibleArraySubsetAndShapeError
inArrayStoreBytesError::InvalidArrayShape
- Breaking: Add
ArrayError::InvalidDataShape
- Add a fast path to
Array::retrieve_chunk_subset{_opt}
if the entire chunk is requested DimensionName::new()
generalised to accept a name implementingInto<String>
- Cleanup uninitialised
Vec
handling - Dependency bumps
- Make
UnsafeCellSlice
public
- Breaking: Remove
InvalidArraySubsetError
andArrayExtractElementsError
- Breaking: Remove non-default store lock constructors
- Breaking: Remove unused
storage::store::{Readable,Writable,ReadableWritable,Listable}Store
- Breaking:
ArraySubset::end_inc
now returns anOption
, which isNone
for an empty array subset Array::retrieve_array_subset
and variants now correctly return the fill value if the array subset references out-of-bounds elements- Add missing input validation to some
partial_decode
methods - Validate
ndarray
array shape in{async_}store_{chunk,chunks}_ndarray{_opt}
- Fixed transpose partial decoder and its test, elements were not being correctly transposed
- Minor docs fixes
0.11.6 - 2024-02-06
- Add a global configuration
config::Config
accessible viaconfig::{get_config,get_config_mut}
- Currently it exposes a single configuration option:
validate_checksums
(default:true
)
- Currently it exposes a single configuration option:
- Document correctness issues with past versions and how to correct errant arrays in crate root
0.11.5 - 2024-02-05
- Major bug Fixed the
crc32c
codec so it usesCRC32C
rather thanCRC32
- All arrays written prior to this release that use the
crc32c
codec are not correct
- All arrays written prior to this release that use the
- Fixed the
crc32c
codec reserving more memory than necessary
0.11.4 - 2024-02-05
- Add
codecov
support to CI
- Fixed a regression introduced in v0.11.2 (89fc63f) where codecs with an empty configuration would serialise as a string rather than a struct with a
name
field, which goes against the zarr spec- Fixes the
codec_bytes_configuration_none
test and addscodec_crc32c_configuration_none
test
- Fixes the
0.11.3 - 2024-01-31
- Added support for miri testing and accompanying notes in
BUILD.md
- Make
IDENTIFIER
public for codecs, chunk key encodings, and chunk grids
- Fix formatting of
pcodec
feature inlib.rs
docs - Remove
println!
inPcodecCodec
- Fixed
FillValue::equals_all
with unaligned inputs
0.11.2 - 2024-01-30
- Added experimental
bz2
(bzip2) codec behindbz2
feature - Added experimental
pcodec
codec behindpcodec
feature
- docs: clarify that
bitround
andzfp
codec configurations are draft
- Do not serialise
configuration
inMetadata
if is empty - Do not serialise
endian
inBytesCodecConfigurationV1
if it is none
0.11.1 - 2024-01-29
- Fixed build with
bitround
orzfp
features withoutasync
feature
0.11.0 - 2024-01-26
- This release targeted
- Improving documentation
- Increasing coverage and correctness (line coverage increased from 70.66% to 78.46% since
0.10.0
) - Consolidating and improving errors and their messages
- Major breaking changes
Array
retrieve_
methods now returnVec<u8>
/Vec<T>
instead ofBox<[u8]>
/Box<[T]>
- Added
ChunkShape
(which wrapsVec<NonZeroU64>
) and addedChunkRepresentation
- Chunks can no longer have any zero dimensions
- Creating an array now requires specifying a chunk shape like
vec![1, 2, 3].try_into()?
instead ofvec![1, 2, 3].into()
- Tests for
ByteRange
,BytesRepresentation
,StorePrefix
,StoreKey
,ArrayBuilder
,ArraySubset
,GroupBuilder
,Group
,NodeName
,NodePath
,Node
,AdditionalFields
,Metadata
,FillValue
,Group
,Metadata
array_subset::IncompatibleStartEndIndicesError
- Add
array::transmute_from_bytes_vec
- Re-export public dependencies at the crate root:
bytes
,bytemuck
,dyn_clone
,serde_json
,ndarray
,object_store
, andopendal
- Implement
Display
forByteRange
,StoreKeyRange
,NodeName
- Add
HexString::new
- Add
PluginMetadataInvalidError
- Breaking:
Array
retrieve_
methods now returnVec<u8>
/Vec<T>
instead ofBox<[u8]>
/Box<[T]>
- This avoids potential internal reallocations
- Breaking:
StoreKey::parent
now returnsStorePrefix
instead ofOption<StorePrefix>
- Breaking:
ZipStorageAdapter::{new,new_with_path}
now take aStoreKey
- Breaking:
ArraySubset::new_with_start_end_{inc,exc}
now returnIncompatibleStartEndIndicesError
instead ofIncompatibleDimensionalityError
- It is now an error if any element of
end
is less thanstart
- It is now an error if any element of
- Remove
#[must_use]
fromGroupBuilder::{attributes,additional_fields}
- Breaking: Rename
Node::new_with_store
toNode::new
, andNode::new
toNode::new_with_metadata
for consistency withArray
/Group
- Use
serde_json
float_roundtrip
feature - Breaking: Use
bytemuck
instead ofsafe_transmute
- Array methods now have
<T: bytemuck::Pod + ..>
instead of<T: safe_transmute::TriviallyTransmutable + ..>
- Array methods now have
- Breaking: Rename
array::safe_transmute_to_bytes_vec
toarray::transmute_to_bytes_vec
- Breaking: Make
zfp
a private dependency by changingZfp{Bitstream,Field,Stream}
frompub
topub(super)
- Breaking: Make
zip
a private dependency by not exposingZipError
inZipStorageAdapterCreateError
- Refine
UsageLogStorageTransformer
outputs and add docs - Improve
PerformanceMetricsStorageTransformer
docs - Breaking:
InvalidByteRangeError
now holds aByteRange
and bytes length and returns a more informative error message - Breaking: Remove
StorageError::InvalidJSON
and addStorageError::InvalidMetadata
InvalidMetadata
additionally holds aStoreKey
for more informative error messages
- More informative
Metadata
deserialisation error message with an invalid configuration - Breaking:
PluginCreateError::Other
changed to unit struct and addedPluginCreateError::from<{String,&str}>
PluginCreateError::Unsupported
now includes aplugin_type
field for more informative error messages- Add
array::ChunkShape
wrappingVec<NonZeroU64>
andarray::ChunkRepresentation
which is essentiallyArrayRepresentation
with aNonZeroU64
shape- Breaking: Relevant codec and partial decoder methods now use
ChunkRepresentation
instead ofArrayRepresentation
- Breaking: Relevant chunk grid methods now use
ChunkShape
instead ofArrayShape
- Breaking: Relevant array methods now use
ChunkShape
instead ofArrayShape
- Breaking: Relevant codec and partial decoder methods now use
- Breaking: Remove
StorePrefixError::new
, deprecated sincev0.7.3
- Breaking: Remove
ArraySubset::{in_subset,in_subset_unchecked}
, deprecated sincev0.7.2
- Breaking: Remove
impl From<&StorePrefix> for NodeName
, unused and not useful - Breaking: Remove
NodeCreateError::Metadata
NodeCreateError::StorageError
withStorageError::InvalidMetadata
is used instead
- Breaking: Remove
{ArrayCreateError,GroupCreateError}::MetadataDeserializationError
{ArrayCreateError,GroupCreateError}::StorageError
withStorageError::InvalidMetadata
is used instead
- Breaking: Remove
GroupCreateError::Metadata
as it was unused - Breaking: Remove
PluginCreateError::ConfigurationInvalidError
- Disallow an empty string for a
StoreKey
ArrayBuilder
now validates additional fieldsFillValue::equals_all
incorrect behaviour with aFillValue
with size not equal to 1, 2, 4, 8, or 16 bytes.- Fix
NodePath
display output - Fix handling of non-standard
NaN
values forf16
andbf16
- Fix potential missed error in
Metadata::to_configuration
0.10.0 - 2024-01-17
- Bump
opendal
to 0.44 - Bump
object_store
to 0.9 - Breaking
async_store_chunk
andAsyncWritableStorageTraits::set
now takebytes::Bytes
bytes::Bytes
are used by both supported async stores (object_store
andopendal
), and this avoids a copy
- Various clippy warnings
0.9.0 - 2024-01-03
- New
Array
methods to store/retrieve/erase multiple chunks - Many
Array
internal revisions and removal of some unnecessary methods
- Reexport
safe_transmute::TriviallyTransmutable
asarray::TriviallyTransmutable
- Add
Array::chunks_subset{_bounded}
- Add
store_chunks
,retrieve_chunks
,erase_chunks
and variants toArray
- Use macros to reduce common code patterns in
Array
- Separate
Array
methods into separate files for each storage trait - Breaking: Remove
_opt
andpar_
variants ofasync_retrieve_array_subset
andasync_store_array_subset
(including_elements
and_ndarray
variants) - Revise
array_write_read
andasync_array_write_read
examples - Breaking: Storage
erase
/erase_values
/erase_prefix
methods andArray::erase_chunk
now return()
instead ofbool
and succeed irrespective of the whether the key/prefix exists
0.8.0 - 2023-12-26
- Feature changes:
- Added:
object_store
andopendal
with generalised support for stores from these crates - Removed:
s3
,gcp
, andazure
(useobject_store
oropendal
instead) - Changed:
http
andzip
are no longer default features
- Added:
ReadableStorageTraits
is no longer a supertrait ofWritableStorageTraits
- Moved chunk locking from
Array
into stores - Improved documentation and code coverage
- Added
ReadableWritableStorage
andReadableWritableStore
and async variants - Added
{async_}store_set_partial_values
- Breaking Added
create_readable_writable_transformer
toStorageTransformerExtension
trait - Added
storage::store_lock
module- Adds generic
StoreLocks
,StoreKeyMutex
, andStoreKeyMutexGuard
with associated traits and async variants - Includes
DefaultStoreLocks
andDisabledStoreLocks
implementations
- Adds generic
- Readable and writable stores include a
new_with_locks
method to choose the store lock implementation - Added
ArraySubset::new_with_ranges
- Added
ByteRange::offset
- Added
object_store
feature withAsyncObjectStore
store (wrapsobject_store::ObjectStore
)- Breaking Removes the explicit
object_store
-based stores (e.g.AsyncAmazonS3Store
,AsyncHTTPStore
) - Breaking Removes the
object_store_impl
macro - Breaking Removes the
s3
,gcp
, andazure
crate features
- Breaking Removes the explicit
- Added
opendal
featureOpendalStore
store (wrapsopendal::BlockingOperator
)AsyncOpendalStore
store (wrapsopendal::Operator
)
- Breaking
ReadableStorageTraits
is no longer a supertrait ofWritableStorageTraits
WritableStorage
is no longer implicitly readable. UseReadableWritableStorage
- Breaking:
{Async}WritableStorageTraits::set_partial_values()
no longer include default implementations- Use new
{async_}store_set_partial_values
utility functions instead
- Use new
- Add
#[must_use]
toArray::builder
,Array::chunk_grid_shape
, andArrayBuilder::from_array
- Breaking Remove
http
andzip
from default features - Locking functionality for arrays is moved into stores
- Improved
Array
documentation - Add store testing utility functions for unified store testing
- Make various
Array
methods withparallel
parameterpub
- Remove
#[doc(hidden)]
from various functions which areunsafe
and primarily intended for internal use - Breaking Bump minimum supported rust version (MSRV) to
1.71
(13 July, 2023)
- Fixed
MemoryStore::get_partial_values_key
if given an invalid byte range, now returnsInvalidByteRangeError
instead of panicking
0.7.3 - 2023-12-22
- Add
From<ChunkKeyEncodingTraits>
forChunkKeyEncoding
- Add chunk key encoding tests
- Revise code coverage section in
BUILD.md
to usecargo-llvm-cov
- Increased code coverage in some modules
- Add
--all-features
to clippy usage inBUILD.md
andci.yml
- Fixed chunk key encoding for 0 dimensional arrays with
default
andv2
encoding - Fixed various clippy warnings
0.7.2 - 2023-12-17
ArraySubset::{extract_elements/extract_elements_unchecked}
andArrayExtractElementsError
- Add
ArraySubset::{overlap,overlap_unchecked}
andArraySubset::{relative_to,relative_to_unchecked}
- These replace
ArraySubset::{in_subset,in_subset_unchecked}
, which are now deprecated
- These replace
- Add
From<String>
forStorePrefixError
and deprecateStorePrefixError::new
- Fix
cargo test
withasync
crate feature disabled
0.7.1 - 2023-12-11
- Fix use of
impl_trait_projections
in{Array/Bytes}PartialDecoderCache
, which was only stabilised in Rust 1.74
0.7.0 - 2023-12-05
- Experimental
async
feature: Support async stores and array/group operations- See
async_array_write_read
andasync_http_array_read
examples
- See
- Experimental
s3
/gcp
/azure
features for experimental async Amazon S3/Google Cloud Storage/Microsoft Azure Blob Storage stores
- Add
storage_async
module with asynchronous storage traits:Async{Readable,Writable,Listable,ReadableListable}StorageTraits
- Implemented for
StorageHandle
- Add async filesystem/http/memory stores in
storage::store::async
module and a wrapper for any store provided by theobject_store
crate - Add async support to zarr
Group
andArray
- Add
Async{Readable,Writable,Listable,ReadableListable}Storage
- Add
StorageTransformerExtension::create_async_{readable,writable,listable,readable_listable}_transformer
- Add
Node::async_new_with_store
and implementstorage::async_get_child_nodes
- Add
async_array_write_read
andasync_http_array_read
examples - Add experimental
async
feature (disabled by default) - Add experimental async
Amazon S3
,Google Cloud
,Microsoft Azure
stores (untested)
- Bump itertools to
0.12
and zstd to0.13
- Set minimum supported rust version (MSRV) to
1.70
(1 June, 2023)- Required by
half
since2.3.1
(26 June, 2023)
- Required by
- Make
StoreKeyRange
andStoreKeyStartValue
clonable - Breaking: Remove
ReadableWritableStorageTraits
,ReadableWritableStorage
,ReadableWritableStore
, andStorageTransformerExtension::create_readable_writable_transformer
- These were redundant because
WritableStorageTraits
requiresReadableStorageTraits
since 6e69a4d
- These were redundant because
- Move sync stores to
storage::store::sync
- Move sync storage traits to
storage_sync.rs
- Move array sync storage trait impls into
array_sync.rs
- Use
required-features
for examples
0.6.0 - 2023-11-16
- Revisions for recent updates to the Zarr V3 specification (e.g. sharding
index_location
and removal of"order": "C"/"F"
from transpose codec) - API changes to improve usability
- Performance improvements and a few bug fixes
- Experimental
zfp
andbitround
codecs
- Breaking: Added
UnsupportedDataTypeError
- Breaking: Added
CodecError::UnsupportedDataType
- Added
array_subset::IncompatibleArrayShapeError
- Added
array_subset::iter_linearised_indices_unchecked
- Added parallel encoding/decoding to tests
- Added
array_subset::ArrayStoreBytesError
,store_bytes
, andstore_bytes_unchecked
- Added experimental
zfp
codec implementation behindzfp
feature flag (disabled by default) - Added experimental
bitround
codec implementation behindbitround
feature flag (disabled by default)- This is similar to numcodecs BitRound, but it supports rounding integers from the most significant set bit
- Added
ShardingCodecBuilder
- Added
ReadableListableStorage
,ReadableListableStorageTraits
,StorageTransformerExtension::create_readable_listable_transformer
- Added
ByteRange::to_range()
andto_range_usize()
- Added
StoreKeyStartValue::end()
- Added default implementation for
WritableStorageTraits::set_partial_values
WritableStorageTraits
now requiresReadableStorageTraits
- Added
From<&[u8]>
forFillValue
- Added
FillValue::all_equal
and fill value benchmark- Implements a much faster fill value test
- Added
Array::chunk_grid_shape
/chunk_subset
- Added
par_
variants for thestore_array_subset
/retrieve_array_subset
variants inArray
, which can encode/decode multiple chunks in parallel - Added
ArraySubset::bound
andArray::chunk_subset_bounded
- Added methods to
CodecChain
to retrieve underlying codecs - Added
Array::builder()
andArrayBuilder::from_array()
- Added more
ArrayBuilder
modifiers and made internals public - Added a fast path to
Array::retrieve_array_subset
methods if the array subset matches a chunk - Added
array::{ZARR_NAN_F64,ZARR_NAN_F32,ZARR_NAN_F16,ZARR_NAN_BF16}
which match the zarr nan bit representation on all implementations - Added
size_usize()
toArrayRepresentation
- Add generic implementations of storage supertraits (
ReadableWritableStorageTraits
andReadableListableStorageTraits
) - Add
size_prefix()
to stores
- Breaking:
array::data_type::DataType
is now marked#[non_exhaustive]
- Breaking: Promote the
r*
(raw bits),float16
andbfloat16
data types to standard data types inarray::data_type::DataType
, rather than extension data types- Breaking: Remove the crate features:
raw_bits
,float16
,bfloat16
- Breaking: Removes
array::data_type::RawBitsDataType/Bfloat16DataType/Float16DataType
- Breaking:
half
is now a required dependency
- Breaking: Remove the crate features:
- Breaking: Rename
TransposeCodec::new
tonew_with_configuration
- Breaking: Array subset methods dependent on an
array_shape
now use theIncompatibleArrayShapeError
error type instead ofIncompatibleDimensionalityError
- Breaking: Various array subset iterators now have validated
new
and unvalidatednew_unchecked
constructors - Blosc codec: disable parallel encoding/decoding for small inputs/outputs
- Bytes codec: optimise implementation
- Breaking:
ArrayToArrayCodecTraits::compute_encoded_size
andArrayToBytesCodecTraits::compute_encoded_size
can now return aCodecError
ArrayBuilder::build()
andGroupBuilder::build
now accept unsized storage- Breaking:
StoragePartialDecoder
now takes aReadableStorage
input sharded_array_write_read
example now prints storage operations and demonstrates retrieving inner chunks directly from a partial decoder- the zarrs version and a link to the source code is now written to the
_zarrs
attribute in array metadata, this can be disabled withset_include_zarrs_metadata(false)
- Breaking: Rename
FillValueMetadata::Uint
toUInt
for consistency with theDataType::UInt
variants. StorePrefix
,StoreKey
,NodeName
new
methods are now: impl Into<String>
- Breaking:
ArrayBuilder::dimension_names
now takes anOption
input, matching the output ofArray::dimension_names
- Breaking:
ArrayError::InvalidChunkGridIndicesError
now holds array indices directly, not achunk_grid::InvalidArrayIndicesError
- Breaking:
Array::chunk_array_representation
now returnsArrayError
instead ofInvalidChunkGridIndicesError
and thearray_shape
parameter is removed - Breaking:
Array::chunks_in_array_subset
now returnsIncompatibleDimensionalityError
instead ofArrayError
- Breaking:
ArraySubset::new_with_start_end_inc
/new_with_start_end_exc
now takeend: ArrayIndices
instead of `end: &[u64] - Breaking: Move
array_subset::validate_array_subset
toArraySubset::inbounds
- Allow out-of-bounds
Array::store_array_subset
andArray::retrieve_array_subset
- retrieved out-of-bounds elements are populated with the fill value
- Derive
Clone
forStorageTransformerChain
- Breaking:
ArrayBuilder::storage_transformers
useStorageTransformerChain
- Breaking: change
ArrayError::InvalidFillValue
toInvalidFillValueMetadata
and add a newInvalidFillValue
- Breaking: The transpose codec order configuration parameter no longer supports the constants "C" or "F" and must instead always be specified as an explicit permutation zarr-developers/zarr-specs #264
- Removes
TransposeOrderImpl
TransposeOrder
is now validated on creation/deserialisation andTransposeCodec::new
no longer returns aResult
- Removes
- Breaking: Change
HexString::as_bytes()
toas_be_bytes()
- Support
index_location
for sharding codec - Optimise
unravel_index
- Breaking: Array subset iterator changes
- Simplify the implementations
- Remove
next
inputs - Make constructors consistent, remove
inner
in constructors - Add
size_hint
to all iterators, implementExactSizeIterator
/FusedIterator
- Major breaking: Output boxed slices
Box<[..]>
from array retrieve methods instead ofVec<..>
- Major breaking: Input
Vec<..>
instead of&[..]
to array store methods- Supports some perf improvements
- Breaking: Change
BytesRepresentation
enum fromKnownSize(u64)
/VariableSize
toFixedSize(u64)
/BoundedSize(u64)
/UnboundedSize
- Preallocate sharding codec encoded output when the encoded representation has a fixed or bounded size
- Add
par_encode
forzstd
codec - Breaking: Codecs now must implement
encode_opt
,decode_opt
, andpartial_decoder_opt
- Breaking: Partial decoders now must implement
partial_decode_opt
and thedecoded_representation
is now supplied on creation, rather than when callingpartial_decode
/partial_decode_par
/partial_decode_opt
- Sharding partial decoder now decodes inner chunks in full rather than partially decoding them, this is much faster with some codecs (e.g. blosc)
- In future, this will probably become configurable
- Moved
storage/store/{key.rs,prefix.rs}
tostorage/{store_key.rs,store_prefix.rs}
- Bytes codec handling of complex and raw bits data types
- Additional debug assertions to validate input in array subset
_unchecked
functions - Breaking:
array_subset::iter_linearised_indices
now returns aResult<_, IncompatibleArrayShapeError>
, previously it could not fail even if thearray_shape
did not enclose the array subset - The
array_subset_iter_contiguous_indices3
test was incorrect as the array shape was invalid for the array subset ArraySubset::extract_bytes
now reserves the appropriate amount of memory- Sharding codec performance optimisations
FilesystemStore::erase_prefix
now correctly removes non-empty directories- Breaking:
ArrayBuilder::storage_transformers
remove#[must_use]
- Validate data type and fill value compatibility in
ArrayBuilder
- Handling of
"NaN"
fill values, they are now guaranteed to match the byte representation specified in the zarr v3 spec - Add a fast path to array retrieve methods which avoids a copy
- Optimise sharding codec decode by removing initial population by fill value
- Include checksum with
zstd
codec if enabled, previously this did nothing
- Breaking: Disabled data type extensions
array::data_type::DataType::Extension
. - Breaking: Remove
StoreExtension
traits - Breaking: Remove
chunk_grid::InvalidArrayIndicesError
/ChunkGridShapeError
- Breaking: Remove
ArrayError::InvalidArrayIndicesError
0.5.1 - 2023-10-10
- Tests for
DataType::fill_value_from_metadata
- A paragraph on concurrency in the
Array
docs
- Fix some docs typos
FillValueMetadata::try_as_uint/int
can both now handleFillValueMetadata::Uint/Int
Array::store_chunk
now erases empty chunks- Fixed a race in
Array::store_chunk_subset
and add a fast path if the subset spans the whole chunk - Fix complex number handling in
DataType::fill_value_from_metadata
- Fix byte arrays being interpreted as complex number fill value metadata
0.5.0 - 2023-10-08
MaybeBytes
an alias forOption<Vec<u8>>
- When a value is read from the store but the key is not found, the returned value is now
None
instead of an error indicating a missing key
- When a value is read from the store but the key is not found, the returned value is now
- Add
storage::erase_chunk
andArray::erase_chunk
- The
array_write_read
example is updated to demonstrateerase_chunk
- The
- Add
TryFrom::<&str>
forMetadata
andFillValueMetadata
- Add
chunk_key_encoding
andchunk_key_encoding_default_separator
toArrayBuilder
- Add
TryFrom<char>
forChunkKeySeparator
- Add
ArraySubset::new_with_start_end_inc/new_with_start_end_exc
- Add
codec::extract_byte_ranges_read
utility function to read byte ranges from aRead
source which does not supportSeek
- Breaking: Remove
StorageError::KeyNotFound
in favour of returningMaybeBytes
- Breaking: Add
StorageError::UnknownKeySize
if a method requires a known key size, but the key size cannot be determined - Breaking: Add
ArrayCreateError::MissingMetadata
if attempting to create an array in a store without specifying metadata, and the metadata does not exist - Breaking:
UsageLogStorageTransformer
now takes a prefix function rather than a string- The
http_array_read
example now logs store requests to stdout usingUsageLogStorageTransformer
- The
- Breaking:
WritableStorageTraits::erase/erase_values/erase_prefix
return a boolean indicating if they actually deleted something - Breaking: Add
ReadableStorageTraits::get_partial_values_key
which reads byte ranges for a store key - Breaking: Changed
data_type::try_create_data_type
toDataType::from_metadata
- Breaking: Changed
try_create_codec
toCodec::from_metadata
- Make
ArrayBuilder
andGroupBuilder
non-consuming - Add a fast-path to
Array::store_array_subset
if the array subset matches a chunk subset - Breaking: Make
ChunkKeyEncoding
a newtype.- Breaking: Changed
try_create_chunk_key_encoding
toChunkKeyEncoding::from_metadata
.
- Breaking: Changed
- Breaking: Make
ChunkGrid
a newtype.- Breaking: Changed
try_create_chunk_grid
toChunkGrid::from_metadata
.
- Breaking: Changed
- Breaking: Rename
StorageTransformerChain::new_with_metadatas
tofrom_metadata
- Breaking: Rename
CodecChain::new_with_metadatas
tofrom_metadata
- Breaking: Rename
DataTypeExtension::try_create_fill_value
tofill_value_from_metadata
- Breaking: Rename
codec::extract_byte_ranges_rs
toextract_byte_ranges_read_seek
BytesCodec
now defaults to native endian encoding as opposed to no encoding (only valid for 8 bit data types).storage::get_child_nodes
andNode::new_with_store
now correctly propagate storage errors instead of treating all errors as missing metadataGroup::new
now handles an implicit group (with a missingzarr.json
)ZipStore
handle missing filesZipStore
no longer reads an internal file multiple times when extracting multiple byte rangesHTTPStore
improve error handling, check status codes
0.4.2 - 2023-10-06
- Add
From<&str>
andFrom<String>
forOther
variants ofCodecError
,StorageError
,ChunkGridShapeError
,StorePluginCreateError
- Support parallel encoding, parallel decoding, and partial decoding with the
blosc
codec- Previously the blosc codec would read the whole chunk when partial decoding
HTTPStore
range requests are now batched by default
- Fixed
retrieve_chunk_subset
returning fill values on anyStorageError
instead of justStorageError::KeyNotFound
0.4.1 - 2023-10-04
- Add
StorageHandle
, a clonable handle to borrowed unsized storage
- Support unsized storage (
TStorage: ?Sized
everywhere)
0.4.0 - 2023-10-04
- Readable and listable
ZipStorageAdapter
behindzip
feature - Readable
HTTPStore
behindhttp
feature - Add
StorageValueIO
, astd::io::Read
interface to a storage value. - Add
zip_array_write_read
andhttp_array_read
examples
- Relax some dependency minimum versions
- Add
size_hint()
to some array subset iterators - Breaking: Fix
LinearisedIndicesIterator
to use array shape instead of subset shapeLinearisedIndicesIterator::new
andArraySubset::iter_linearised_indices
now requirearray_shape
parameter
- Breaking: Array subset shape no longer needs to be evenly divisible by chunk shape when creating a chunk iterator
- Removes
ChunksIteratorError
- Removes
- Add array subset iterator tests
- Breaking: Remove unvalidated
from(String)
for store key/prefix - Validate that store prefixes and keys do not start with
/
- Breaking: Add
StorageError::Other
andStorageError::Unsupported
variants - Breaking
FilesystemStore
now accepts a file and does not create directory on creation- adds
FilesystemStoreCreateError:InvalidBasePath
and removesFilesystemStoreCreateError:InvalidBaseDirectory/ExistingFile
- adds
- Breaking:
ReadableStorageTraits::size()
tou64
fromusize
- Breaking: Add
ReadableStorageTraits::size_key()
- Storage and store traits no longer require
Debug
- Add a default implementation for
WritableStorageTraits::erase_values
- Make array/group explicitly store
Arc<TStorage>
StorageTransformerChain
now only acceptsArc
storage.- Breaking: Various group methods are now
#[must_use]
- Change
NodePath
internal representation toPathBuf
- Remove unneeded '/' prefix strip in
StorePrefix
- Breaking: Remove storage trait implementations for
Arc<TStorage>
, now must explicitly deref - Implement
Eq
andPartialEq
forDataType
- Breaking: Use
u64
instead ofusize
for byte ranges/array index/shape etc. This makes it possible to index into larger arrays on 32-bit systems.
- Fix store prefix to node path conversion and vice versa
- Fix
StorePrefix::parent()
so it outputs a validStorePrefix
- Fix
StoreKey::parent()
for top level keys, e.g"a"
now has parent prefix"/"
instead ofNone
- Print root node with
Node::hierarchy_tree
0.3.0 - 2023-09-27
- Add
CHANGELOG.md
- Require the
ndarray
feature for examples - Remove the
ndarray
dev dependency - Remove the
ndarray
dependency for thesharding
feature - Replace deprecated
tempdir
withtempfile
for tests - Breaking: Change
ByteRange
enum to haveFromStart
andFromEnd
variants - Substitute
blosc
dependency forblosc-src
which builds blosc from source - Breaking: Rename
compression
field tocname
inBloscCodecConfigurationV1
for consistency with the zarr spec
0.2.0 - 2023-09-25
- Initial public release