Predict tropical cyclone intensity using pre-trained Input-Output Hidden Markov Models
Project description
PepC-Global Intensity
A Python package for predicting tropical cyclone intensity using pre-trained Input-Output Hidden Markov Models.
Installation
pip install --upgrade pepc-global-intensity
Or from source:
git clone https://github.com/CongGao-CG/pepc-global-intensity.git
cd pepc-global-intensity
pip install .
Quick Start
import pandas as pd
from pepc_global_intensity import predict_intensity
# Create DataFrame for a single storm with required columns
df = pd.DataFrame({
"step": [0, 1, 2],
"time": pd.to_datetime(["2000-07-01", "2000-07-01 06:00", "2000-07-01 12:00"]),
"year": [2000, 2000, 2000],
"mode": ["ocean", "ocean", "ocean"],
"ILD": [50.0, 50.0, 50.0],
"grd": [1e-4, 1e-4, 1e-4],
"ut": [5.0, 5.0, 5.0],
"pi": [70.0, 70.0, 70.0],
"shr": [10.0, 10.0, 10.0],
"rh600": [0.7, 0.7, 0.7],
"ocean": [True, True, True],
"ocean_next": [True, True, True],
"mean_stl1": [0.0, 0.0, 0.0],
"mean_fsr": [0.0, 0.0, 0.0],
"mean_swvl1": [0.0, 0.0, 0.0],
})
# Predict intensity for a specific basin and experiment
result = predict_intensity(
basin="NA", # North Atlantic
df=df,
experiment="historical",
model="ACCESS-ESM1-5",
variant="r1i1p1f1",
seed=42,
)
print(result[["step", "time", "pre_wind", "state"]])
Available Basins
| Basin Code | Name | Latitude Range | Longitude Range |
|---|---|---|---|
AS |
Arabian Sea | 5° to 22.5°N | 50° to 77.5°E |
BoB |
Bay of Bengal | 5° to 22.5°N | 80° to 100°E |
WNP |
Western North Pacific | 5° to 30°N | 102.5°E to 180° |
ENP |
Eastern North Pacific | 5° to 25°N | 177.5° to 75°W |
NA |
North Atlantic | 5° to 30°N | 97.5° to 2.5°W |
SI |
South Indian | 30° to 5°S | 20° to 145°E |
SP |
South Pacific | 30° to 5°S | 147.5°E to 100°W |
API Reference
predict_intensity(basin, df, experiment, model, variant, seed)
Predict tropical cyclone intensity using Input-Output Hidden Markov Models.
Parameters:
basin(str): Basin name (one of: 'AS', 'BoB', 'WNP', 'ENP', 'NA', 'SI', 'SP')df(pd.DataFrame): Pre-prepared data for a single storm with required columns (see Input Variables table below)experiment(str): Experiment type — 'historical' or 'ssp585'model(str): CMIP6 model name (used for ssp585 upper-bound schedule lookup)variant(str): CMIP6 variant label (used for ssp585 upper-bound schedule lookup)seed(int or None): Random seed for reproducibility
Returns:
pd.DataFrame: Copy of the input DataFrame with added columns:pre_wind: Predicted wind speedpre_delta_wind_b: Predicted backward wind changepre_delta_wind_f: Predicted forward wind changepre_ocn: Predicted ocean statestate: Hidden state classification
Raises:
ValueError: If basin is invalid, experiment is not 'historical' or 'ssp585', or required columns are missing from df
get_basin_names()
Get the list of valid basin names.
Returns:
list[str]: List of 7 basin names
BASINS
List of valid basin names.
Input Variables
| Variable | Description | Typical Units |
|---|---|---|
| step | Track point index within the storm (0 at genesis) | — |
| time | Timestamp | datetime |
| year | Calendar year | — |
| mode | Surface type: 'ocean', 'land', or 'not' | — |
| ILD | Isothermal layer depth | m |
| grd | Ocean temperature gradient | K m^−1 |
| ut | Storm translation speed | m s^−1 |
| pi | Potential intensity | kt |
| shr | Vertical wind shear between 200 hPa and 850 hPa | m s^−1 |
| rh600 | Relative humidity at 600 hPa | % |
| ocean | ocean fraction at the current position | — |
| ocean_next | ocean fraction at the next 6-hour position | — |
| mean_stl1 | Land-weighted soil temperature | K |
| mean_fsr | Land-weighted surface roughness length | m |
| mean_swvl1 | Land-weighted soil water volume | m^3 m^−3 |
Model Details
This package contains pre-trained Input-Output Hidden Markov Models (IOHMM) for 7 tropical cyclone basins. The models were pre-trained on ERA5 monthly data using multiple environmental predictors known to influence tropical cyclone intensity:
- Ocean coupling (ILD, grd): Ocean thermal structure affecting ocean feedback
- Storm motion (ut): Translation speed affecting ocean feedback
- Potential intensity (pi): Theoretical upper bound on storm strength
- Wind shear (shr): Vertical wind shear affecting intensification
- Mid-level humidity (rh600): Environmental moisture affecting intensification
- Land effects (mean_fsr, mean_stv1, mean_swvl1): Land and soil conditions affecting over-land decay
Each basin has its own pre-trained IOHMM parameters and land-mode regression coefficients.
License
MIT License
Citation
If you use this package in your research, please cite:
Gao, Cong, Ning Lin. "PepC-Global: A Basin-Tuned Probabilistic Tropical Cyclone Model with Enhanced Out-of-Sample Skill and Climate-Sensitive Over-Land Decay". Journal of Advances in Modeling Earth Systems (JAMES), under review.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file pepc_global_intensity-0.1.2.tar.gz.
File metadata
- Download URL: pepc_global_intensity-0.1.2.tar.gz
- Upload date:
- Size: 21.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.10.16
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3cd223bc7e8a3c404c5586a84ad94e17af40f26c6f40f7cbc8652d4a81572121
|
|
| MD5 |
7d4265640493d26cdd373a4f7dc22c09
|
|
| BLAKE2b-256 |
27b2e45472cedd37f126639271b25c598a148c3c5410377281c8ba55617854ce
|
File details
Details for the file pepc_global_intensity-0.1.2-py3-none-any.whl.
File metadata
- Download URL: pepc_global_intensity-0.1.2-py3-none-any.whl
- Upload date:
- Size: 28.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.10.16
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3f4ebc4593f7a68444ed5bec014cd1674ed93e0744bc1e48ec11081de9cace61
|
|
| MD5 |
91fe779d118c264f9512c8eb33092903
|
|
| BLAKE2b-256 |
e0003e2973ab38921572c92439edd5a798edb7407f450aafc8ee7b6fa25214f4
|