-
Notifications
You must be signed in to change notification settings - Fork 283
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
iris.experimental.stratify.relevel
interface is difficult to use
#5298
Comments
|
Personally, I've never liked the I'd vote to deprecate and retire it 👍 (ping @HGWright) |
From discussion in @SciTools/peloton: we can definitely see the merit in an Iris-to-stratify convenience, but it shouldn't look the way it does now (written to solve a very specific case)! So the way forward is probably to completely re-do |
Can Our use cases in ESMValCore would be subsetting or interpolating vertical levels. Ideally with some configurable tolerance to use subsetting instead of interpolation if the requested level is already very close to what is available in the cube. However, for more complicated grids, full 3D regridding might be more appropriate as also mentioned by @zklaus in earlier discussions. |
Nope. They're not related, as far as I know i.e., we don't have that level of interoperability (yet)... but it does sound interesting as a concept 🤔 |
@hdyson also registered an interest in |
@bouweandela It would be great to hangout with you to capture your use case. I suspect this will shape the Would you be interested in doing that sometime? |
Actually I think it is implicit that all the Iris cube interpolation + regridding schemes only operate with horizontal coordinates. This could really do with explaining -- unfortunately the piecemeal history of the various schemes has left us with a lot of unstated detail and a lack of consistency in explaining their various properties and usage requirements. |
Yeah, that "whatever form" is the key from our perspective here. We currently use stratify directly, so have no attachment to the existing iris interface. But when there is an iris interface to stratify that people are happy with, we'd be happy to migrate our usage over to the iris interface. There's no urgency on our part here: our current solution works for our use cases, so the motivating factor would be the usual benefits of moving over to library solutions (less duplication, less code for us to maintain, more chance of bugs being found and fixed, etc). |
✨ Feature Request
In the ESMValCore, we have a Python function extract_levels originally contributed by @bjlittle. It would be nice if we could replace this function by
iris.experimental.stratify.relevel
, but the current implementation of that function has a difficult to use interface.For example, if I have a 4D cube with dimensions (time x air_pressure x latitude x longitude), providing the source levels is difficult, it's unclear why I need to provide the axis argument, and the target levels lack any information on the variable name and units so the operation is quite unsafe:
What I would like to be able to do is
i.e. the axis is automatically determined from the target levels and the source coordinate is found based on matching the target coordinate in the input cube.
Are there any plans for
iris.experimental.stratify.relevel
? Or are you planning to remove it in favour of more advanced techniques such as 3D regridding?Related to #5290 and previously discussed in ESMValGroup/ESMValCore#35 (comment) and https://github.com/orgs/SciTools/projects/16?pane=issue&itemId=20691829.
The text was updated successfully, but these errors were encountered: