Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
21 commits
Select commit Hold shift + click to select a range
faa5ef5
feat: add IndexTransform library for composable, lazy coordinate mapp…
d-v-b Apr 14, 2026
732dddd
Merge branch 'main' into refactor/simplify-indexing
d-v-b Apr 14, 2026
79cd9c8
feat: add JSON serialization for IndexTransform (TensorStore-compatible)
d-v-b Apr 14, 2026
db31317
Merge branch 'main' into refactor/simplify-indexing
d-v-b Apr 15, 2026
797b25e
Merge branch 'main' into refactor/simplify-indexing
d-v-b Apr 16, 2026
9f50a4c
Merge branch 'main' into refactor/simplify-indexing
d-v-b Apr 21, 2026
53c0042
Merge branch 'main' into refactor/simplify-indexing
d-v-b Apr 22, 2026
1477f92
Merge branch 'main' into refactor/simplify-indexing
d-v-b May 6, 2026
e3927be
Merge branch 'main' of https://github.com/zarr-developers/zarr-python…
d-v-b May 6, 2026
2989756
Merge branch 'main' into refactor/simplify-indexing
d-v-b May 11, 2026
ed9167c
Merge branch 'main' into refactor/simplify-indexing
d-v-b May 18, 2026
0cf74f9
Merge branch 'main' into refactor/simplify-indexing
d-v-b May 19, 2026
ce78f48
rename accessor to lazy, and use result instead of resolve
d-v-b May 19, 2026
6bd22dc
Merge branch 'main' into refactor/simplify-indexing
d-v-b Jun 8, 2026
93e8c94
perf: cache Array shape/ndim and reuse chunk grid in transform resolvers
d-v-b Jun 29, 2026
ab795ca
perf: skip the transform resolver for eager (identity-transform) inde…
d-v-b Jun 29, 2026
b43023a
perf(lazy): resolve chunk_grid[coords] once per chunk in transform re…
d-v-b Jun 29, 2026
32cd3af
perf(lazy): single-pass sub_transform_to_selections with hoisted doma…
d-v-b Jun 29, 2026
f16ce13
fix(indexing): restore type narrowing and memoize shape on IndexDomain
d-v-b Jun 29, 2026
cd217c7
docs: update Array repr doctests for domain= suffix
d-v-b Jun 29, 2026
22db497
Merge branch 'main' into refactor/simplify-indexing
d-v-b Jun 29, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions src/zarr/api/synchronous.py
Original file line number Diff line number Diff line change
Expand Up @@ -1138,20 +1138,20 @@ def from_array(
... )
>>> arr2 = zarr.from_array(store, data=arr, overwrite=True)
>>> arr2
<Array file://example_from_array.zarr shape=(100, 100) dtype=int32>
<Array file://example_from_array.zarr shape=(100, 100) dtype=int32 domain={ [0, 100), [0, 100) }>
>>> asyncio.run(store.clear()) # Remove files generated by test

Create an array from an existing NumPy array:

>>> import numpy as np
>>> zarr.from_array({}, data=np.arange(10000, dtype="i4").reshape(100, 100))
<Array memory://... shape=(100, 100) dtype=int32>
<Array memory://... shape=(100, 100) dtype=int32 domain={ [0, 100), [0, 100) }>

Create an array from any array-like object:

>>> arr3 = zarr.from_array({}, data=[[1, 2], [3, 4]])
>>> arr3
<Array memory://... shape=(2, 2) dtype=int64>
<Array memory://... shape=(2, 2) dtype=int64 domain={ [0, 2), [0, 2) }>
>>> arr3[...]
array([[1, 2], [3, 4]])

Expand All @@ -1160,7 +1160,7 @@ def from_array(
>>> arr4 = zarr.from_array({}, data=[[1, 2], [3, 4]])
>>> arr5 = zarr.from_array({}, data=arr4, write_data=False)
>>> arr5
<Array memory://... shape=(2, 2) dtype=int64>
<Array memory://... shape=(2, 2) dtype=int64 domain={ [0, 2), [0, 2) }>
>>> arr5[...]
array([[0, 0], [0, 0]])
"""
Expand Down
Loading
Loading