StormScope Meteosat FCI Nowcasting¶
StormScope inference workflow with MTG-I1 FCI satellite imagery.
This example will demonstrate how to run inference to generate nowcasts of Meteosat Third Generation (MTG-I1) FCI satellite imagery using StormScopeMeteosatEU, a generative diffusion model that predicts the next 10-minute FCI frame from a sliding window of recent observations.
In this example you will learn:
- How to instantiate
earth2studio.models.px.StormScopeMeteosatEU - Fetching FCI observations on the model grid through the model's default source
- Selecting a regional view for presentation
- Running iterative nowcasting
- Plotting an RGB composite of FCI channels with cartopy
Set Up¶
StormScopeMeteosatEU is a pure-observation nowcasting model: it requires no
external NWP conditioning. The only input is a sliding window of L
consecutive FCI frames ending at the analysis time.
The model runs on a crop of the 2 km FCI full-disk grid over Europe. Its
default_sources returns a earth2studio.data.MeteosatFCI source
that reads exactly that crop: the infrared channels at 2 km, and the visible
and near-infrared channels, which are only available at 1 km, averaged over
the 2x2 blocks of 1 km pixels that form each 2 km pixel.
EUMETSAT Data Store credentials must be available via the environment
variables EUMETSAT_CONSUMER_KEY and EUMETSAT_CONSUMER_SECRET, or in
the ~/.eumdac/credentials file.
import os
from datetime import datetime, timezone
os.makedirs("outputs", exist_ok=True)
from dotenv import load_dotenv
load_dotenv()
import cartopy.crs as ccrs
import matplotlib.pyplot as plt
import numpy as np
import torch
from tqdm import tqdm
from earth2studio.data import fetch_data
from earth2studio.data.meteosat_fci import (
PERSPECTIVE_POINT_HEIGHT,
SEMI_MAJOR_AXIS,
SEMI_MINOR_AXIS,
)
from earth2studio.grids import Region
from earth2studio.models.px.stormscope_meteosat import StormScopeMeteosatEU
Load Model¶
Load StormScopeMeteosatEU from a package. region optionally selects a
[earth2studio.grids.Region][] box for
presentation. The model always runs on its full European domain, because its
networks are trained for that input size; a regional view crops the forecast
with crop_output.
device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
# Region.box(west, south, east, north) in degrees, or None for the full domain.
region: Region | None = None # Example: Region.box(-5.0, 42.0, 10.0, 52.0)
package = StormScopeMeteosatEU.load_default_package()
model = StormScopeMeteosatEU.load_model(package=package, compile=True)
model = model.to(device)
model.eval()
if region is not None:
model = model.with_region(region)
Console output233 lines
Downloading config.yaml: 0%| | 0.00/438 [00:00<?, ?B/s]
Downloading config.yaml: 100%|██████████| 438/438 [00:00<00:00, 2.35kB/s]
Downloading config.yaml: 100%|██████████| 438/438 [00:00<00:00, 2.33kB/s]
Downloading StormscopeMTG-low.mdlus: 0%| | 0.00/1.14G [00:00<?, ?B/s]
Downloading StormscopeMTG-low.mdlus: 1%| | 10.0M/1.14G [00:01<02:15, 8.98MB/s]
Downloading StormscopeMTG-low.mdlus: 2%|▏ | 20.0M/1.14G [00:01<01:04, 18.7MB/s]
Downloading StormscopeMTG-low.mdlus: 3%|▎ | 30.0M/1.14G [00:01<00:45, 26.0MB/s]
Downloading StormscopeMTG-low.mdlus: 3%|▎ | 40.0M/1.14G [00:01<00:35, 33.3MB/s]
Downloading StormscopeMTG-low.mdlus: 4%|▍ | 50.0M/1.14G [00:01<00:30, 37.9MB/s]
Downloading StormscopeMTG-low.mdlus: 5%|▌ | 60.0M/1.14G [00:02<00:30, 38.3MB/s]
Downloading StormscopeMTG-low.mdlus: 6%|▌ | 70.0M/1.14G [00:02<00:29, 38.5MB/s]
Downloading StormscopeMTG-low.mdlus: 7%|▋ | 80.0M/1.14G [00:02<00:33, 33.6MB/s]
Downloading StormscopeMTG-low.mdlus: 8%|▊ | 90.0M/1.14G [00:03<00:38, 29.7MB/s]
Downloading StormscopeMTG-low.mdlus: 9%|▊ | 100M/1.14G [00:03<00:42, 26.2MB/s]
Downloading StormscopeMTG-low.mdlus: 9%|▉ | 110M/1.14G [00:04<00:48, 22.7MB/s]
Downloading StormscopeMTG-low.mdlus: 10%|█ | 120M/1.14G [00:05<00:58, 18.8MB/s]
Downloading StormscopeMTG-low.mdlus: 11%|█ | 130M/1.14G [00:05<01:05, 16.6MB/s]
Downloading StormscopeMTG-low.mdlus: 12%|█▏ | 140M/1.14G [00:06<01:11, 15.1MB/s]
Downloading StormscopeMTG-low.mdlus: 13%|█▎ | 150M/1.14G [00:07<01:20, 13.3MB/s]
Downloading StormscopeMTG-low.mdlus: 14%|█▎ | 160M/1.14G [00:09<01:32, 11.4MB/s]
Downloading StormscopeMTG-low.mdlus: 15%|█▍ | 170M/1.14G [00:09<01:28, 11.8MB/s]
Downloading StormscopeMTG-low.mdlus: 15%|█▌ | 180M/1.14G [00:10<01:20, 12.8MB/s]
Downloading StormscopeMTG-low.mdlus: 16%|█▋ | 190M/1.14G [00:10<01:09, 14.8MB/s]
Downloading StormscopeMTG-low.mdlus: 17%|█▋ | 200M/1.14G [00:11<00:55, 18.2MB/s]
Downloading StormscopeMTG-low.mdlus: 18%|█▊ | 210M/1.14G [00:11<00:54, 18.6MB/s]
Downloading StormscopeMTG-low.mdlus: 19%|█▉ | 220M/1.14G [00:12<00:45, 22.1MB/s]
Downloading StormscopeMTG-low.mdlus: 20%|█▉ | 230M/1.14G [00:12<00:38, 25.4MB/s]
Downloading StormscopeMTG-low.mdlus: 21%|██ | 240M/1.14G [00:12<00:32, 29.6MB/s]
Downloading StormscopeMTG-low.mdlus: 21%|██▏ | 250M/1.14G [00:12<00:27, 34.4MB/s]
Downloading StormscopeMTG-low.mdlus: 22%|██▏ | 260M/1.14G [00:12<00:23, 40.4MB/s]
Downloading StormscopeMTG-low.mdlus: 23%|██▎ | 270M/1.14G [00:13<00:20, 45.9MB/s]
Downloading StormscopeMTG-low.mdlus: 24%|██▍ | 280M/1.14G [00:13<00:18, 49.7MB/s]
Downloading StormscopeMTG-low.mdlus: 25%|██▍ | 290M/1.14G [00:13<00:18, 51.0MB/s]
Downloading StormscopeMTG-low.mdlus: 26%|██▌ | 300M/1.14G [00:13<00:18, 50.2MB/s]
Downloading StormscopeMTG-low.mdlus: 27%|██▋ | 310M/1.14G [00:13<00:19, 47.1MB/s]
Downloading StormscopeMTG-low.mdlus: 27%|██▋ | 320M/1.14G [00:14<00:20, 43.7MB/s]
Downloading StormscopeMTG-low.mdlus: 28%|██▊ | 330M/1.14G [00:14<00:23, 37.7MB/s]
Downloading StormscopeMTG-low.mdlus: 29%|██▉ | 340M/1.14G [00:14<00:26, 32.7MB/s]
Downloading StormscopeMTG-low.mdlus: 30%|██▉ | 350M/1.14G [00:15<00:28, 29.6MB/s]
Downloading StormscopeMTG-low.mdlus: 31%|███ | 360M/1.14G [00:15<00:28, 29.7MB/s]
Downloading StormscopeMTG-low.mdlus: 32%|███▏ | 370M/1.14G [00:16<00:27, 30.4MB/s]
Downloading StormscopeMTG-low.mdlus: 33%|███▎ | 380M/1.14G [00:16<00:25, 32.5MB/s]
Downloading StormscopeMTG-low.mdlus: 33%|███▎ | 390M/1.14G [00:16<00:22, 35.9MB/s]
Downloading StormscopeMTG-low.mdlus: 34%|███▍ | 400M/1.14G [00:16<00:19, 40.9MB/s]
Downloading StormscopeMTG-low.mdlus: 35%|███▌ | 410M/1.14G [00:16<00:17, 45.3MB/s]
Downloading StormscopeMTG-low.mdlus: 36%|███▌ | 420M/1.14G [00:17<00:16, 47.5MB/s]
Downloading StormscopeMTG-low.mdlus: 37%|███▋ | 430M/1.14G [00:17<00:14, 53.1MB/s]
Downloading StormscopeMTG-low.mdlus: 38%|███▊ | 440M/1.14G [00:17<00:13, 58.3MB/s]
Downloading StormscopeMTG-low.mdlus: 39%|███▊ | 450M/1.14G [00:17<00:12, 62.3MB/s]
Downloading StormscopeMTG-low.mdlus: 40%|████ | 470M/1.14G [00:17<00:09, 78.2MB/s]
Downloading StormscopeMTG-low.mdlus: 42%|████▏ | 490M/1.14G [00:17<00:08, 86.1MB/s]
Downloading StormscopeMTG-low.mdlus: 44%|████▎ | 510M/1.14G [00:18<00:07, 93.3MB/s]
Downloading StormscopeMTG-low.mdlus: 45%|████▌ | 530M/1.14G [00:18<00:07, 92.5MB/s]
Downloading StormscopeMTG-low.mdlus: 46%|████▌ | 540M/1.14G [00:18<00:08, 82.3MB/s]
Downloading StormscopeMTG-low.mdlus: 47%|████▋ | 550M/1.14G [00:18<00:08, 74.5MB/s]
Downloading StormscopeMTG-low.mdlus: 48%|████▊ | 560M/1.14G [00:18<00:09, 70.2MB/s]
Downloading StormscopeMTG-low.mdlus: 49%|████▉ | 570M/1.14G [00:19<00:09, 64.7MB/s]
Downloading StormscopeMTG-low.mdlus: 50%|████▉ | 580M/1.14G [00:19<00:08, 69.2MB/s]
Downloading StormscopeMTG-low.mdlus: 50%|█████ | 590M/1.14G [00:19<00:07, 76.0MB/s]
Downloading StormscopeMTG-low.mdlus: 51%|█████▏ | 600M/1.14G [00:19<00:07, 77.8MB/s]
Downloading StormscopeMTG-low.mdlus: 53%|█████▎ | 620M/1.14G [00:19<00:06, 93.5MB/s]
Downloading StormscopeMTG-low.mdlus: 54%|█████▍ | 630M/1.14G [00:19<00:05, 94.5MB/s]
Downloading StormscopeMTG-low.mdlus: 56%|█████▌ | 650M/1.14G [00:19<00:05, 102MB/s]
Downloading StormscopeMTG-low.mdlus: 56%|█████▋ | 660M/1.14G [00:20<00:05, 90.3MB/s]
Downloading StormscopeMTG-low.mdlus: 57%|█████▋ | 670M/1.14G [00:20<00:06, 76.2MB/s]
Downloading StormscopeMTG-low.mdlus: 58%|█████▊ | 680M/1.14G [00:20<00:07, 69.6MB/s]
Downloading StormscopeMTG-low.mdlus: 59%|█████▉ | 690M/1.14G [00:20<00:07, 64.4MB/s]
Downloading StormscopeMTG-low.mdlus: 60%|█████▉ | 700M/1.14G [00:20<00:08, 58.0MB/s]
Downloading StormscopeMTG-low.mdlus: 61%|██████ | 710M/1.14G [00:21<00:09, 52.1MB/s]
Downloading StormscopeMTG-low.mdlus: 62%|██████▏ | 720M/1.14G [00:21<00:09, 49.0MB/s]
Downloading StormscopeMTG-low.mdlus: 62%|██████▏ | 730M/1.14G [00:21<00:09, 47.5MB/s]
Downloading StormscopeMTG-low.mdlus: 63%|██████▎ | 740M/1.14G [00:21<00:09, 45.3MB/s]
Downloading StormscopeMTG-low.mdlus: 64%|██████▍ | 750M/1.14G [00:22<00:10, 43.1MB/s]
Downloading StormscopeMTG-low.mdlus: 65%|██████▌ | 760M/1.14G [00:22<00:09, 43.0MB/s]
Downloading StormscopeMTG-low.mdlus: 66%|██████▌ | 770M/1.14G [00:22<00:09, 42.7MB/s]
Downloading StormscopeMTG-low.mdlus: 67%|██████▋ | 780M/1.14G [00:22<00:08, 47.7MB/s]
Downloading StormscopeMTG-low.mdlus: 68%|██████▊ | 790M/1.14G [00:22<00:07, 51.3MB/s]
Downloading StormscopeMTG-low.mdlus: 68%|██████▊ | 800M/1.14G [00:23<00:06, 56.4MB/s]
Downloading StormscopeMTG-low.mdlus: 69%|██████▉ | 810M/1.14G [00:23<00:06, 60.4MB/s]
Downloading StormscopeMTG-low.mdlus: 70%|███████ | 820M/1.14G [00:23<00:05, 62.0MB/s]
Downloading StormscopeMTG-low.mdlus: 71%|███████ | 830M/1.14G [00:23<00:05, 62.0MB/s]
Downloading StormscopeMTG-low.mdlus: 72%|███████▏ | 840M/1.14G [00:23<00:05, 66.9MB/s]
Downloading StormscopeMTG-low.mdlus: 73%|███████▎ | 850M/1.14G [00:23<00:04, 72.2MB/s]
Downloading StormscopeMTG-low.mdlus: 74%|███████▍ | 870M/1.14G [00:24<00:04, 73.8MB/s]
Downloading StormscopeMTG-low.mdlus: 75%|███████▌ | 880M/1.14G [00:24<00:04, 74.4MB/s]
Downloading StormscopeMTG-low.mdlus: 76%|███████▌ | 890M/1.14G [00:24<00:04, 66.0MB/s]
Downloading StormscopeMTG-low.mdlus: 77%|███████▋ | 900M/1.14G [00:24<00:04, 62.9MB/s]
Downloading StormscopeMTG-low.mdlus: 78%|███████▊ | 910M/1.14G [00:24<00:04, 65.8MB/s]
Downloading StormscopeMTG-low.mdlus: 79%|███████▊ | 920M/1.14G [00:24<00:04, 65.0MB/s]
Downloading StormscopeMTG-low.mdlus: 80%|███████▉ | 930M/1.14G [00:25<00:03, 67.8MB/s]
Downloading StormscopeMTG-low.mdlus: 80%|████████ | 940M/1.14G [00:25<00:03, 72.4MB/s]
Downloading StormscopeMTG-low.mdlus: 81%|████████▏ | 950M/1.14G [00:25<00:02, 79.1MB/s]
Downloading StormscopeMTG-low.mdlus: 82%|████████▏ | 960M/1.14G [00:25<00:02, 81.7MB/s]
Downloading StormscopeMTG-low.mdlus: 83%|████████▎ | 970M/1.14G [00:25<00:02, 79.9MB/s]
Downloading StormscopeMTG-low.mdlus: 84%|████████▍ | 980M/1.14G [00:25<00:02, 82.7MB/s]
Downloading StormscopeMTG-low.mdlus: 86%|████████▌ | 0.98G/1.14G [00:25<00:02, 84.3MB/s]
Downloading StormscopeMTG-low.mdlus: 86%|████████▋ | 0.99G/1.14G [00:26<00:02, 80.5MB/s]
Downloading StormscopeMTG-low.mdlus: 87%|████████▋ | 1.00G/1.14G [00:26<00:01, 82.6MB/s]
Downloading StormscopeMTG-low.mdlus: 88%|████████▊ | 1.01G/1.14G [00:26<00:02, 54.7MB/s]
Downloading StormscopeMTG-low.mdlus: 89%|████████▉ | 1.02G/1.14G [00:27<00:04, 30.7MB/s]
Downloading StormscopeMTG-low.mdlus: 90%|████████▉ | 1.03G/1.14G [00:27<00:05, 23.7MB/s]
Downloading StormscopeMTG-low.mdlus: 91%|█████████ | 1.04G/1.14G [00:28<00:05, 19.6MB/s]
Downloading StormscopeMTG-low.mdlus: 92%|█████████▏| 1.04G/1.14G [00:29<00:06, 17.1MB/s]
Downloading StormscopeMTG-low.mdlus: 92%|█████████▏| 1.05G/1.14G [00:29<00:04, 19.3MB/s]
Downloading StormscopeMTG-low.mdlus: 93%|█████████▎| 1.06G/1.14G [00:30<00:04, 18.3MB/s]
Downloading StormscopeMTG-low.mdlus: 94%|█████████▍| 1.07G/1.14G [00:30<00:03, 20.9MB/s]
Downloading StormscopeMTG-low.mdlus: 95%|█████████▍| 1.08G/1.14G [00:31<00:02, 25.8MB/s]
Downloading StormscopeMTG-low.mdlus: 96%|█████████▌| 1.09G/1.14G [00:31<00:01, 31.6MB/s]
Downloading StormscopeMTG-low.mdlus: 97%|█████████▋| 1.10G/1.14G [00:31<00:01, 23.5MB/s]
Downloading StormscopeMTG-low.mdlus: 98%|█████████▊| 1.11G/1.14G [00:35<00:04, 7.39MB/s]
Downloading StormscopeMTG-low.mdlus: 98%|█████████▊| 1.12G/1.14G [00:39<00:03, 5.05MB/s]
Downloading StormscopeMTG-low.mdlus: 99%|█████████▉| 1.13G/1.14G [00:40<00:01, 6.05MB/s]
Downloading StormscopeMTG-low.mdlus: 100%|██████████| 1.14G/1.14G [00:40<00:00, 7.92MB/s]
Downloading StormscopeMTG-low.mdlus: 100%|██████████| 1.14G/1.14G [00:40<00:00, 30.4MB/s]
Downloading StormscopeMTG-high.mdlus: 0%| | 0.00/1.14G [00:00<?, ?B/s]
Downloading StormscopeMTG-high.mdlus: 1%| | 10.0M/1.14G [00:01<02:02, 9.91MB/s]
Downloading StormscopeMTG-high.mdlus: 2%|▏ | 20.0M/1.14G [00:01<01:00, 19.8MB/s]
Downloading StormscopeMTG-high.mdlus: 3%|▎ | 30.0M/1.14G [00:01<00:40, 29.5MB/s]
Downloading StormscopeMTG-high.mdlus: 3%|▎ | 40.0M/1.14G [00:01<00:32, 36.6MB/s]
Downloading StormscopeMTG-high.mdlus: 4%|▍ | 50.0M/1.14G [00:01<00:26, 44.7MB/s]
Downloading StormscopeMTG-high.mdlus: 5%|▌ | 60.0M/1.14G [00:01<00:23, 50.4MB/s]
Downloading StormscopeMTG-high.mdlus: 6%|▌ | 70.0M/1.14G [00:02<00:31, 37.1MB/s]
Downloading StormscopeMTG-high.mdlus: 7%|▋ | 80.0M/1.14G [00:02<00:26, 42.3MB/s]
Downloading StormscopeMTG-high.mdlus: 8%|▊ | 90.0M/1.14G [00:02<00:24, 45.7MB/s]
Downloading StormscopeMTG-high.mdlus: 9%|▊ | 100M/1.14G [00:02<00:21, 53.0MB/s]
Downloading StormscopeMTG-high.mdlus: 9%|▉ | 110M/1.14G [00:02<00:19, 57.0MB/s]
Downloading StormscopeMTG-high.mdlus: 10%|█ | 120M/1.14G [00:03<00:18, 60.4MB/s]
Downloading StormscopeMTG-high.mdlus: 11%|█ | 130M/1.14G [00:03<00:24, 44.4MB/s]
Downloading StormscopeMTG-high.mdlus: 12%|█▏ | 140M/1.14G [00:03<00:23, 45.0MB/s]
Downloading StormscopeMTG-high.mdlus: 13%|█▎ | 150M/1.14G [00:03<00:24, 42.9MB/s]
Downloading StormscopeMTG-high.mdlus: 14%|█▎ | 160M/1.14G [00:04<00:23, 45.1MB/s]
Downloading StormscopeMTG-high.mdlus: 15%|█▍ | 170M/1.14G [00:04<00:22, 47.4MB/s]
Downloading StormscopeMTG-high.mdlus: 15%|█▌ | 180M/1.14G [00:04<00:21, 47.1MB/s]
Downloading StormscopeMTG-high.mdlus: 16%|█▋ | 190M/1.14G [00:04<00:21, 47.8MB/s]
Downloading StormscopeMTG-high.mdlus: 17%|█▋ | 200M/1.14G [00:05<00:27, 36.5MB/s]
Downloading StormscopeMTG-high.mdlus: 18%|█▊ | 210M/1.14G [00:05<00:25, 39.3MB/s]
Downloading StormscopeMTG-high.mdlus: 19%|█▉ | 220M/1.14G [00:05<00:26, 37.2MB/s]
Downloading StormscopeMTG-high.mdlus: 20%|█▉ | 230M/1.14G [00:05<00:22, 44.6MB/s]
Downloading StormscopeMTG-high.mdlus: 21%|██ | 240M/1.14G [00:06<00:18, 53.0MB/s]
Downloading StormscopeMTG-high.mdlus: 21%|██▏ | 250M/1.14G [00:06<00:18, 52.4MB/s]
Downloading StormscopeMTG-high.mdlus: 22%|██▏ | 260M/1.14G [00:06<00:24, 38.6MB/s]
Downloading StormscopeMTG-high.mdlus: 23%|██▎ | 270M/1.14G [00:06<00:21, 43.0MB/s]
Downloading StormscopeMTG-high.mdlus: 24%|██▍ | 280M/1.14G [00:07<00:20, 46.4MB/s]
Downloading StormscopeMTG-high.mdlus: 25%|██▍ | 290M/1.14G [00:07<00:19, 48.2MB/s]
Downloading StormscopeMTG-high.mdlus: 26%|██▌ | 300M/1.14G [00:07<00:18, 49.6MB/s]
Downloading StormscopeMTG-high.mdlus: 27%|██▋ | 310M/1.14G [00:07<00:17, 51.9MB/s]
Downloading StormscopeMTG-high.mdlus: 27%|██▋ | 320M/1.14G [00:07<00:16, 52.4MB/s]
Downloading StormscopeMTG-high.mdlus: 28%|██▊ | 330M/1.14G [00:07<00:15, 57.6MB/s]
Downloading StormscopeMTG-high.mdlus: 30%|██▉ | 350M/1.14G [00:08<00:11, 74.2MB/s]
Downloading StormscopeMTG-high.mdlus: 32%|███▏ | 370M/1.14G [00:08<00:09, 83.8MB/s]
Downloading StormscopeMTG-high.mdlus: 33%|███▎ | 390M/1.14G [00:08<00:08, 90.8MB/s]
Downloading StormscopeMTG-high.mdlus: 34%|███▍ | 400M/1.14G [00:08<00:08, 91.5MB/s]
Downloading StormscopeMTG-high.mdlus: 35%|███▌ | 410M/1.14G [00:08<00:08, 93.8MB/s]
Downloading StormscopeMTG-high.mdlus: 36%|███▌ | 420M/1.14G [00:08<00:09, 79.0MB/s]
Downloading StormscopeMTG-high.mdlus: 37%|███▋ | 430M/1.14G [00:09<00:09, 81.0MB/s]
Downloading StormscopeMTG-high.mdlus: 38%|███▊ | 440M/1.14G [00:09<00:08, 85.1MB/s]
Downloading StormscopeMTG-high.mdlus: 39%|███▉ | 460M/1.14G [00:09<00:07, 94.4MB/s]
Downloading StormscopeMTG-high.mdlus: 41%|████ | 480M/1.14G [00:09<00:07, 98.7MB/s]
Downloading StormscopeMTG-high.mdlus: 42%|████▏ | 490M/1.14G [00:09<00:08, 83.0MB/s]
Downloading StormscopeMTG-high.mdlus: 43%|████▎ | 500M/1.14G [00:09<00:08, 80.8MB/s]
Downloading StormscopeMTG-high.mdlus: 44%|████▎ | 510M/1.14G [00:10<00:09, 69.3MB/s]
Downloading StormscopeMTG-high.mdlus: 45%|████▍ | 520M/1.14G [00:10<00:09, 70.9MB/s]
Downloading StormscopeMTG-high.mdlus: 46%|████▌ | 540M/1.14G [00:10<00:07, 85.4MB/s]
Downloading StormscopeMTG-high.mdlus: 47%|████▋ | 550M/1.14G [00:10<00:13, 49.4MB/s]
Downloading StormscopeMTG-high.mdlus: 48%|████▊ | 560M/1.14G [00:11<00:17, 37.3MB/s]
Downloading StormscopeMTG-high.mdlus: 49%|████▉ | 570M/1.14G [00:11<00:20, 30.5MB/s]
Downloading StormscopeMTG-high.mdlus: 50%|████▉ | 580M/1.14G [00:12<00:24, 25.3MB/s]
Downloading StormscopeMTG-high.mdlus: 50%|█████ | 590M/1.14G [00:12<00:20, 29.5MB/s]
Downloading StormscopeMTG-high.mdlus: 51%|█████▏ | 600M/1.14G [00:12<00:17, 35.0MB/s]
Downloading StormscopeMTG-high.mdlus: 52%|█████▏ | 610M/1.14G [00:13<00:15, 39.0MB/s]
Downloading StormscopeMTG-high.mdlus: 53%|█████▎ | 620M/1.14G [00:13<00:13, 42.2MB/s]
Downloading StormscopeMTG-high.mdlus: 54%|█████▍ | 630M/1.14G [00:13<00:12, 45.3MB/s]
Downloading StormscopeMTG-high.mdlus: 55%|█████▍ | 640M/1.14G [00:13<00:11, 48.3MB/s]
Downloading StormscopeMTG-high.mdlus: 56%|█████▌ | 650M/1.14G [00:13<00:09, 54.4MB/s]
Downloading StormscopeMTG-high.mdlus: 56%|█████▋ | 660M/1.14G [00:13<00:09, 58.9MB/s]
Downloading StormscopeMTG-high.mdlus: 57%|█████▋ | 670M/1.14G [00:14<00:08, 62.4MB/s]
Downloading StormscopeMTG-high.mdlus: 59%|█████▉ | 690M/1.14G [00:14<00:06, 76.5MB/s]
Downloading StormscopeMTG-high.mdlus: 60%|█████▉ | 700M/1.14G [00:14<00:06, 73.1MB/s]
Downloading StormscopeMTG-high.mdlus: 61%|██████ | 710M/1.14G [00:14<00:06, 78.8MB/s]
Downloading StormscopeMTG-high.mdlus: 62%|██████▏ | 720M/1.14G [00:14<00:06, 71.1MB/s]
Downloading StormscopeMTG-high.mdlus: 62%|██████▏ | 730M/1.14G [00:14<00:07, 65.0MB/s]
Downloading StormscopeMTG-high.mdlus: 63%|██████▎ | 740M/1.14G [00:15<00:07, 59.7MB/s]
Downloading StormscopeMTG-high.mdlus: 64%|██████▍ | 750M/1.14G [00:15<00:07, 55.7MB/s]
Downloading StormscopeMTG-high.mdlus: 65%|██████▌ | 760M/1.14G [00:15<00:08, 49.1MB/s]
Downloading StormscopeMTG-high.mdlus: 66%|██████▌ | 770M/1.14G [00:16<00:14, 29.2MB/s]
Downloading StormscopeMTG-high.mdlus: 67%|██████▋ | 780M/1.14G [00:17<00:18, 22.6MB/s]
Downloading StormscopeMTG-high.mdlus: 68%|██████▊ | 790M/1.14G [00:18<00:24, 16.4MB/s]
Downloading StormscopeMTG-high.mdlus: 68%|██████▊ | 800M/1.14G [00:18<00:22, 17.5MB/s]
Downloading StormscopeMTG-high.mdlus: 69%|██████▉ | 810M/1.14G [00:18<00:18, 20.3MB/s]
Downloading StormscopeMTG-high.mdlus: 70%|███████ | 820M/1.14G [00:19<00:16, 22.7MB/s]
Downloading StormscopeMTG-high.mdlus: 71%|███████ | 830M/1.14G [00:19<00:13, 26.0MB/s]
Downloading StormscopeMTG-high.mdlus: 72%|███████▏ | 840M/1.14G [00:19<00:11, 30.0MB/s]
Downloading StormscopeMTG-high.mdlus: 73%|███████▎ | 850M/1.14G [00:20<00:10, 32.7MB/s]
Downloading StormscopeMTG-high.mdlus: 74%|███████▎ | 860M/1.14G [00:20<00:09, 35.4MB/s]
Downloading StormscopeMTG-high.mdlus: 74%|███████▍ | 870M/1.14G [00:20<00:08, 36.6MB/s]
Downloading StormscopeMTG-high.mdlus: 75%|███████▌ | 880M/1.14G [00:20<00:08, 34.3MB/s]
Downloading StormscopeMTG-high.mdlus: 76%|███████▌ | 890M/1.14G [00:21<00:09, 31.8MB/s]
Downloading StormscopeMTG-high.mdlus: 77%|███████▋ | 900M/1.14G [00:21<00:09, 29.6MB/s]
Downloading StormscopeMTG-high.mdlus: 78%|███████▊ | 910M/1.14G [00:22<00:09, 28.0MB/s]
Downloading StormscopeMTG-high.mdlus: 79%|███████▊ | 920M/1.14G [00:22<00:10, 25.9MB/s]
Downloading StormscopeMTG-high.mdlus: 80%|███████▉ | 930M/1.14G [00:23<00:10, 24.3MB/s]
Downloading StormscopeMTG-high.mdlus: 80%|████████ | 940M/1.14G [00:23<00:09, 24.6MB/s]
Downloading StormscopeMTG-high.mdlus: 81%|████████▏ | 950M/1.14G [00:23<00:08, 26.8MB/s]
Downloading StormscopeMTG-high.mdlus: 82%|████████▏ | 960M/1.14G [00:23<00:06, 31.9MB/s]
Downloading StormscopeMTG-high.mdlus: 83%|████████▎ | 970M/1.14G [00:24<00:05, 36.9MB/s]
Downloading StormscopeMTG-high.mdlus: 84%|████████▍ | 980M/1.14G [00:24<00:05, 39.4MB/s]
Downloading StormscopeMTG-high.mdlus: 85%|████████▍ | 990M/1.14G [00:24<00:04, 43.3MB/s]
Downloading StormscopeMTG-high.mdlus: 86%|████████▌ | 0.98G/1.14G [00:24<00:03, 50.8MB/s]
Downloading StormscopeMTG-high.mdlus: 86%|████████▋ | 0.99G/1.14G [00:24<00:03, 50.6MB/s]
Downloading StormscopeMTG-high.mdlus: 87%|████████▋ | 1.00G/1.14G [00:25<00:02, 55.0MB/s]
Downloading StormscopeMTG-high.mdlus: 88%|████████▊ | 1.01G/1.14G [00:25<00:02, 58.4MB/s]
Downloading StormscopeMTG-high.mdlus: 89%|████████▉ | 1.02G/1.14G [00:25<00:02, 67.1MB/s]
Downloading StormscopeMTG-high.mdlus: 91%|█████████ | 1.04G/1.14G [00:25<00:01, 71.5MB/s]
Downloading StormscopeMTG-high.mdlus: 92%|█████████▏| 1.04G/1.14G [00:25<00:01, 76.8MB/s]
Downloading StormscopeMTG-high.mdlus: 92%|█████████▏| 1.05G/1.14G [00:25<00:01, 61.6MB/s]
Downloading StormscopeMTG-high.mdlus: 93%|█████████▎| 1.06G/1.14G [00:26<00:01, 57.6MB/s]
Downloading StormscopeMTG-high.mdlus: 94%|█████████▍| 1.07G/1.14G [00:26<00:01, 56.6MB/s]
Downloading StormscopeMTG-high.mdlus: 95%|█████████▍| 1.08G/1.14G [00:26<00:01, 53.6MB/s]
Downloading StormscopeMTG-high.mdlus: 96%|█████████▌| 1.09G/1.14G [00:26<00:01, 47.4MB/s]
Downloading StormscopeMTG-high.mdlus: 97%|█████████▋| 1.10G/1.14G [00:27<00:00, 51.8MB/s]
Downloading StormscopeMTG-high.mdlus: 98%|█████████▊| 1.11G/1.14G [00:27<00:00, 46.5MB/s]
Downloading StormscopeMTG-high.mdlus: 98%|█████████▊| 1.12G/1.14G [00:27<00:00, 45.7MB/s]
Downloading StormscopeMTG-high.mdlus: 99%|█████████▉| 1.13G/1.14G [00:27<00:00, 46.3MB/s]
Downloading StormscopeMTG-high.mdlus: 100%|██████████| 1.14G/1.14G [00:27<00:00, 49.0MB/s]
Downloading StormscopeMTG-high.mdlus: 100%|██████████| 1.14G/1.14G [00:27<00:00, 43.9MB/s]
Downloading metadata.nc: 0%| | 0.00/32.2M [00:00<?, ?B/s]
Downloading metadata.nc: 31%|███ | 10.0M/32.2M [00:01<00:03, 7.47MB/s]
Downloading metadata.nc: 62%|██████▏ | 20.0M/32.2M [00:01<00:00, 15.1MB/s]
Downloading metadata.nc: 93%|█████████▎| 30.0M/32.2M [00:01<00:00, 22.3MB/s]
Downloading metadata.nc: 100%|██████████| 32.2M/32.2M [00:01<00:00, 18.4MB/s]Fetch Initial Condition¶
We fetch an initial window of 6 consecutive FCI frames ending at the chosen
analysis time. fetch_data calls the data source at start_time +
lead_time for each lead-time offset defined by the model ([-50 min, -40
min, ..., 0 min] for a 6-frame window), and the model's default source
returns every channel on the model grid.
# Start time; replace with any time for which MTG-I1 FCI data is available.
# StormScopeMeteosatEU was trained on November 2024 - May 2026 data; start times
# should generally be outside that period.
start_time = np.datetime64(datetime(2026, 6, 30, 12, 0, 0, tzinfo=timezone.utc))
in_coords = model.input_coords()
x = fetch_data(
model.default_sources(),
time=np.array([start_time]),
variable=in_coords["variable"].values,
lead_time=in_coords["lead_time"].values,
device=device,
)
Console output81 lines
Downloading MTG products: 0%| | 0/1 [00:00<?, ?it/s]
2026-11-19 19:11:41.451 | INFO | earth2studio.data.meteosat_fci:_fetch_product:572 - Downloading MTG FCI product: W_XX-EUMETSAT-Darmstadt,IMG+SAT,MTI1+FCI-1C-RRAD-FDHSI-FD--x-x---x_C_EUMT_20260630111317_IDPFI_OPE_20260630111007_20260630111935_N__O_0068_0000
Downloading MTG products: 0%| | 0/1 [00:08<?, ?it/s]
Downloading MTG products: 100%|██████████| 1/1 [02:03<00:00, 123.71s/it]
Downloading MTG products: 100%|██████████| 1/1 [02:03<00:00, 123.71s/it]
Downloading MTG products: 0%| | 0/1 [00:00<?, ?it/s]
Downloading MTG products: 100%|██████████| 1/1 [00:00<00:00, 593.93it/s]
Downloading MTG products: 0%| | 0/1 [00:00<?, ?it/s]
2026-11-19 19:13:52.804 | INFO | earth2studio.data.meteosat_fci:_fetch_product:572 - Downloading MTG FCI product: W_XX-EUMETSAT-Darmstadt,IMG+SAT,MTI1+FCI-1C-RRAD-FDHSI-FD--x-x---x_C_EUMT_20260630112312_IDPFI_OPE_20260630112007_20260630112939_N__O_0069_0000
Downloading MTG products: 0%| | 0/1 [00:05<?, ?it/s]
Downloading MTG products: 100%|██████████| 1/1 [03:17<00:00, 197.79s/it]
Downloading MTG products: 100%|██████████| 1/1 [03:17<00:00, 197.79s/it]
Downloading MTG products: 0%| | 0/1 [00:00<?, ?it/s]
Downloading MTG products: 100%|██████████| 1/1 [00:00<00:00, 152.37it/s]
Downloading MTG products: 0%| | 0/1 [00:00<?, ?it/s]
2026-11-19 19:17:17.674 | INFO | earth2studio.data.meteosat_fci:_fetch_product:572 - Downloading MTG FCI product: W_XX-EUMETSAT-Darmstadt,IMG+SAT,MTI1+FCI-1C-RRAD-FDHSI-FD--x-x---x_C_EUMT_20260630113315_IDPFI_OPE_20260630113007_20260630113939_N__O_0070_0000
Downloading MTG products: 0%| | 0/1 [00:04<?, ?it/s]
2026-11-19 19:18:44.174 | WARNING | earth2studio.data.utils:async_retry:1183 - Retry 1/3 after error: ('Connection broken: IncompleteRead(413440128 bytes read, 608588490 more expected)', IncompleteRead(413440128 bytes read, 608588490 more expected)). Waiting 2.3s
Downloading MTG products: 0%| | 0/1 [01:30<?, ?it/s]
2026-11-19 19:18:51.869 | INFO | earth2studio.data.meteosat_fci:_fetch_product:572 - Downloading MTG FCI product: W_XX-EUMETSAT-Darmstadt,IMG+SAT,MTI1+FCI-1C-RRAD-FDHSI-FD--x-x---x_C_EUMT_20260630113315_IDPFI_OPE_20260630113007_20260630113939_N__O_0070_0000
Downloading MTG products: 0%| | 0/1 [01:38<?, ?it/s]
Downloading MTG products: 100%|██████████| 1/1 [04:47<00:00, 287.49s/it]
Downloading MTG products: 100%|██████████| 1/1 [04:47<00:00, 287.49s/it]
Downloading MTG products: 0%| | 0/1 [00:00<?, ?it/s]
Downloading MTG products: 100%|██████████| 1/1 [00:00<00:00, 44.45it/s]
Downloading MTG products: 0%| | 0/1 [00:00<?, ?it/s]
2026-11-19 19:22:16.989 | INFO | earth2studio.data.meteosat_fci:_fetch_product:572 - Downloading MTG FCI product: W_XX-EUMETSAT-Darmstadt,IMG+SAT,MTI1+FCI-1C-RRAD-FDHSI-FD--x-x---x_C_EUMT_20260630114312_IDPFI_OPE_20260630114007_20260630114939_N__O_0071_0000
Downloading MTG products: 0%| | 0/1 [00:07<?, ?it/s]
2026-11-19 19:23:38.833 | WARNING | earth2studio.data.utils:async_retry:1183 - Retry 1/3 after error: ('Connection broken: IncompleteRead(944935878 bytes read, 77779449 more expected)', IncompleteRead(944935878 bytes read, 77779449 more expected)). Waiting 2.2s
Downloading MTG products: 0%| | 0/1 [01:29<?, ?it/s]
2026-11-19 19:23:46.397 | INFO | earth2studio.data.meteosat_fci:_fetch_product:572 - Downloading MTG FCI product: W_XX-EUMETSAT-Darmstadt,IMG+SAT,MTI1+FCI-1C-RRAD-FDHSI-FD--x-x---x_C_EUMT_20260630114312_IDPFI_OPE_20260630114007_20260630114939_N__O_0071_0000
Downloading MTG products: 0%| | 0/1 [01:36<?, ?it/s]
Downloading MTG products: 100%|██████████| 1/1 [04:05<00:00, 245.46s/it]
Downloading MTG products: 100%|██████████| 1/1 [04:05<00:00, 245.46s/it]
Downloading MTG products: 0%| | 0/1 [00:00<?, ?it/s]
Downloading MTG products: 100%|██████████| 1/1 [00:00<00:00, 69.10it/s]
Downloading MTG products: 0%| | 0/1 [00:00<?, ?it/s]
2026-11-19 19:26:28.311 | INFO | earth2studio.data.meteosat_fci:_fetch_product:572 - Downloading MTG FCI product: W_XX-EUMETSAT-Darmstadt,IMG+SAT,MTI1+FCI-1C-RRAD-FDHSI-FD--x-x---x_C_EUMT_20260630115316_IDPFI_OPE_20260630115007_20260630115939_N__O_0072_0000
Downloading MTG products: 0%| | 0/1 [00:04<?, ?it/s]
Downloading MTG products: 100%|██████████| 1/1 [03:46<00:00, 226.93s/it]
Downloading MTG products: 100%|██████████| 1/1 [03:46<00:00, 226.93s/it]
Downloading MTG products: 0%| | 0/1 [00:00<?, ?it/s]
Downloading MTG products: 100%|██████████| 1/1 [00:00<00:00, 54.61it/s]
Downloading MTG products: 0%| | 0/1 [00:00<?, ?it/s]
2026-11-19 19:30:24.546 | INFO | earth2studio.data.meteosat_fci:_fetch_product:572 - Downloading MTG FCI product: W_XX-EUMETSAT-Darmstadt,IMG+SAT,MTI1+FCI-1C-RRAD-FDHSI-FD--x-x---x_C_EUMT_20260630120316_IDPFI_OPE_20260630120007_20260630120939_N__O_0073_0000
Downloading MTG products: 0%| | 0/1 [00:05<?, ?it/s]
Downloading MTG products: 100%|██████████| 1/1 [03:14<00:00, 194.18s/it]
Downloading MTG products: 100%|██████████| 1/1 [03:14<00:00, 194.18s/it]
Downloading MTG products: 0%| | 0/1 [00:00<?, ?it/s]
Downloading MTG products: 100%|██████████| 1/1 [00:00<00:00, 203.35it/s]Add Ensemble Dimension¶
The model expects input of shape (ensemble, time, lead_time, variable, y, x).
Up to GPU memory limits, ensemble_size can be increased to produce multiple
independent ensemble members in a single forward pass.
Execute the Nowcast¶
create_iterator handles the autoregressive rollout for us: each yielded
value advances the prediction by one 10-minute interval, starting with the
first forecast.
n_steps = 12 # 2 hours of 10-minute forecast steps
for step, x_pred in enumerate(tqdm(model.create_iterator(x), total=n_steps)):
if step == n_steps - 1:
break
Console output13 lines
0%| | 0/12 [00:00<?, ?it/s]
8%|▊ | 1/12 [00:44<08:07, 44.28s/it]
17%|█▋ | 2/12 [01:13<05:51, 35.14s/it]
25%|██▌ | 3/12 [01:41<04:50, 32.23s/it]
33%|███▎ | 4/12 [02:10<04:07, 30.98s/it]
42%|████▏ | 5/12 [02:39<03:32, 30.30s/it]
50%|█████ | 6/12 [03:09<02:59, 29.97s/it]
58%|█████▊ | 7/12 [03:38<02:28, 29.74s/it]
67%|██████▋ | 8/12 [04:08<01:58, 29.66s/it]
75%|███████▌ | 9/12 [04:37<01:28, 29.57s/it]
83%|████████▎ | 10/12 [05:06<00:59, 29.56s/it]
92%|█████████▏| 11/12 [05:36<00:29, 29.52s/it]
92%|█████████▏| 11/12 [06:05<00:33, 33.27s/it]Post Processing¶
Plot the final predicted FCI frame as a true-color RGB composite (VIS 0.6 /
0.5 / 0.4 µm) in geostationary projection. Off-Earth pixels are already set
to NaN by denormalize. For a regional view, crop_output crops the
forecast to the requested region.
rgb_channels = ["fci06vis", "fci05vis", "fci04vis"]
field = model.crop_output(x_pred).e2s.as_numpy().isel(ensemble=0, time=0, lead_time=0)
# here we approximately replicate EUMETSAT's recipe for "true-colour" RGB
rgb = (field.sel(variable=rgb_channels) / 24.0).clip(min=0, max=1) * 255
rgb = rgb.transpose("y", "x", "variable").values
rgb = np.interp(rgb, [0, 30, 60, 120, 190, 255], [0, 110, 160, 210, 240, 255]) / 255.0
proj = ccrs.Geostationary(
central_longitude=0.0,
satellite_height=PERSPECTIVE_POINT_HEIGHT,
globe=ccrs.Globe(semimajor_axis=SEMI_MAJOR_AXIS, semiminor_axis=SEMI_MINOR_AXIS),
sweep_axis="y",
)
# Pixel-edge extent in metres from the scan-angle labels; x increases westward.
x_angle, y_angle = field["x"].values, field["y"].values
dx, dy = abs(x_angle[1] - x_angle[0]), abs(y_angle[1] - y_angle[0])
extent = [
-(x_angle.max() + dx / 2) * PERSPECTIVE_POINT_HEIGHT,
-(x_angle.min() - dx / 2) * PERSPECTIVE_POINT_HEIGHT,
(y_angle.min() - dy / 2) * PERSPECTIVE_POINT_HEIGHT,
(y_angle.max() + dy / 2) * PERSPECTIVE_POINT_HEIGHT,
]
aspect = (extent[1] - extent[0]) / (extent[3] - extent[2])
fig_height = 8
fig = plt.figure(figsize=(fig_height * aspect, fig_height))
ax = fig.add_subplot(1, 1, 1, projection=proj)
ax.set_xlim(extent[0], extent[1])
ax.set_ylim(extent[2], extent[3])
ax.coastlines(color="white", linewidth=0.8)
# Rows run south to north and columns west to east, matching the extent.
im = ax.imshow(rgb, transform=proj, extent=extent, origin="lower")
valid_time = field["time"].values + field["lead_time"].values
valid_time = np.datetime_as_string(valid_time, unit="m").replace("T", " ")
lead_min = int(field["lead_time"].values / np.timedelta64(1, "m"))
ax.set_title(
f"StormScopeMeteosatEU — RGB\n" f"Valid {valid_time} UTC (+{lead_min} min)"
)
fig.tight_layout()
fig.savefig("outputs/04_stormscope_meteosat_example.png", dpi=150)
