WeatherNext 3 Python: Read the Ensemble Without Downloading the World

The WeatherNext 3 full ensemble lives in chunked Zarr arrays on Google Cloud Storage. Python can open the store lazily with xarray, choose one initialization and read only the variables, members and lead times that matter. This independent guide covers the two stores, the dimensions you will actually see and a reproducible first query. For the access and billing context, read the data access guide. Updated November 26, 2026 by the WeatherNext 3 Editorial Team.

Full ensemble access may require a Google Cloud billing project and requester-pays header. The statistics store has a simpler path. Verify current Google terms before use.

A luminous developer notebook beside a rotating atmospheric globe and Zarr grid shards

What you need to know before opening the store

Three details decide whether your first notebook is fast, expensive or simply pointed at the wrong dataset.

64 Members are stored in the `sample` dimension of the raw ensemble store.

64

Members are stored in the `sample` dimension of the raw ensemble store.

2 Stores: full ensemble and precomputed statistics, for different jobs.

2

Stores: full ensemble and precomputed statistics, for different jobs.

3 Packages for the documented path: `xarray`, `zarr` and `obstore`.

3

Packages for the documented path: `xarray`, `zarr` and `obstore`.

Python workflow

How do you open WeatherNext 3 with xarray?

Use the smallest store that answers the question. The full ensemble is for member-level analysis; the statistics store is for mean and percentile summaries.

An open glass data cube revealing atmospheric arrays and computational grid cells

WeatherNext 3's raw forecast data is delivered as Zarr v3 stores on Google Cloud Storage. Zarr is useful here because it stores multidimensional arrays in compressed chunks, so xarray can request a region or a lead-time slice without pulling the entire global grid into memory.

Which WeatherNext 3 Python store should you use?

Google documents two spatial stores:

  • gs://weathernext3_spatial/weathernext_3_0_0/zarr/ contains the raw 64-member ensemble, including 3D pressure levels and all surface variables. The full-ensemble bucket may require your Google Cloud billing project in a requester-pays header.

  • gs://weathernext3_statistics_spatial/weathernext_3_0_0_statistics/zarr/ contains precomputed _mean, _p10, _p25, _p50, _p75 and _p90 fields. Use it when you do not need individual members.

For a first read, the statistics store is the least surprising choice. For uncertainty analysis, member clustering or custom probabilities, use the raw ensemble store and keep the analysis chunked.

How do you open one WeatherNext 3 run in Python?

Install the packages named in the Google guide and open the run with xr.open_zarr. The example below is intentionally lazy: it prints the dataset and selects a small region instead of loading every variable.

pip install xarray zarr obstore
import numpy as np
import obstore
import xarray as xr
import zarr

gcs_store = obstore.store.GCSStore(
    bucket="weathernext3_spatial",
    prefix="weathernext_3_0_0/zarr/2026_to_present/20260826_00hr_01_preds/predictions.zarr",
    client_options={
        "default_headers": {"x-goog-user-project": "YOUR_BILLING_PROJECT"}
    },
)
zstore = zarr.storage.ObjectStore(gcs_store)
ds = xr.open_zarr(zstore, chunks={"sample": 1})

print(ds[["temperature_2m", "station_head_temperature_2m"]])
print(ds["init_time"].values)
print(ds["lead_time"].values[:5])

The raw ensemble uses sample for the 64 members. Surface fields use the lat_0p1 and lon_0p1 coordinates; station-head fields use lat_0p05 and lon_0p05. Longitudes are stored in the 0 to 360 degree convention, so New York is around 286 degrees and London is around 359.9 degrees. Convert a conventional negative longitude with lon % 360.

How do you select one region and a short lead time?

Select coordinates before computing anything. This is the Python equivalent of filtering a database table: control the slice first, then materialize only the result you need.

nyc = ds[["temperature_2m"]].sel(
    lat_0p1=slice(40.5, 40.9),
    lon_0p1=slice(285.74, 286.30),
    lead_time=[np.timedelta64(h, "h") for h in [6, 12, 18, 24]],
    lead_subtime=np.timedelta64(0, "h"),
)

nyc_mean_c = nyc["temperature_2m"].mean(dim=("sample", "lat_0p1", "lon_0p1")) - 273.15
print(nyc_mean_c.values)

For continuous hourly series from the raw ensemble, stack lead_time and lead_subtime as shown in the official GCS guide. The statistics store is already flattened onto a single one-hour lead_time axis, so use it when the hourly sequence is the main product.

How do you work with all 64 members?

Keep sample lazy until you have reduced the spatial and temporal dimensions. A global 64-member calculation is a different engineering task from a city-sized slice. For a regional file, a good pattern is: select one init, one variable and one bounding box, then compute the mean, median and spread over sample.

regional = ds["temperature_2m"].sel(
    lat_0p1=slice(35.0, 60.0),
    lon_0p1=slice(0.0, 20.0),
    lead_time=np.timedelta64(6, "h"),
    lead_subtime=np.timedelta64(0, "h"),
)

mean_k = regional.mean("sample", skipna=True)
spread_k = regional.std("sample", skipna=True)
p10_k, p50_k, p90_k = regional.quantile([0.1, 0.5, 0.9], dim="sample")

Do not compare a mean from one initialization with a percentile from another. Preserve init_time, lead_time and lead_subtime in the output, and convert valid time explicitly when you build a table or a chart.

How do you validate a Python forecast subset?

Check five things before trusting a notebook: the store path, the initialization, the member count, the longitude convention and the units. Temperature and dew point are stored in kelvin; precipitation is stored in metres per one-hour step. A plausible-looking chart with the wrong unit is still wrong.

For a production pipeline, cache the regional subset rather than repeatedly reopening the global store. Keep the source URI and run timestamp in the cache key so a new run cannot silently reuse yesterday's data.

Primary sources

WeatherNext 3 Python questions

Practical answers for a first xarray and Zarr notebook.







Next: how to interpret the 64-member ensemble or the BigQuery SQL route.

Turn a Zarr subset into an hourly forecast

Use Python for the data work, then inspect the same location and time window in a visual forecast. Seven-day free trial, cancel anytime. Related: the model guide and accuracy and verification.

WeatherNext 3 Python: Xarray, Zarr and Ensemble Data