enscg commited on
Commit
d6ea0c5
·
verified ·
1 Parent(s): efde9aa

Update sample README

Browse files
Files changed (1) hide show
  1. zarr_sample/README.md +58 -19
zarr_sample/README.md CHANGED
@@ -1,37 +1,76 @@
1
  # calvdb — Dataset Sample
2
 
3
- This folder contains a small sample of the full **calvdb** dataset, provided so that reviewers can inspect the data format without downloading the complete archive (6.02 GB).
 
 
 
4
 
5
- ## Contents
 
6
 
7
- The sample includes Braasvellbreen glacier (RGI60-07.00025) taken from the **train split** of the benchmark.
 
 
8
 
9
- ## How the sample was created
10
 
11
- Each Zarr store in this folder is taken directly from the full dataset without modification. The stores were copied from the full `zarr_zipped/` collection and are structurally identical to every other glacier store in calvdb.
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
12
 
13
  ## Zarr store structure
14
 
15
- Each glacier is stored as a Zarr v3 group (zstd compression). Opening any store reveals the following arrays:
 
16
 
17
  | Array | Shape | Description |
18
  |---|---|---|
19
- | `sdt` | `(T, H, W)` | Signed distance transform of the calving front; values clipped to ±2000 m |
20
  | `imagery` | `(T, 5, H, W)` | Multispectral imagery: blue, green, red, NIR, SWIR-1 |
21
- | `geophys` | `(T, 6, H, W)` | Geophysical channels: bed elevation, surface elevation, ice thickness, surface velocity, strain rate, ice–fjord mask |
22
- | `climate` | `(T, 2)` | Climate forcing: surface runoff, ocean temperature |
23
- | `trace` | `(T, H, W)` | Rasterised calving-front line (used for evaluation only, not a model input) |
24
- | `dates` | `(T,)` | Observation dates in YYYY-MM-DD format |
25
- | `valid_sdt` | `(T,)` | Boolean mask True if the SDT observation is valid |
26
- | `valid_img` | `(T,)` | Boolean mask — True if the imagery observation is valid |
27
- | `valid_clm` | `(T,)` | Boolean mask — True if the climate observation is valid |
28
- | `valid_trace` | `(T,)` | Boolean mask — True if the trace observation is valid |
29
- | `sensors` | `(T,)` | Sensor identifier for each imagery observation |
30
 
31
- All arrays share the same time axis `T`. Spatial dimensions `H × W` vary per glacier. Spatial resolution is 30 m; CRS is EPSG:3995 (Arctic Polar Stereographic).
 
32
 
33
- > **Note on `ice_fjord_mask` (geophys channel 5):** Although `ice_fjord_mask` is stored in the zarr archive as geophysical channel 5 for completeness, it is excluded from the model input tensor in the baseline experiments due to inaccuracies in the mask boundary for several glaciers. It is retained in the dataset to support future work that may use or improve upon this variable.
 
 
 
34
 
35
  ## Further details
36
 
37
- - **Full dataset, splits and normalization:** see the main [README](../README.md)
 
 
1
  # calvdb — Dataset Sample
2
 
3
+ This folder holds one glacier from **calvdb**, left **unzipped** so you can inspect
4
+ the store layout in the file browser above without downloading the full dataset
5
+ (5.4 GB). Click into `RGI60-07.00025.zarr/` and open any `zarr.json` to see the
6
+ shape, dtype, chunking and dimension names of an array.
7
 
8
+ The sample is Braasvellbreen (RGI60-07.00025), 55 observations, from the **train**
9
+ split. Its arrays are identical to `zarr_zipped/RGI60-07.00025.zarr.zip`.
10
 
11
+ > **For actual use, download from [`zarr_zipped/`](../zarr_zipped) instead** one
12
+ > file of 275 MB rather than the 617 loose files here, and readable without
13
+ > unzipping. This copy exists for browsing.
14
 
15
+ ## Reading it
16
 
17
+ Requires **zarr >= 3.0** and **Python >= 3.11**. These are Zarr **format 3** stores;
18
+ zarr-python 2.x cannot read them and fails with
19
+ `GroupNotFoundError: group not found at path ''`. See the
20
+ [main README](../README.md#requirements) for the full requirements and
21
+ troubleshooting.
22
+
23
+ ```python
24
+ import zarr
25
+ from huggingface_hub import snapshot_download
26
+
27
+ path = snapshot_download(
28
+ repo_id="enscg/calvdb",
29
+ repo_type="dataset",
30
+ allow_patterns="zarr_sample/RGI60-07.00025.zarr/*",
31
+ )
32
+ group = zarr.open_group(f"{path}/zarr_sample/RGI60-07.00025.zarr", mode="r")
33
+ print(group["sdt"].shape) # (55, 541, 1052)
34
+ ```
35
+
36
+ The zipped archives are read the same way but without unzipping:
37
+
38
+ ```python
39
+ store = zarr.storage.ZipStore("RGI60-07.00025.zarr.zip", mode="r")
40
+ group = zarr.open_group(store, mode="r")
41
+ ```
42
+
43
+ A complete runnable example is in
44
+ [`example_loading.ipynb`](../example_loading.ipynb).
45
 
46
  ## Zarr store structure
47
 
48
+ Each glacier is a Zarr v3 group (zstd compression) with `T` observations on an
49
+ `H × W` grid:
50
 
51
  | Array | Shape | Description |
52
  |---|---|---|
53
+ | `sdt` | `(T, H, W)` | Signed distance transform of the calving front, metres, clipped ±2000; the front is the zero level set |
54
  | `imagery` | `(T, 5, H, W)` | Multispectral imagery: blue, green, red, NIR, SWIR-1 |
55
+ | `geophys` | `(T, 6, H, W)` | Bed elevation, surface elevation, ice thickness, surface velocity, strain rate, ice–fjord mask |
56
+ | `climate` | `(T, 2)` | Surface runoff, ocean temperature |
57
+ | `trace` | `(T, H, W)` | Rasterised calving-front line (evaluation only, not a model input) |
58
+ | `dates` | `(T,)` | Observation dates, YYYY-MM-DD |
59
+ | `sensors` | `(T,)` | Sensor code: `0=S2, 1=LE07, 2=LC08, 3=LC09, 255=unknown` |
60
+ | `valid_sdt` | `(T,)` | True if the SDT observation is valid |
61
+ | `valid_img` | `(T,)` | True if the imagery observation is valid |
62
+ | `valid_clm` | `(T,)` | True if the climate observation is valid |
63
+ | `valid_trace` | `(T,)` | True if the trace observation is valid |
64
 
65
+ All arrays share the same time axis `T`. Spatial dimensions `H × W` vary per
66
+ glacier. Resolution is 30 m; CRS is EPSG:3995 (Arctic Polar Stereographic).
67
 
68
+ > **Note on `ice_fjord_mask` (geophys channel 5):** it is stored for completeness
69
+ > but excluded from the model input tensor in the baseline experiments, because
70
+ > the mask boundary is inaccurate for several glaciers. It is retained to support
71
+ > future work that may use or improve upon this variable.
72
 
73
  ## Further details
74
 
75
+ - **Full dataset, requirements, splits and normalisation:** see the main
76
+ [README](../README.md)