The Marine Biogeochemical Evaluation Toolkit, bgcval2

Lee de Mora1, Valeriu Predoi2

1 Plymouth Marine Laboratory,  2 NCAS-CMS Reading

The marine biogeochemistry validation toolkit, bgcval, has been a key part of the validation of the United Kingdom Earth System model since the early days of UKESM1 development back in 2015. Since then, bgcval has been deployed non-stop in the background for monitoring and scientific evaluation of the marine component of simulations for the development of UKESM1.0, our CMIP6 contributions, and testing of UKESM1.1 and UKESM2.0.

Bgcval simplifies the automation and distribution of model validation suites by generating a shareable web-visible html report comparing the marine component of several different model simulations. The bgcval code is run centrally on the CEDA computing system, JASMIN, and users almost never need to interact with the underlying python code. Most of the time, people just fire up their favourite browser, load the bgcval website and browse the output figures. Users can even check in on active simulations during their morning commute or on their way to meetings.

A diverse range of performance metrics are included in the toolkit, such as for the physical ocean; temperature, salinity, currents, and circulation, and for marine biogeochemistry; primary production, chlorophyll, nutrients, and carbonate chemistry. The important headline results are quick to check at the top of the page, then further down there’s a more complete picture of the simulations, including various time development metrics at pre-defined regions and depth levels.

Figure 1: bgcval2 interface showing key metrics

While the html interface is the same in the recently updated bgcval2, behind the scenes, bgcval2 includes a whole range of upgrades and improvements. The bulk of the recent development, led by Valeriu “V” Predoi (NCAS-CMS Reading), has really raised the bar on the code standards and brought several best practices into bgcval2. In a short time, V has updated the codebase to Python3, made bgcval2 into a portable and deployable Python package with a new conda-pip environment, included integration & unit testing, and support for nctoolkit. We’ve started to include additional models and grids, such as NEMO-ORCA025, the Atlantic Meridional Margins domain (AMM) and the ERSEM marine biogeochemistry model. Also, we have shared bgcval2 to a new open GitHub repository, with several users already deploying the code and contributing to its development.

We will continue to develop bgcval2, including the migration from the bespoke bgcval (v1) analysis engine to use more standardised tools, such as nctoolkit. We plan to include more metrics from the cryosphere and build support for more model domains and analyses. On the deployment side, we plan to release conda-forge and PyPI packages to further reduce barriers to deployment. Bgcval2 has a small but growing user group and we’re excitedly looking forward to the next steps for the tools. Please get in touch if you are interested in setting up an analysis for your UKESM simulations!


de Mora, L. et al: BGC-val: a model- and grid-independent Python toolkit to evaluate marine biogeochemical models, Geosci. Model Dev., 11, 4215–4240,  2018.

Bgcval2, github development page, nctoolkit: Fast and easy analysis of netCDF data in Python: