Preprints
https://doi.org/10.5194/gmd-2024-79
https://doi.org/10.5194/gmd-2024-79
Submitted as: development and technical paper
 | 
03 Jun 2024
Submitted as: development and technical paper |  | 03 Jun 2024
Status: a revised version of this preprint is currently under review for the journal GMD.

A Fortran-Python Interface for Integrating Machine Learning Parameterization into Earth System Models

Tao Zhang, Cyril Morcrette, Meng Zhang, Wuyin Lin, Shaocheng Xie, Ye Liu, Kwinten Van Weverberg, and Joana Rodrigues

Abstract. Parameterizations in Earth System Models (ESMs) are subject to biases and uncertainties arising from subjective empirical assumptions and incomplete understanding of the underlying physical processes. Recently, the growing representational capability of machine learning (ML) in solving complex problems has spawned immense interests in climate science applications. Specifically, ML-based parameterizations have been developed to represent convection, radiation and microphysics processes in ESMs by learning from observations or high-resolution simulations, which have the potential to improve the accuracies and alleviate the uncertainties. Previous works have developed some surrogate models for these processes using ML. These surrogate models need to be coupled with the dynamical core of ESMs to investigate the effectiveness and their performance in a coupled system. In this study, we present a novel Fortran-Python interface designed to seamlessly integrate ML parameterizations into ESMs. This interface showcases high versatility by supporting popular ML frameworks like PyTorch, TensorFlow, and Scikit-learn. We demonstrate the interface's modularity and reusability through two cases: a ML trigger function for convection parameterization and a ML wildfire model. We conduct a comprehensive evaluation of memory usage and computational overhead resulting from the integration of Python codes into the Fortran ESMs. By leveraging this flexible interface, ML parameterizations can be effectively developed, tested, and integrated into ESMs.

Publisher's note: Copernicus Publications remains neutral with regard to jurisdictional claims made in the text, published maps, institutional affiliations, or any other geographical representation in this preprint. The responsibility to include appropriate place names lies with the authors.
Tao Zhang, Cyril Morcrette, Meng Zhang, Wuyin Lin, Shaocheng Xie, Ye Liu, Kwinten Van Weverberg, and Joana Rodrigues

Status: final response (author comments only)

Comment types: AC – author | RC – referee | CC – community | EC – editor | CEC – chief editor | : Report abuse
  • CEC1: 'Comment on gmd-2024-79', Juan Antonio Añel, 20 Jun 2024
    • AC1: 'Reply on CEC1', Tao Zhang, 22 Jun 2024
  • RC1: 'Comment on gmd-2024-79', Anonymous Referee #1, 05 Oct 2024
    • AC2: 'Reply on RC1', Tao Zhang, 17 Nov 2024
  • RC2: 'Comment on gmd-2024-79', Anonymous Referee #2, 14 Oct 2024
    • AC3: 'Reply on RC2', Tao Zhang, 17 Nov 2024
Tao Zhang, Cyril Morcrette, Meng Zhang, Wuyin Lin, Shaocheng Xie, Ye Liu, Kwinten Van Weverberg, and Joana Rodrigues
Tao Zhang, Cyril Morcrette, Meng Zhang, Wuyin Lin, Shaocheng Xie, Ye Liu, Kwinten Van Weverberg, and Joana Rodrigues

Viewed

Total article views: 950 (including HTML, PDF, and XML)
HTML PDF XML Total BibTeX EndNote
666 193 91 950 12 16
  • HTML: 666
  • PDF: 193
  • XML: 91
  • Total: 950
  • BibTeX: 12
  • EndNote: 16
Views and downloads (calculated since 03 Jun 2024)
Cumulative views and downloads (calculated since 03 Jun 2024)

Viewed (geographical distribution)

Total article views: 951 (including HTML, PDF, and XML) Thereof 951 with geography defined and 0 with unknown origin.
Country # Views %
  • 1
1
 
 
 
 
Latest update: 13 Dec 2024
Download
Short summary
Earth System Models (ESMs) struggle the uncertainties associated with parameterizing sub-grid physics. Machine learning (ML) algorithms offer a solution by learning the important relationships and features from high-resolution models. To incorporate ML parameterizations into ESMs, we develop a Fortran-Python interface that allows for calling Python functions within Fortran-based ESMs. Through two case studies, this interface demonstrates its feasibility, modularity and effectiveness.