xoa.grid.decode_cf_dz2depth¶
- xoa.grid.decode_cf_dz2depth(ds, errors='raise', **kwargs)[source]¶
Compute depth from layer thickness in a dataset
Needed stuff is inferred from CF conventions.
- Parameters
ds (xarray.Dataset) – Dataset than contains everything
errors ({'ignore', 'warn', 'raise'}) –
In case of errors
ignore: silently ignorewarn: emit a warningraise: raise an exception
kwargs (dict) – Extra keywords are passed to
dz2depth()
- Returns
xarray.Dataset – A new dataset with a depth coordinate
See also