AIFS_Single_v1

Model Introduction

AIFS Single v1.1 is the deterministic version of the AI-powered weather forecasting system developed by the European Centre for Medium-Range Weather Forecasts (ECMWF).

Paper: AIFS — ECMWF's data-driven forecasting system, arXiv:2406.01465

https://arxiv.org/abs/2406.01465

Model Description

AIFS is built on a Graph Neural Network (GNN), pre-trained on ERA5 data and fine-tuned with NWP operational analysis data.

Use Cases

Scenario Description
Weather Forecast Training Train AIFS from scratch using ERA5 HDF5 data
Local Quick Validation Use synthetic data to verify data loading, model training & inference, and inference result visualization.
ModelScope / OneCode Execution Download as a standalone model package, install dependencies, and run scripts directly.

Usage Guide

1. OneCode Usage

Experience intelligent one-click AI4S programming through the OneCode online environment:

Click to Experience Intelligent One-Click AI4S Programming

2. Manual Installation and Usage

Hardware Requirements

  • A GPU or DCU is recommended.
  • CPU can be used for import and small-scale connectivity verification; full training and inference will be slow.
  • DCU users must install DTK in advance. DTK 25.04.2 or above is recommended.

Download the Model Package

hf download OneScience-Group/AIFS_Single_v1 --local-dir ./AIFS_Single_v1
cd AIFS_Single_v1

Install the Runtime Environment

DCU

# Please activate DTK and CONDA first
conda create -n onescience311 python=3.11 -y
conda activate onescience311
# uv installation is supported
pip install onescience[earth-dcu] -i http://mirrors.onescience.ai:3141/pypi/simple/  --trusted-host mirrors.onescience.ai

GPU

# Please activate CONDA first
conda create -n onescience311 python=3.11 -y libstdcxx-ng=12 libgcc-ng=12 gcc_linux-64=12 gxx_linux-64=12
conda activate onescience311
# uv installation is supported
pip install onescience[earth-gpu] -i http://mirrors.onescience.ai:3141/pypi/simple/  --trusted-host mirrors.onescience.ai

Training Data Introduction

The OneScience community provides ERA5 data for training (due to file size limits, the current repository contains a slice of the full dataset). Users can download it with the command below and confirm that the data path in conf/config.yaml is set correctly:

hf download --repo-type dataset OneScience-Group/ERA5 --local-dir ./data

Training

python scripts/train.py

Training weights are saved to weights/model_bak.ckpt, and the normalization file computed before training is saved to weights/era5_stats.npz.

Training Weights

This repository provides weights trained on ERA5 reanalysis data in the weights/ folder. The weight files will be uploaded soon and are expected to be available in the near future.

Inference

python scripts/inference.py

The number of forecast steps is controlled by test_lead_time in conf/config.yaml (in hours; default 24 = 1 day). Inference results will be saved to the output directory.

Evaluation and Visualization

python scripts/result.py

Computes ACC / RMSE metrics and generates plots. Metrics are saved to metrics/ and figures are saved to plots/.

OneScience Official Information

Citation & License

  • This repository is a reproduction of the original AIFS Single v1.1 paper.

中文说明

模型简介

AIFS Single v1.1 是由欧洲中期天气预报中心(ECMWF)开发的 AI 天气预报(weather forecasting)系统的确定性版本。

论文:AIFS — ECMWF 的数据驱动预报系统,arXiv:2406.01465

https://arxiv.org/abs/2406.01465

模型描述

AIFS 基于图神经网络(GNN),使用 ERA5 数据预训练,并使用 NWP 业务分析数据进行微调(fine-tuning)。

使用场景

场景 说明
天气预报模型训练 使用 ERA5 HDF5 数据从头训练 AIFS
本地快速验证 使用合成数据验证数据加载、模型训练与推理(inference),以及推理结果可视化。
在 ModelScope / OneCode 中运行 下载独立模型包,安装依赖后直接运行脚本。

使用指南

1. OneCode 使用方法

通过 OneCode 在线环境体验智能一键 AI4S 编程。

点击体验智能一键 AI4S 编程

2. 手动安装与使用

硬件要求

  • 建议使用 GPU 或 DCU。
  • CPU 可用于导入和小规模连通性验证,完整训练和推理速度较慢。
  • DCU 用户必须提前安装 DTK。建议使用 DTK 25.04.2 或更高版本。

下载模型包

hf download OneScience-Group/AIFS_Single_v1 --local-dir ./AIFS_Single_v1
cd AIFS_Single_v1

安装运行环境

DCU

# Please activate DTK and CONDA first
conda create -n onescience311 python=3.11 -y
conda activate onescience311
# uv installation is supported
pip install onescience[earth-dcu] -i http://mirrors.onescience.ai:3141/pypi/simple/  --trusted-host mirrors.onescience.ai

GPU

# Please activate CONDA first
conda create -n onescience311 python=3.11 -y libstdcxx-ng=12 libgcc-ng=12 gcc_linux-64=12 gxx_linux-64=12
conda activate onescience311
# uv installation is supported
pip install onescience[earth-gpu] -i http://mirrors.onescience.ai:3141/pypi/simple/  --trusted-host mirrors.onescience.ai

训练数据简介

OneScience 社区提供用于训练的 ERA5 数据(受文件大小限制,当前仓库仅包含完整数据集的一部分)。用户可以通过以下命令下载数据,并确认 conf/config.yaml 中的数据路径设置正确。

hf download --repo-type dataset OneScience-Group/ERA5 --local-dir ./data

训练

python scripts/train.py

训练权重保存到 weights/model_bak.ckpt,训练前计算得到的归一化文件保存到 weights/era5_stats.npz。

训练权重

本仓库在 weights/ 文件夹中提供基于 ERA5 再分析(reanalysis)数据训练得到的权重。权重文件即将上传,预计近期可用。

推理

python scripts/inference.py

预报步数由 conf/config.yaml 中的 test_lead_time 控制(单位为小时,默认 24 = 1 天)。 推理结果将保存到 output 目录。

评估与可视化

python scripts/result.py

计算 ACC / RMSE 指标并生成图表。指标保存到 metrics/,图表保存到 plots/。

OneScience 官方信息

引用与许可证

  • 本仓库复现了 AIFS Single v1.1 的原始论文。
Downloads last month
19
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Paper for OneScience-Group/AIFS_Single_v1