@@ -18,8 +18,10 @@ Highly experimental, pre-alpha. Bug reports and pull requests very welcome.
18
18
## Design goals
19
19
20
20
* Chunking in multiple dimensions
21
+ * Resize any dimension
21
22
* Concurrent reads
22
23
* Concurrent writes
24
+ * Release the GIL during compression and decompression
23
25
24
26
## Usage
25
27
@@ -41,7 +43,7 @@ zarr.ext.Array((10000, 1000), int32, chunks=(1000, 100), nbytes=38.1M, cbytes=0,
41
43
Fill it with some data:
42
44
43
45
``` python
44
- >> > z[:] = np.arange(10000000 , dtype = ' i4' ).reshape(( 10000 , 1000 ) )
46
+ >> > z[:] = np.arange(10000000 , dtype = ' i4' ).reshape(10000 , 1000 )
45
47
>> > z
46
48
zarr.ext.Array((10000 , 1000 ), int32, chunks = (1000 , 100 ), nbytes = 38. 1M , cbytes = 2. 0M , cratio = 19.3 , cname = blosclz, clevel = 5 , shuffle = 1 )
47
49
@@ -73,6 +75,23 @@ zarr.ext.Array((20000, 1000), int32, chunks=(1000, 100), nbytes=76.3M, cbytes=4.
73
75
74
76
```
75
77
78
+ For convenience, an ` append ` method is available, which can be used to
79
+ append data to any axis:
80
+
81
+ ``` python
82
+ >> > a = np.arange(10000000 , dtype = ' i4' ).reshape(10000 , 1000 )
83
+ >> > z = zarr.array(a, chunks = (1000 , 100 ))
84
+ >> > z
85
+ zarr.ext.Array((10000 , 1000 ), int32, chunks = (1000 , 100 ), nbytes = 38. 1M , cbytes = 2. 0M , cratio = 19.3 , cname = blosclz, clevel = 5 , shuffle = 1 )
86
+ >> > z.append(a+ a)
87
+ >> > z
88
+ zarr.ext.Array((20000 , 1000 ), int32, chunks = (1000 , 100 ), nbytes = 76. 3M , cbytes = 3. 6M , cratio = 21.2 , cname = blosclz, clevel = 5 , shuffle = 1 )
89
+ >> > z.append(np.vstack([a, a]), axis = 1 )
90
+ >> > z
91
+ zarr.ext.Array((20000 , 2000 ), int32, chunks = (1000 , 100 ), nbytes = 152. 6M , cbytes = 7. 6M , cratio = 20.2 , cname = blosclz, clevel = 5 , shuffle = 1 )
92
+
93
+ ```
94
+
76
95
## Tuning
77
96
78
97
`` zarr `` is designed for use in parallel computations working chunk-wise
@@ -88,5 +107,5 @@ the correlation structure in your data.
88
107
## Acknowledgments
89
108
90
109
`` zarr `` uses [ c-blosc] ( https://github.com/Blosc/c-blosc ) internally for
91
- compression and decompression, and borrows code heavily from
110
+ compression and decompression and borrows code heavily from
92
111
[ bcolz] ( http://bcolz.blosc.org/ ) .
0 commit comments