Conversation
Adds: - `read_zarr` and `write_zarr` methods which fall back to pickle if no zarr store is available. - Warnings that read_pickle methods will be deprecated for future GlacierDirectories. - Zarr as a core dependency. Refs: OGGM#1903
Adds:
- Validation for different zarr/pickle stores to maintain backwards
compatibility.
- Dedicated module for zarr-related operations.
- Conversion between existing pickles and zarr.
- Reconstruction of OGGM objects from minimum possible data.
Refactors:
- Replaces all instances of `read_pickle` with `read_store`.
Compatibility is maintained
Currently writes each data set to a separate file instead of a larger data store
ON-60 write data to zarr
Falls back to pickle if zarr r/w fails Refs: ON-60
… into ON-60-write-data-to-zarr
also removes hardcoded pickles
Merge fix pickle on 60 on 63
ON-60 write data to zarr
fix(workflow): replacement zarr groups
Remove multiple if statements and replace with dedicated method
|
Review notes from today's meeting @fmaussion, @pat-schmitt.
@fmaussion your suggestions for expanding scope:
|
|
thanks for the meeting @gampnico ! Quick notes:
Mh, more the other way around? Artifacts should be "child-agnostic". Some deltas need a very specific parent, while some deltas (briefly mentioned this morning) should be parent-fixed and others might be "parent-flexible".
To me, materialisations aren't niche but the main case from the user perspective: all of the gdirs they will build locally are materialisations. A materialisations hence needs to know all the parents it was built from, which parameter settings they used, which tasks were run, etc. not only incremental anymore.
yes
I grew quite accustomed to "artifact" today!
Agreed that some id would be good. |
This adds a lot of boilerplate code, but it's easier to test and develop than the previous design with logic statements.
Quick little utility that used to be part of geozarr.py
Workaround for datetime64 at ns, which uses an int that can't be decoded without a unit.
…-gdirs This commit is expected to fail as it introduces conflicts between npz and zarr
It's finally here!
For an easier-to-read demonstration of the new system, download and try the notebook:
Features
utils/compat.py, with support for multiple base URLs and checks to make sure datasets are compatible. You can convert any region, number or combination of RGI IDs.zarrnpz.Overview
This changes the default glacier directory system from cumulative levels to incremental ones. Most levels on the cluster are now deltas, which contain only the files that are different or added relative to the previous levels. Clients layer levels they need into a single glacier directory, which now contain manifests to track changes and identify datasets.
L3 and L5 datasets are standalone. L3 because there are differences in certain files between L1 and L3 e.g. inversion_flowlines, and L5 because it's a "minimal" preset. I'm calling a combination of levels a "materialisation".
Every prepro level comes with a manifest, and creating a glacier directory now works by layering the levels they need into one glacier directory. Legacy datasets keep working via a fallback that treats them as cumulative materialisations.
Points for Discussion
fsspecandxarrayto pick and mix the data we want without downloading it first!TODO:
Closes #1900
Refs: #1896
whats-new.rst