Skip to content
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

Tropical Cyclone Potential Intensity #3677

Open
stella-bourdin opened this issue Nov 5, 2024 · 1 comment
Open

Tropical Cyclone Potential Intensity #3677

stella-bourdin opened this issue Nov 5, 2024 · 1 comment
Labels
Type: Feature New functionality

Comments

@stella-bourdin
Copy link

What should we add?

Hello,
Would it be possible to add a function to compute tropical cyclone (TC) potential intensity (PI) in MetPy?
PI is a widely used variable in the TC community. It defines the theoretical maximum intensity of a tropical cyclone in a given environment as defined by temperature and humidity.
The only existing Python package to compute it (Gilford et al., 2021) is a Python translation of K. Emanuel's Matlab code, it is not built in a very flexible manner, does not handle units well and is very slow.
I tried improving the existing code but find myself going back to the fundamentals, so I believe it would make more sense to include it within MetPy's already existing infrastructure and take advantage of the existing functions, as well as MetPy's visibility.
I am considering contributing it myself, however, I am not well acquainted with both the meteorological concepts behind PI, nor MetPy's infrastructure, so it might take quite a lot of time before I can... So I thought maybe someone here is better equipped to do so? Or at least to help me?
Thanks, Stella

Reference

Bister & Emanuel, 1998
Wing et al., 2015
Gilford et al., 2021
Wikipedia

@stella-bourdin stella-bourdin added the Type: Feature New functionality label Nov 5, 2024
@DWesl
Copy link
Contributor

DWesl commented Nov 9, 2024

Do you have an equation in mind? There's a few in the referenced papers. MetPy has moist static energy, saturation mixing ratio, and CAPE, if that is where your problem is.

If it is primarily speed you are after, would it make more sense to grab the Fortran version the other package links, wrap it with f2py, then wrap the result with pint.wraps to handle units? I don't know that that will beat the numba.njit decorators currently on the python version for repeated computation, but it should help with the first dozen calculations (alternately, I think numba has functions for ahead-of-time compiling if you want to go that route instead).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Feature New functionality
Projects
None yet
Development

No branches or pull requests

2 participants