ESMValGroup / ESMValCore

ESMValCore: A community tool for pre-processing data from Earth system models in CMIP and running analysis scripts.
https://www.esmvaltool.org
Apache License 2.0
42 stars 38 forks source link

python-stratify still needed? #35

Open bouweandela opened 5 years ago

bouweandela commented 5 years ago

It looks like iris supports vertical regridding: https://scitools.org.uk/iris/docs/latest/userguide/interpolation_and_regridding.html#interpolating-non-horizontal-coordinates

@bjlittle Do we still need python-stratify for vertical interpolation? Additionally, do we still need to do cube slicing if the levels are already available, is this shortcut not taken by the iris vertical interpolator?

There are two problems with python-stratify:

Here is a link to the relevant code: https://github.com/ESMValGroup/ESMValTool/blob/3e68d1593f544694618617368f8a3c88d0683f33/esmvaltool/preprocessor/_regrid.py#L327-L434

bjlittle commented 5 years ago

@bouweandela I highly suspect that the generic core iris.analysis.Linear interpolator scheme will not be performant enough for you. Not even close.

The attraction of python-stratify is that it is cythonized, therefore closer to bare metal speed. However, you are right, it isn't lazy. I'm keen to do a couple of things here...

valeriupredoi commented 5 years ago

will this be included (or excluded) in iris=2.3 @bjlittle ? I am starting to think we should make a list of ESMValTool/Core iris-related issues with fixes in 2.3 :beer:

valeriupredoi commented 4 years ago

noticed in #776 that stratify accepts and works happily with cube.core_data() - any way to make it fully lazy and output a lazy data array @bjlittle ? :beer: