Deepak Cherian
Deepak Cherian
Now the error is ``` NotImplementedError: Could not find any pre-defined interp grid ufuncs with signature (X:center)->(X:center) ``` for ``` python dataset.map( grid.interp, axis=("X", "Y"), to="center" ) ```
> before it even realises that you fed it a dataset. I used `Dataset.map` so it receives a DataArray so that part of your code is working well :)
I don't think you can automate it without squash merging: https://stackoverflow.com/questions/3523534/good-ways-to-manage-a-changelog-using-git
I thought I had seen something recently but its an emacs/magit thing: https://github.com/magit/magit/pull/3928
This lines up with the cf xarray discussion: https://github.com/pangeo-data/pangeo/issues/771.
If you have the `axis` attribute set, you can now do this with cf-xarray: https://cf-xarray.readthedocs.io/en/latest/examples/introduction.html#Slicing EDIT: that's not exactly right. It won't take into account the grid layout. cf_xarray implements...
See https://github.com/pydata/xarray/pull/4979#issuecomment-790716187
I agree. let's do `isel` first. `sel` can then call `isel`. > pos_mapping={'center':'center', 'left':'left'} I feel like this should be the default. i.e. preserve the positions. For your first case,...
I read it as saying: take any variable currently on `x: left` and make it `x: outer` on the returned grid and dataset.
The explosion of ufuncs feels wrong to me. In this case though, can a grid not have `wet_mask=1` (appropriate DataArrays actually) by default? In which case xgcm expects all ufuncs...