Skip to content

TRACCS-COMPACT/hybrid_physics_AI_awesome_list

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

42 Commits
 
 
 
 
 
 

Repository files navigation

Awesome list of software solutions for hybrid ESMs

List of sofware solutions for interfacing physics based simulation codes with machine learning models for high performance computing in the context of Earth System Models (ESMs).

All listed names have corresponding LaTeX reference for citation in bibtex file. Ex: \cite{neural-fortran}

Follow contriburing instructions to complete the list with any item that appears relevant to you.

DOI

1. Neural Network in Fortran

  • neural-fortran : Fortran library that allows the creation of NN layers of arbitrary size and structure with several activation functions and stochastic gradient descent, uses Fortran 2018.
  • inference-engine : or Fiats, as neural-fortran but leverage advanced Fortran 2023 features.
  • Fortran-Keras-Bridge : converts models built and trained in Keras (TensorFlow) to ones usable in Fortran, also provides a Fortran module to load and use converted models.
  • FNN : a Fortran module to implement simple, sequential neural networks. Can also convert Keras models to FNN-usable model.
  • module_neural_net : Single Fortran module for fully connected neural network inference with input/output scaling and optimized matrix multiplications and activations. Depends on BLAS/MKL and NetCDF. Part of NCAR PUMAS (used in CAM).

2. Python scripts from Fortran using Python bindings

  • forpy : not to be confused with fortpy !! Fortran module to wrap and manipulate Python objects (list, dict, numpy arrays...). Allows to import and use Python packages or user-defined Python functions. Requires to convert Fortran variables into Python variables by hand.
  • call_py_fort : Fortran module to call Python functions written in a third Python script. Uses numpy to convert Fortran arrays passed as arguments.

3. Leverage C/C++ bindings of ML libraries

  • infero : Machine learning support library that runs pre-trained machine learning models for inference. Provides a common interface to multiple inference engines (TensorFlow LITE, TensorFlow C-API, ONNX-Runtime, TensorRT) and can be called from C/C++, Fortran or Python.
  • FTorch : Fortran wrapper for calling PyTorch models for inference. Runs on CPU and Nvidia, Intel, AMD, and Apple GPUs.
  • pytorch-fortran : Fortran bindings to PyTorch for inference and training. Passes Fortran arrays/tensors and runs on CPU or GPU. Requires converting PyTorch models to TorchScript, which may be depreciated.
  • Fortran-TF-lib : Fortran wrapper for calling TensorFlow / Keras models for inference.
  • TorchClim : Fortran wrapper for calling PyTorch models. Also provides an additional layer to ease wrapping in the Community Earth System Model (CESM) framework.
  • TorchFort : Fortran/C/C++ wrapper for calling PyTorch models for training and inference. Also wraps the use of NVIDIA GPUs.

4. Leverage high-level couplers Fortran and Python APIs

  • smartsim : Workflow library in which Fortran/C/Python clients can send data to a remote server that executes ML models and scripts on GPUs or CPUs.
  • XIOS : I/O dataflow library in which simulation codes clients can send or receive data to a remote server that performs online operation (writing, reading, coupling, post-processing...), including user-defined Python procedures (under development).
  • PhyDLL : Coupling library with Fortran/C/Python APIs. Allows coupled scripts (heterogeneously written or not) to exchange data. Built on CWIPI.
  • Eophis : Python wrapper to ease the deployment and configuration of OASIS Python API. OASIS works similarly as PhyDLL and is built on MCT.
  • Arnold2024 : Study in which the Python and Fortran interfaces of the YAC coupler are used for hybrid modeling.
  • ZhangT2025, Wang2022, Zhong2023 : Miscellaneous articles with in-house developed coupling interface.

5. Build Python wrappers of ESMs

  • fv3gfs-wrapper : Python wrapper for the FV3GFS global climate model. The wrapper provides interfaces to advance the Fortran main loop and get/set variables used by the Fortran model to/from the Python environment.

Related efforts on GitHub

About

No description, website, or topics provided.

Resources

Contributing

Stars

Watchers

Forks

Packages

 
 
 

Contributors

Languages