Maybe we should start with adding a module to generate small and simple xarray Datasets with all the input variables we need to get started (e.g., the equivalent of NEMO coordinates/bathymetry files).
Say we are developing/testing/benchmarking a new function, we can just do something like:
from pydomcfg.datasets import flat_bathy_ds
def create_domain_cfg(ds: Dataset, ...):
...
return domain_cfg_ds
create_domain_cfg(flat_bathy_ds)
The real case scenario would become something like:
import pydomcfg
import xarray as xr
ds = xr.open_dataset("bathymetry_orca1.nc")
domain_cfg_ds = pydomcfg.create_domain_cfg(ds)
domain_cfg_ds.to_netcdf("domain_cfg_orca1.nc")
This way everything we need to develop is self-contained and we don't have to use/share files with data.
Maybe we should start with adding a module to generate small and simple xarray Datasets with all the input variables we need to get started (e.g., the equivalent of NEMO coordinates/bathymetry files).
Say we are developing/testing/benchmarking a new function, we can just do something like:
The real case scenario would become something like:
This way everything we need to develop is self-contained and we don't have to use/share files with data.