Skip to main content

Predict tropical cyclone track displacements using pre-trained Random Forest models

Project description

PepC-Global Track

A Python package for predicting tropical cyclone track displacements using pre-trained Random Forest models.

Installation

pip install --upgrade pepc-global-track

Or from source:

git clone https://github.com/CongGao-CG/pepc-global-track.git
cd pepc-global-track
pip install .

Quick Start

import numpy as np
from pepc_global_track import predict_track

# Create predictor array with shape (N, 5)
# Columns: [u250, v250, u850, v850, lat]
# u250, v250: zonal and meridional wind at 250 hPa (m s^-1)
# u850, v850: zonal and meridional wind at 850 hPa (m s^-1)
# lat: storm latitude (degrees)
X = np.array([
    [5.0, 1.0, 3.0, -1.0, 15.0],
    [6.0, 1.5, 3.5, -0.5, 16.0],
    [7.0, 2.0, 4.0,  0.0, 17.0],
])

# Predict longitude displacement for a specific basin
basin = 'NA'  # North Atlantic
delta_lon = predict_track(basin, 'lon', X)

# Predict latitude displacement
delta_lat = predict_track(basin, 'lat', X)

print(f"Predicted longitude displacement: {delta_lon}")
print(f"Predicted latitude displacement: {delta_lat}")

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_track(basin, disp_type, X)

Predict tropical cyclone track displacement (longitude or latitude).

Parameters:

  • basin (str): Basin name (one of: 'AS', 'BoB', 'WNP', 'ENP', 'NA', 'SI', 'SP')
  • disp_type (str): Displacement type — 'lon' for zonal (longitude) displacement or 'lat' for meridional (latitude) displacement
  • X (np.ndarray): 2D array of shape (N, 5) with columns [u250, v250, u850, v850, lat]

Returns:

  • np.ndarray: 1D array of predicted displacements (degrees)

Raises:

  • ValueError: If basin is invalid, disp_type is not 'lon' or 'lat', or X does not have shape (N, 5)

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
u250 Zonal wind at 250 hPa m s^−1
v250 Meridional wind at 250 hPa m s^−1
u850 Zonal wind at 850 hPa m s^−1
v850 Meridional wind at 850 hPa m s^−1
lat Storm latitude degrees

Model Details

This package contains pre-trained Random Forest models for 7 tropical cyclone basins. The models were pre-trained on ERA5 monthly data using five environmental predictors known to influence tropical cyclone track:

  1. Zonal wind at 250 hPa (u250): Upper-level zonal flow
  2. Meridional wind at 250 hPa (v250): Upper-level meridional flow
  3. Zonal wind at 850 hPa (u850): Lower-level zonal flow
  4. Meridional wind at 850 hPa (v850): Lower-level meridional flow
  5. Storm latitude (lat): Current storm position

Each basin has its own pre-trained models for both longitude and latitude displacement predictions.

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


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pepc_global_track-0.2.1.tar.gz (4.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pepc_global_track-0.2.1-py3-none-any.whl (4.2 kB view details)

Uploaded Python 3

File details

Details for the file pepc_global_track-0.2.1.tar.gz.

File metadata

  • Download URL: pepc_global_track-0.2.1.tar.gz
  • Upload date:
  • Size: 4.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.10.16

File hashes

Hashes for pepc_global_track-0.2.1.tar.gz
Algorithm Hash digest
SHA256 e34b473c89e1ce9fe68e0d9ef47740b7bc5f1c4bff76fb1cc9a18d64f5b5051f
MD5 435234d230a9924bf269ab74bdd8893a
BLAKE2b-256 1ea9dc3a6d01551d55cfbb84f3a57e1a192cafc18bcfc40d5ce1c27105aa11d8

See more details on using hashes here.

File details

Details for the file pepc_global_track-0.2.1-py3-none-any.whl.

File metadata

File hashes

Hashes for pepc_global_track-0.2.1-py3-none-any.whl
Algorithm Hash digest
SHA256 f6ddecff8e183dc578b1efee7bc20b099c92589e27730b851be919a429517ae2
MD5 d191fedf0f1dc534a8a750da1fe3d4d1
BLAKE2b-256 d38366d96373af13dc0fabf4c0cf9e1764bb93cd309ebcf6ffe51c6effc38b0d

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page