Skip to main content
OceanBench logo

OceanBench

The latest version of OceanBench can be found on PyPI. Link to discover EDITO Information on what versions of Python OceanBench supports can be found on PyPI. Information on what kind of operating systems OceanBench can be installed on. Information on the OceanBench licence. REUSE status

OceanBench is a benchmarking tool to evaluate ocean forecasting systems against reference ocean analysis datasets (such as 2024 GLORYS reanalysis and GLO12 analysis) as well as observations.

Citation

OceanBench's scientific paper is published in NeurIPS 2025 and is accessible at https://openreview.net/forum?id=wZGe1Kqs8G.

@inproceedings{
  aouni2025oceanbench,
  title={OceanBench: A Benchmark for Data-Driven Global Ocean Forecasting systems},
  author={Anass El Aouni and Quentin Gaudel and Juan Emmanuel Johnson and REGNIER Charly and Julien Le Sommer and van Gennip and Ronan Fablet and Marie Drevillon and Yann DRILLET and Pierre Yves Le Traon},
  booktitle={The Thirty-ninth Annual Conference on Neural Information Processing Systems Datasets and Benchmarks Track},
  year={2025},
  url={https://openreview.net/forum?id=wZGe1Kqs8G}
}

Score table and system comparison

The official score table is available on the OceanBench website. Any version, region and track can be exported as CSV, Parquet or Zarr with the Export buttons next to the pickers, or fetched through the Scores API:

curl -O https://oceanbench.edito.eu/api/scores/index.json

Open GLORYS dataset to train your ocean forecasting system

You can train your model with GLORYS reanalysis from 1993 to 2019 (included). The years covered by the benchmark must not be used for training. From an environment with OceanBench installed, run:

import oceanbench

oceanbench.datasets.training.glorys_reanalysis()

to open the 1/12° GLORYS dataset as a lazy xarray.Dataset, through the Copernicus Marine Toolbox (see Dependency on the Copernicus Marine Service):

<xarray.Dataset> Size: 140TB
Dimensions:    (depth: 50, latitude: 2041, longitude: 4320, time: 9861)
Coordinates:
  * depth      (depth) float32 200B 0.494 1.541 2.646 ... 5.275e+03 5.728e+03
  * latitude   (latitude) float32 8kB -80.0 -79.92 -79.83 ... 89.83 89.92 90.0
  * longitude  (longitude) float32 17kB -180.0 -179.9 -179.8 ... 179.8 179.9
  * time       (time) datetime64[ns] 79kB 1993-01-01 1993-01-02 ... 2019-12-31
Data variables:
    thetao     (time, depth, latitude, longitude) float64 35TB dask.array<chunksize=(50, 1, 512, 2048), meta=np.ndarray>
    so         (time, depth, latitude, longitude) float64 35TB dask.array<chunksize=(50, 1, 512, 2048), meta=np.ndarray>
    uo         (time, depth, latitude, longitude) float64 35TB dask.array<chunksize=(50, 1, 512, 2048), meta=np.ndarray>
    vo         (time, depth, latitude, longitude) float64 35TB dask.array<chunksize=(50, 1, 512, 2048), meta=np.ndarray>
    zos        (time, latitude, longitude) float64 696GB dask.array<chunksize=(50, 512, 2048), meta=np.ndarray>

For training on the 1 degree track, OceanBench also exposes the 1 degree GLORYS dataset, covering the same years:

import oceanbench

oceanbench.datasets.training.glorys_reanalysis_1_degree()

Evaluate your system with OceanBench

The evaluation of a system runs several evaluation methods against a set of forecasts (produced by the system), namely the challenger dataset, opened as an xarray Dataset by a Python file, the challenger file. It prints the score tables and writes them to a scores file, <challenger>.<region>.scores.json.

The OceanBench documentation describes the shape a challenger dataset must have, as well as the definitions of the methods used to evaluate systems.

Official evaluation

All official challenger files are maintained and remain executable in order to update the scores with new OceanBench versions (all official challengers are re-evaluated with each new version).

To officially submit your system to OceanBench, please open an issue on this repository attaching one of the following:

  1. A way to access the system output data in a standard format (e.g. Zarr or NetCDF).
  2. A way to execute the system code or container, so that the maintainers can reproduce the output, along with clear instructions for how to run it (e.g., input/output format, required dependencies, etc.).

Optionally, attach the challenger file and the scores file resulting from an evaluation.

In addition, please provide the following metadata:

  • The organization that leads the construction or operation of the system.
  • A link to the reference paper of the system.
  • The system method. For example, "Physics-based", "ML-based" or "Hybrid".
  • The system type. For example, "Forecast (deterministic)" or "Forecast (ensemble)".
  • The system initial conditions. For example, "GLO12/IFS".
  • The approximate horizontal resolution of the system. For example, "1/12°" or "1/4°".

Get started evaluating your system

Follow the Get started evaluating your system guide, or this notebook it is made from, to compute the OceanBench scores of a sample of the GLONET system, interpolated to 1 degree. It needs no credentials. The notebook opens the challenger dataset and computes each score table with the functions of oceanbench.metrics.

You can replace the cell that opens the challenger dataset with your code and execute the notebook. The official evaluation of a system is oceanbench evaluate.

Execute on your own resources

You will need to install OceanBench manually in your environment.

Installation
Using pip via PyPI
pip install oceanbench

The notebook also needs Jupyter:

pip install jupyter
From sources
git clone git@github.com:mercator-ocean/oceanbench.git && cd oceanbench/ && pip install --editable .

Execute on EDITO

You can open and manually execute the notebook in EDITO datalab by clicking here: Link to open resource in EDITO

Evaluate a system

Once installed, you can evaluate your system from the command line or using python.

CLI

oceanbench evaluate path/to/challenger.py

To evaluate multiple challengers in parallel:

oceanbench evaluate challenger_a.py challenger_b.py

By default, OceanBench evaluates the global domain. To evaluate an official region, pass its identifier:

oceanbench evaluate path/to/challenger.py --region ibi

To evaluate a custom region, write its bounding box in a JSON file:

{
  "id": "western_med",
  "display_name": "Western Mediterranean",
  "bounds": {
    "minimum_latitude": 34.0,
    "maximum_latitude": 44.5,
    "minimum_longitude": -1.0,
    "maximum_longitude": 18.0
  }
}

Then pass it to the CLI:

oceanbench evaluate path/to/challenger.py --region-file path/to/region.json

Each evaluation prints the score tables and the duration of each step, and writes a scores file in the current directory. Its name is derived from the challenger file name and region (e.g. challenger.py produces challenger.global.scores.json for the global benchmark and challenger.ibi.scores.json for the IBI benchmark).

To also upload the scores files to an S3 bucket:

oceanbench evaluate path/to/challenger.py --output-bucket my-bucket --output-prefix results

To run OceanBench on an HPC compute node without internet access, see Run OceanBench offline.

Python

import oceanbench

oceanbench.evaluate_challenger("path/to/file/opening/the/challenger/datasets.py")

It prints the score tables and writes the same scores file as the CLI.

More details in the documentation.

Dependency on the Copernicus Marine Service

Running OceanBench to evaluate systems with 1/12° resolution uses the Copernicus Marine Toolbox and therefore requires authentication with the Copernicus Marine Service.

If you're running OceanBench in a non-interactive way, please follow the Copernicus Marine Toolbox documentation to login to the Copernicus Marine Service before running the bench.

Contribution

Your help to improve OceanBench is welcome. Please first read contribution instructions here.

License

Licensed under the EUPL-1.2 license.

About

Implemented by:

Mercator Ocean International logo

As part of a fruitful collaboration with:

PPR logo IMTA logo UGA logo IGEO logo

Powered by:

EDITO logo

Metadata

Release files for oceanbench 0.7.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for oceanbench 0.7.0
File Size Uploaded Provenance Actions
oceanbench-0.7.0.tar.gz 69.2 kB With provenance Details for oceanbench-0.7.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for oceanbench 0.7.0
File Interpreter ABI Platform Actions
oceanbench-0.7.0-py3-none-any.whl Python 3 none any Details for oceanbench-0.7.0-py3-none-any.whl

Total release size: 161.9 kB

Release files / oceanbench-0.7.0.tar.gz

Download URL oceanbench-0.7.0.tar.gz
Size 69.2 kB
Tags Source
SHA-256 checksum
How to use checksums
2ff3f247c1c697576f984013213952f04a392f6993c3e032149196dc791ae14c
BLAKE2b-256 checksum
How to use checksums
306e3ed013af775b68d4e8f93e3472e937b633812c7129584769d9e1f644e979
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 18, 2026.

Transparency log

Release files / oceanbench-0.7.0-py3-none-any.whl

Download URL oceanbench-0.7.0-py3-none-any.whl
Size 92.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
88c6f3d75d4567d281d7f8c3884b899f73b08b57b1943f09df0aea64069dd867
BLAKE2b-256 checksum
How to use checksums
233b8c3593d180aab79b750aa9bf9d32fd778ec65556284bfbf884b260e58522
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 18, 2026.

Transparency log

Security for oceanbench 0.7.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for oceanbench-0.7.0.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 18, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page