You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently, there are three things we have to change manually after creating a .zarr file with anemoi-datasets:
Change frequency from "1h" to 1 (already done in set_ds_frequency.py)
There are two places where resolution is defined in .zarr. In the first location resolution is set to "o96", whereas in the second location it is set to "null". "null" has to be changed to "o96" (or whatever the resolution is set to).
When creating a dataset with only one variable, e.g. the surface mask (at z=0), the variable name is set to "" in .zattrs of the .zarr file. This means that anemoi-training is not able to extract the variable, as it does not have a name. Add functionality to set_ds_frequency.py to handle this.
For a variable named "land_binary_mask_0" the changes would look like this:
"variables": [ "variables": [
"" ------> "land_binary_mask_0"
] ]
inakbk
changed the title
Build upon set_ds_frequency.py to update all necessarry attributes in .zarr
Datasets: Build upon set_ds_frequency.py to update all necessarry attributes in .zarr
Dec 19, 2024
For some reason it seems that I didn't have to change variable name for "h" in "h_norkyst_2024.zarr" manually, even though there is only a single variable included here (like had to be done with the mask dataset). Strange.
A check to see if all variables are named, and then add correct names should still be added to set_ds_frequency.py.
Currently, there are three things we have to change manually after creating a .zarr file with anemoi-datasets:
Change frequency from "1h" to 1 (already done in set_ds_frequency.py)
There are two places where resolution is defined in .zarr. In the first location resolution is set to "o96", whereas in the second location it is set to "null". "null" has to be changed to "o96" (or whatever the resolution is set to).
When creating a dataset with only one variable, e.g. the surface mask (at z=0), the variable name is set to "" in .zattrs of the .zarr file. This means that anemoi-training is not able to extract the variable, as it does not have a name. Add functionality to set_ds_frequency.py to handle this.
For a variable named "land_binary_mask_0" the changes would look like this:
"variables": [ "variables": [
"" ------> "land_binary_mask_0"
] ]
And:
"variables_metadata": { "variables_metadata":{
"": { "land_binary_mask_0":{
"mars": { "mars":{
"date": "20240101", "date": "20240101"
"step": 0, "step": 0,
"time": "0000", ------> "time": "0000",
"valid_datetime": "2024-01-01T00:00:00", "valid_datetime": "2024-01-01T00:00:00",
"variable": "land_binary_mask" "variable": "land_binary_mask"
} }
} }
}, },
The text was updated successfully, but these errors were encountered: