Running FMDA in the WRFx system
WRFx system
WRFx: Requirements and environment
Install Anaconda distribution
Download and install the Python 3 conda distribution for your platform. We recommend an installation into the users' home directory. For example,
wget https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh chmod +x Miniconda3-latest-Linux-x86_64.sh ./Miniconda3-latest-Linux-x86_64.sh
The installation may instruct you to exit and log in again.
On a shared system, you may have a system-wide Python distribution with conda already installed, perhaps as a module, try module avail.
Install necessary packages
The currently preferred process is to have conda find the versions for you:
conda create -n wrfx python=3.8 conda activate wrfx conda install -c conda-forge gdal conda install -c conda-forge netcdf4 h5py pyhdf pygrib f90nml lxml simplekml pytz pandas scipy conda install -c conda-forge basemap paramiko dill psutil flask wgrib2 pip install MesoPy python-cmr shapely==2
On Linux x86-64, you can also use versions specified in a yml file:
wget https://demo.openwfm.org/web/wrfx/wrfx.yml conda env create --name wrfx --file wrfx.yml
Note: The versions listed in the yml file may not be available on platforms other than Linux x86-64 (most common), or may just not work as package repositories evolve.
Set environment
Every time before using WRFx, make the packages available by
conda activate wrfx
WRFx: wrfxpy
WRF-SFIRE forecasting and data assimilation in python using an HPC environment.
wrfxpy: Installation
Clone github repository
Clone wrfxpy repository
git clone https://github.com/openwfm/wrfxpy
Change to the directory where the wrfxpy repository has been created
cd wrfxpy
General configuration
An etc/conf.json file must be created with the keys discussed below. A template file etc/conf.json.initial is provided as a starting point.
cd wrfxpy cp etc/conf.json.initial etc/conf.json
Configure the queuing system, system directories, WPS/WRF-SFIRE locations, and workspace locations by editing the following keys in etc/conf.json:
"sys_install_path": "/path/to/wrfxpy" "wget" : "/path/to/wget"
Note that the rest of the paths are not used by FMDA, so you can leave defaults or remove them. To find the default wget,
which wget
Tokens configuration
When running wrfxpy, sometimes the data needs to be accessed and downloaded using a specific token created for the user. For instance, in the case of running the Fuel Moisture Model, one needs a token from a valid MesoWest user to download data automatically. All of these can be specified with the creation of the file etc/tokens.json from the template etc/tokens.json.initial containing:
{
"mesowest" : "token-from-synopticdata.com"
}
So, if any of the previous capabilities are required, create a token from the specific page, do
cp etc/tokens.json.initial etc/tokens.json
and edit the file to include your previously created token.
For running the fuel moisture model, a new MesoWest user can be created in MesoWest New User. Then, the token can be acquired and replaced in the etc/tokens.json file. Also, the user can specify a list of tokens to use.