-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Validate
vlen
codec length32
encoding against zarr-python
v2
- Loading branch information
Showing
100 changed files
with
88 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
{ | ||
"chunks": [ | ||
1000 | ||
], | ||
"compressor": null, | ||
"dtype": "|O", | ||
"fill_value": "", | ||
"filters": [ | ||
{ | ||
"id": "vlen-utf8" | ||
} | ||
], | ||
"order": "C", | ||
"shape": [ | ||
47868 | ||
], | ||
"zarr_format": 2 | ||
} |
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
import zarr # v2 | ||
import pandas as pd | ||
|
||
print(zarr.__version__) | ||
|
||
df = pd.read_csv("tests/data/cities.csv", header=None) | ||
cities = df[0] | ||
|
||
path_out = 'tests/data/v2/cities.zarr' | ||
array = zarr.open(path_out, mode='w', dtype=str, shape=(len(cities),), chunks=(1000,), compressor = None, fill_value='') | ||
array[:] = cities.values | ||
print(array.info) | ||
|
||
for i in range(48): | ||
v2 = open(f'tests/data/v2/cities.zarr/{i}', 'rb').read() | ||
v3 = open(f'tests/data/v3/cities.zarr/c/{i}', 'rb').read() | ||
assert v2 == v3 | ||
|
||
print("V2 and V3 chunks are identical!") |
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
{ | ||
"zarr_format": 3, | ||
"node_type": "array", | ||
"shape": [ | ||
47868 | ||
], | ||
"data_type": "string", | ||
"chunk_grid": { | ||
"name": "regular", | ||
"configuration": { | ||
"chunk_shape": [ | ||
1000 | ||
] | ||
} | ||
}, | ||
"chunk_key_encoding": { | ||
"name": "default", | ||
"configuration": { | ||
"separator": "/" | ||
} | ||
}, | ||
"fill_value": null, | ||
"codecs": [ | ||
{ | ||
"name": "vlen", | ||
"configuration": { | ||
"encoding": "length32" | ||
} | ||
} | ||
], | ||
"attributes": { | ||
"_zarrs": { | ||
"description": "This array was created with zarrs", | ||
"repository": "https://github.com/LDeakin/zarrs", | ||
"version": "0.16.0" | ||
} | ||
} | ||
} |