NOAA Environmental Modeling System
|This page is meant to guide you in setting up and running experiments for the different models within NEMS. If you are interested in starting out with regression tests, please refer to 'Getting Started' . Bear in mind that, currently, there is no simplified way of running the NMM-B or GFS individually. It may require changes to the regression test script (RT.sh), the ability to recognize other files involved, creation of your own run scripts, and the creation of your own compatible input files.|
Libraries & Dependencies
Currently, NEMS requires the following external libraries to be installed on the system in order to run properly.
- ESMF versions 3.1.0rp2 and 5.2.0rp1 are supported. Available from the ESMF web site.
- netcdf - available from the UNIDATA website.
- The following libraries are from NCEP and can be downloaded from the NEMS trunk (located in EMC's Subversion repository) in /trunk/util/syslib.tar:
- The following will be used only when write_dopost is set to .true. in the configure file:
- g2 - /nwprod/lib
- g2tmpl - /nwprod/util/sorc/g2tmpl.fd
- sigio, sfcio - /nwprod/lib
- unipost - /climate/save/wx20wa/esmf/nems/unipost_r14561
- png, jasper - /usrx/local/64bit/lib; jasper is the library to make jpeg2000 packing
If you are interested in just running regression tests, please refer to 'Regression Tests'. Otherwise, continue on below.
Process to checkout and build NEMS:
|Check out NEMS.||/gpfs/td1/emc/**/save/Firstname.Lastname (Tide)|
** - global, meso, etc.
|svn checkout https://svnemc.ncep.noaa.gov/projects/nems/trunk|
|Configure using the version of the ESMF library that will be used (if running RT.sh, this will be done automatically). Make note of machine specific options.||.../trunk/src||ESMF 3.1.0rp2:
./configure 3_zeus (for the ESMF 3.1.0r series library)
ESMF with reference NUOPC layer (currently ESMF 7.0.0 beta snapshot):
|Source the appropriate module file. Note the machine and ESMF version needed.||.../trunk/src||source conf/modules.nems.Gaea_ESMF_NUOPC
|Clean any previous compilations.||.../trunk/src||gmake clean|
|Compile and build the core(s) needed (/job/tests/rt.sh will build the default settings - NMM and GFS with GOCART).||.../trunk/src||NMM & GSM: gmake nmm_gsm
GEN only: gmake gen
GSM & GEN w/ GOCART & post:gmake gsm_gen_post GOCART_MODE=full
NMM & GSM w/ GOCART: gmake nmm_gsm GOCART_MODE=full
NMM only: gmake nmm
NMM with post: gmake nmm_post
GSM only: gmake gsm
GSM with post: gmake gsm_post
GSM w/ GOCART:gmake gsm GOCART_MODE=full
|In order to build NEMS with ocean components, all of the above targets support the optional OCN variable. Supported values are: \"dummy\", \"hycom\", and \"mom5\". Specifying multiple values, e.g. "gmake nmm_gsm OCN=mom5,dummy", is supported.
In order to build NEMS with sea-ice components, all of the above targets support the optional ICE variable. Supported values are: \"dummy\", \"cice\".
Specifying multiple values, e.g. \"gmake nmm_gsm OCN=mom5,dummy,hycom ICE=dummy\", is supported.
The executable, NEMS.x, will appear in /exe.
How To Run NMM-B
Using regression test script on WCOSS and Zeus (coming soon):
Using the NMM-B Launcher (coming soon):
The state of the Launcher on WCOSS is in a state of flux. For reference, please refer to the evolving draft of Launcher documentation.
How To Run NMM-B Nests
The NMM-B has telescoping static and moving nest capability. All domains, whether the uppermost parent or any nest, are functionally equivalent and thus each needs its own configure file. Both 1-way and 2-way interaction between parent and child domains are available. In addition to running nests using the regression test input and configuration (similar to the method mentioned in 'How to Run NMM-B'), one can also follow as specified below.
The following instructions are also available in the README.NMM file.
1-way nesting: [+/-]
2-way nesting: [+/-]
NMM-B output files are written in a gridded format readable by GrADS (.ctl). To understand NMM-B output, please refer to the 'Output' tab.
How to Run GFS
Currently, the scripts to run the GFS with NEMS are in flux. Follow the temporary instructions below to run, but bear in mind you must have a Subversion account to follow these directions.
GFS Parallel Scripts:
All script work is being done in the GFS branch, gfs4nems. Make sure to use "--ignore-externals" when checking out the branch, unless you want to check out all of the externals, as well. Also, if you have not been tasked to work on any of the branches mentioned in this section, please do not commit anything back to the branches.
Please note that work will continue to be committed back to this branch, so you will want to follow it with ticket #184. Any questions about the scripts can be directed to Kate Howard.
Currently, para_config_T574 in the gfs4nems branch only runs Eulerian. You will want to adjust the BASE_NEMS variable to point to your copy of NEMS and BASEDIR to point to your copy of the gfs4nems branch.
Note the new $NEMS variable near the top. When NEMS=YES, it sets DYNVARS and PHYVARS for NEMS.x and when NEMS=NO, it sets FCSTVARS for global_fcst.
para_config_T1534 will be updated to run semi-Lagrangian soon.
All model code work is being done in the GSM branch, gsm_slg. All questions about the code should be directed to Moorthi. How to build the current NEMS/GSM code:
- Check out the NEMS trunk and make sure NOT to ignore externals. You want to grab the GSM code trhough the external under /src/atmos.
- Update the GSM external under /src/atmos to point to Moorthi's branch if you want to run semi-Lagrangian. Leave the external alone if trying Eulerian first.
- Type "svn propedit svn:externals"
(Seek help if you are unsure about how to do this.)
- Type "svn update" after changing the external. That will change the contents of the GSM directory under /src/atmos to Moorthi's branch.
- Type "svn propedit svn:externals"
- To build, do the following under /src:
- Type "./configure ESMF_OPTION". (Typing just "./configure" will show options, but you will want 6.3r_gsm_wcoss for the ESMF_OPTION for now.)
- Type "source conf/modules.nems".
- Type "gmake gsm".
- You will get a NEMS.x in the /exe directory. Use that instead of global_fcst.
The global_chgres code and script within the gfs4nems GFS branch is new and working. You should build and use that copy to convert your sigio ICs to nemsio. There are a number of wrapper scripts floating around that can be used to run chgres offline. Feel free to use one you already have or try this one, /gpfs/td1/emc/global/noscrub/Kate.Howard/para_gfs/data_4_gfs4nems/run_chgres.sh.
- Attempts have been unsuccessful using global_chgres straight from sigio to nemsio with different starting and ending resolutions (i.e. T1534 sigio to T574 nemsio). You may need to first convert the original sigio file to the resolution you want (e.g. T1534 sigio to T574 sigio, OUTTYP=2, no GRDFMT) and then convert it to nemsio (e.g. T574 sigio to T574 nemsio, OUTTYP=1).
- You can NOT currently convert nemsio back to sigio. Keep that in mind!
- Attemps have also been unsuccessful in using global_chgres to change nemsio files to other resolutions. The only surefire way, so far, is to follow the steps in note #1.
- Make sure to go through the run_chgres.sh script to edit the settings to your preferences. For OUTTYP=1 (nemsio), you need GFSOUT instead of SIGOUT.
- For nemsio, the siganl file is named gfsanl. The scripts are set up to look for gfsanl if NEMSIO_IN=.true. and siganl if SIGIO_IN=.true.
- The sfcanl file does not change, but needs to be converted as well.
- Most likely, nemsio files will be used in binary format. You will notice GRDFMT='bin4' in the CHGRESVARS within the scripts.
The nemsio_get utility is used for nemsio files, just as global_sighdr is used for sigio files. You can use the following copy on Tide, /nwprod/ngac.v1.0.0/exec/nemsio_get. All questions about nemsio_get should be directed to Jun Wang.
Status of Eulerian and semi-Lagrangian:
The current NEMS trunk has been successfully used to run Eulerian sigio to nemsio forecasts (SIGIO_IN=.true. and NEMSIO_OUT=.true.) for all supported resolutions under T878. Eulerian nemsio to nemsio (NEMSIO_IN=.true. and NEMSIO_OUT=.true.) has also been successful for T574. The gsm_slg branch has just started to be used to run semi-Lagrangian T1534, with a few glitches that will hopefully be remedied soon.
In addition to isolating specific GFS regression tests in RT.sh_IN, as mentioned above, one can also use the following method to run GFS on Zeus.
As part of the 2013 NEMS/GFS Modeling Summer School, a suite of scripts and sample initial conditions was created to allow students to run the NEMS GFS. The code is located in /scratch2/portfolios/NCEPDEV/global/save/glopara/Summer_School_2013. Below is information on how to use the code:
- Move to your working directory, then use the following command to copy necessary files: 'sh /scratch2/portfolios/NCEPDEV/global/save/glopara/Summer_School_2013'.
- Compile NEMS/GFS code:
- cd Summer_School_2013/Tutorials
- sh makefile_nems.sh
- Compile log can be viewed in ../sorc/global_fcst.fd/Compile.log
- Make changes to the following corresponding to your account:
- 'export acc='
- 'export NEMSDIR='
- 'export RUNDIR='
How to Run FIM (coming soon)
Following is a procedure for defining functional equivalence on different environments:
- Select key fields from the import state Fi (may include a selection of initial cases).
- Run control run C of application on control environment.
- Perturb each Fi in the last significant digit.
- Nominally after the 6th decimal digit for 32-bit reals.
- For each value Fi(x), construct a distribution.
- Gaussian distribution with width being | Fi(x)/1.e6|.
- Randomly select perturbation from that distribution.
- Run perturbed run P from perturbed import state on control environment.
- Select key fields from the export states Cj (control run) and Pj (perturbed run) - may include a selection of output times.
- Determine area weight w(x)
- Compute the butterfly vector .
- Butterfly vector will have units of original export fields.
- Now run control run but on different environment D.
- Compute difference vector like butterfly vector but using D instead of P.
- Compute dimensionless difference butterfly number vector .
- For a bit-identical requirement, vj must be zero.
- For a functionally equivalent requirement, vj must be largely less than 10.
Update on functional equivalence
Affect on different field perturbations on RMS (NMM-B, global and regional)
RMS comparison between perturbed initial fields and different compilers - Gaea and IBM (global NMM-B case)