Unified PostProcessor on Shaheen

Unified PostProcessor or UPP is a postprocessing tool with capability to post-process output from a variety of NWP models, including WRF-NMM, WRF-ARW, Non-hydrostatic Multi-scale Model on the B grid (NMMB), Global Forest System (GFS), and Climate Forecast System (CFS), and Finite-Volume Cubed Sphere (FV3). For more details, please refer to https://dtcenter.org/community-code/unified-post-processor-upp

Usually, Shaheen CS team maintains the software but if you wish to build your own, this guide applies.

Build Instructions

All builds need to have Position Independent Code (PIC) generated by the linker. The compiler used here is Intel/19.0.5 on CrayXC40. Both grib2 (along with dependencies) and jasper were build with Intel compiler and with flag -fPIC

WRF build with netcdf and hdf5-parallel support

The following modules were loaded in the environment and was built on cdl5 login node:

module load craype-haswell module swap PrgEnv-cray PrgEnv-intel module load cray-netcdf-hdf5parallel module load cray-hdf5-parallel module load grib2 jasper export CRAYPE_LINK_TYPE=dynamic export NETCDF=$NETCDF_DIR export HDF5=$HDF5_DIR export PHDF5=$HDF5_DIR export JASPERLIB=${JASPER_DIR}}/lib export JASPERFINC=${JASPER_DIR}/include export WRFIO_NCD_LARGE_FILE_SUPPORT=1

Run configure and choose option 51:

./configure

Some change need to be made in the resulting configure.wrf:

sed -i 's/icc/cc/g' ./configure.wrf sed -i 's;/lib/cpp -P -nostdinc;/lib/cpp -P ;g' ./configure.wrf sed -i 's/cc/cc -fPIC/g' ./configure.wrf sed -i 's/ftn/ftn -fPIC/g' ./configure.wrf

After configuration is done, we are ready to run compilation:

The above will need 20 hyperthreads to run the make in parallel. The subsequent compilation of em_real work when make runs sequentially.

UPP build

Once WRF is build, UPPV3.1 can be configured as follows:

  • The environment need to be the same in WRF

    • Make sure WRF_DIR is set to the installation path ofwrf you wish to use.

  • Choose option4 when configuring

The following changes are needed in configure.upp file:

Once set, we are now ready to compile

If installation is successful (without errors), UPP directory will end up with copygb.exe  ndate.exe and unipost.exe in UPPV3.1/bin directory.

WRF build with parallel-netcdf and WRF quilting support

The following modules were loaded in the environment and was built on cdl5 login node:

Run configure and choose option 51:

Some change need to be made in the resulting configure.wrf to enable QUILTING and generating Position Independent Code

After configuration is done, we are ready to run compilation:

The above will need 20 hyperthreads to run the make in parallel. The subsequent compilation of em_real work when make runs sequentially.

 UPP build

Once WRF is build, UPPV3.1 can be configured as follows:

  • The environment need to be the same in WRF

    • Make sure WRF_DIR is set to the installation path ofwrf you wish to use.

  • Choose option4 when configuring

The following changes are needed in configure.upp file:

Once set, we are now ready to compile

Running a parallel UPP job

The following is an example jobscript (modify paths according to your installation) is using UPP with pnetcdf support. Change environment if you are running the other version: