MetOffice / CSET

Toolkit for evaluation and investigation of numerical models for weather and climate applications.
https://metoffice.github.io/CSET/
Apache License 2.0
10 stars 4 forks source link

Extend vertical line plot to plotting against model_level and height #658

Closed Sylviabohnenstengel closed 3 months ago

Sylviabohnenstengel commented 4 months ago

What problem does your feature request solve?

Currently the vertical line plot allows to plot against a log pressure axis. This ticket extends the plotting capability to allow plotting against model level number as well as height coordinate.

https://github.com/MetOffice/CSET/pull/567#pullrequestreview-2083466715 https://github.com/MetOffice/CSET/issues/494

Describe the solution you'd like

Extend the existing vertical line plot capability to pass in type of height coordinate to be plotted against.

Describe alternatives you've considered

Sylviabohnenstengel commented 4 months ago

need to extend the generate model_level constraint function to take a list of strings and convert them into an integer list. @jfrost-mo Is there a specific reason why the model_level_number constraint function takes model level number as a string? Can we add integers vis Union[str,int,list]?

Sylviabohnenstengel commented 4 months ago

@jfrost-mo as pressure levels won't be available for now in Lfric we should take the lfric based pressure level reliant recipes out and replace them with model level number reliant ones.

Sylviabohnenstengel commented 4 months ago
jfrost-mo commented 4 months ago

Is there a specific reason why the model_level_number constraint function takes model level number as a string? Can we add integers vis Union[str,int,list]?

It looks like it is just the documentation that is wrong there. It takes both strings and ints, and allthough it doesn't explicitly say so, I think it would also handle lists of ints.

Strings are explicitly converted to ints, but I do wonder if we want to keep doing that, or whether we should just get people to provide the right type in the first place.

jfrost-mo commented 4 months ago

as pressure levels won't be available for now in Lfric we should take the lfric based pressure level reliant recipes out and replace them with model level number reliant ones.

Now that we can read UM and LFRic data with the same recipe, the same recipe will work for both. We can keep it around to use on the UM.

Sylviabohnenstengel commented 3 months ago

PR: https://github.com/MetOffice/CSET/pull/697