/AI-based-attribution

This repository contains the basic scripts to perform the attribution of weather extreme events based on the adpatation of the pesudo-global warming apporach applied to AI-based weather models like FourCastNetv2 and Pangu Weather.

Primary LanguageJupyter NotebookApache License 2.0Apache-2.0

AI-based Attribution Forecasts

This repository contains scripts to attribute extreme weather events to Anthropogenic Climate Change (ACC) using forecasts from newly developed AI-based weather models. The methodology involves applying climate deltas (the difference between actual and preindustrial climate) of thermodynamic variables from historical simulations of global climate models (GCMs) to the initial conditions of weather forecasts. This approach is adapted from the pseudo-global warming methodology (Brogli et al., 2023), traditionally used with regional and global atmospheric physics-based models, but here applied to AI-driven weather forecasts.

We utilize two AI-based weather models: FourCastNetv2 and Pangu-Weather.

To run these models, we use the repository https://github.com/jejjohnson/ddf.git, which largely relies on the Earth2MIP framework. This is particularly relevant if you plan to use the scripts in the 2_AI_model_simulation_scripts directory.

This repository is organized into the following directories, each containing scripts relevant to the rapid attribution of extreme events:

  1. Model Initialization Data Preprocessing Scripts: This directory includes scripts for preparing input files for FourCastNetv2 or Pangu-Weather.

    • Preprocessed CMIP6 data (Eyring et al., 2016) is required to calculate the climate deltas applied to initial conditions. We provide a multimodel mean of 10 models, interpolated to a common grid of 2.5x2.5 degrees. The necessary preprocessed files for applying the ACC deltas can be found in the DATA folder in this repository. The original CMIP6 historical data is available through the ESGF nodes here.
  2. AI Model Simulation Scripts: This directory contains the basic scripts needed to run the AI-based weather models. While we've tested FourCastNetv2 and Pangu-Weather using the external Earth2MIP package, other models might be compatible depending on your hardware.

  3. Extreme Events Case Studies: This folder includes Jupyter notebooks for calculating diagnostics for three selected case studies of extreme events. The data generated using the scripts in section 2 is necessary to run these notebooks.

Installation:

Conda (Recommended)

  • clone the repository into you machine:
git clone https://github.com/bernatj/AI-based-Attribution.git
  • create a new conda environment:
conda env create -f environments/attribution_with_ai.yaml
conda activate attribution_with_ai
  • if you want to be able to run the models you need to manually install APEX using pip:
pip install git+https://github.com/NVIDIA/apex.git -v --disable-pip-version-check --no-cache-dir --no-build-isolation --global-option="--cpp_ext" --global-option="--cuda_ext"
git clone https://github.com/jejjohnson/ddf.git