WRF-infra¶
Why WRF-infra?¶
Running meaningful WRF or WRF-Chem simulations is not trivial. It involves many steps beyond just running the model. Running simulations that can be reproduced at a later time is even more challenging.
WRF-infra is a set of tools that aim to make the development and use of WRF and its derivatives:
- easier
- more transparent
- more reproducible
WRF-infra facilitates many steps of the modelling process:
- compiling WRF, WPS, and the WRF-Chem pre-processing tools
- fetching input data from reliable sources
- pre-processing said input data
- running WPS
- running the WRF and WRF-Chem models
- testing new WRF and WRF-Chem developments
Getting WRF-infra¶
Getting WRF-infra is just a matter of cloning the entire repository:
Setting up WRF-infra¶
Basic WRF-infra functionality only requires Python 3.
Additional WRF-infra functionality (eg. some WRF pre-processors) may require additional dependencies. These are listed in pyproject.toml.
We recommend using mamba or micromamba to install these dependencies from conda-forge.
Support for multiple machines¶
WRF-infra currently supports the following machines:
- Dahu
- Jean Zay
- Jed
- Spirit
A little bit of work is needed to use WRF and WRF-Chem on a new machine (eg. a new supercomputer).
WRF and WRF-Chem rely on external libraries such as NetCDF and flex. The availability and locations of such libraries may vary from one machine to the next. Additionally, you may want to use a scheduler such as slurm to compile and run WRF. Each machine may use a different scheduler. All these things must be sorted out before using WRF and WRF-Chem.
For simplicity, WRF-infra gathers up all the information needed for each machine it supports in so-called "environment files". There is one and only one environment file for each machine. This file defines both the compile-time and the run-time configuration for WRF and WRF-Chem. All environment files are located in the env directory of WRF-infra. The complete documentation for the syntax accepted by these files is here.
To add support for a new machine to WRF-infra, you "just" need to:
- Create the environment file for this machine in the
envdirectory. - Edit the file env/hosts to add the mapping between the machine's hostname and the file you just created.