Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[develop]: Document process for changing number of vertical levels #888

Merged
merged 148 commits into from
Sep 6, 2023
Merged
Changes from 1 commit
Commits
Show all changes
148 commits
Select commit Hold shift + click to select a range
ff80851
update FAQ
gspetro-NOAA Jul 5, 2023
82b2e52
split up/revise Intro; reorg chapters
gspetro-NOAA Jul 5, 2023
b905241
update components section; also monor updates to intro, tech ov, glos…
gspetro-NOAA Jul 5, 2023
fd9efc8
restructure SRW docs
gspetro-NOAA Jul 6, 2023
438814f
finish restructuring, rm images
gspetro-NOAA Jul 6, 2023
a74f4d4
minor updates
gspetro-NOAA Jul 6, 2023
e778e1b
edit tables, add component info
gspetro-NOAA Jul 6, 2023
c2a772a
add info on components
gspetro-NOAA Jul 7, 2023
48e6038
rename Tech Details section
gspetro-NOAA Jul 7, 2023
57c8b08
edit build chapter
gspetro-NOAA Jul 7, 2023
d8e3c30
add cpld_gridgen def
gspetro-NOAA Jul 10, 2023
de60461
rename/reorganize/minor fixes
gspetro-NOAA Jul 10, 2023
1cfba00
minor updates
gspetro-NOAA Jul 10, 2023
593c4c6
minor updates
gspetro-NOAA Jul 10, 2023
e4ba1bc
change regional_workflow to workflow_tools
gspetro-NOAA Jul 10, 2023
e5df5c0
change regional workflow to workflow or SRW App workflow
gspetro-NOAA Jul 10, 2023
92dd46d
update info on loading wflow env for L1 v L2-4 systems
gspetro-NOAA Jul 10, 2023
0a1e7a2
move config_defaults table out of Run chapter
gspetro-NOAA Jul 10, 2023
36b2901
update run ch & tables
gspetro-NOAA Jul 12, 2023
fdf7ed2
config section updates/reorg
gspetro-NOAA Jul 12, 2023
ffc7f86
minor run updates
gspetro-NOAA Jul 12, 2023
0729d1b
plotting & VX updates
gspetro-NOAA Jul 12, 2023
9237772
minor updates
gspetro-NOAA Jul 13, 2023
1860238
add info about NCO-compliant structure
gspetro-NOAA Jul 13, 2023
b88cf59
update wflow & VX task tables
gspetro-NOAA Jul 13, 2023
db20aa9
update VX task table w/ensemble info
gspetro-NOAA Jul 17, 2023
2adb67b
add slides for Purser ESG grid
gspetro-NOAA Jul 17, 2023
552d57b
RunSRW edits
gspetro-NOAA Jul 17, 2023
8f976cf
some QS updates
gspetro-NOAA Jul 17, 2023
43fa966
First set of updates in RunSRW.rst
mkavulich Jul 19, 2023
e6fca92
More updates for PR 864
mkavulich Jul 19, 2023
07ee7a5
'GET_OBS' isn't a valid config.yaml variable
mkavulich Jul 19, 2023
27095ed
Add section links for more information
mkavulich Jul 19, 2023
f13fec5
Better description of MRMS data staging script
mkavulich Jul 19, 2023
c074431
Merge pull request #1 from mkavulich/PR_864_doc_updates
gspetro-NOAA Jul 20, 2023
5a2c266
Merge branch 'ufs-community:develop' into text/ug-updates
gspetro-NOAA Jul 20, 2023
f0656eb
minor formatting
gspetro-NOAA Jul 21, 2023
519a427
add details on AQM executables & tasks
gspetro-NOAA Jul 29, 2023
78d7c6d
minor Tutorial & QS updates
gspetro-NOAA Jul 29, 2023
2bbc3ac
update AQM section
gspetro-NOAA Aug 1, 2023
79e9dbd
formatting fixes
gspetro-NOAA Aug 1, 2023
0b9547a
minor fixes
gspetro-NOAA Aug 1, 2023
4b323de
add AQM expt data info & wflow SUCCESS info
gspetro-NOAA Aug 2, 2023
f004d1f
minor WE2E updates
gspetro-NOAA Aug 2, 2023
2fe0f99
update testing ch
gspetro-NOAA Aug 3, 2023
c52ee61
reorganize WE2E, condense
gspetro-NOAA Aug 4, 2023
911ffdc
WE2E edits
gspetro-NOAA Aug 4, 2023
d74a1d1
update Container QS
gspetro-NOAA Aug 4, 2023
6865890
update VX cases ch
gspetro-NOAA Aug 4, 2023
5f0bcf5
update Tutorial
gspetro-NOAA Aug 4, 2023
9374a3e
update 1st half of FAQ
gspetro-NOAA Aug 4, 2023
b3e1c5f
update FAQ
gspetro-NOAA Aug 7, 2023
7570503
add comma
gspetro-NOAA Aug 7, 2023
f23e441
update Rocoto ch & minor details in other chs
gspetro-NOAA Aug 7, 2023
188a149
rename Tech Deteails ch
gspetro-NOAA Aug 7, 2023
e1ef957
update index file w/new dir names
gspetro-NOAA Aug 7, 2023
7c5818d
add ufs wm intersphinx
gspetro-NOAA Aug 8, 2023
3c2c727
I/O updates
gspetro-NOAA Aug 8, 2023
9806215
update file /path/to convention
gspetro-NOAA Aug 8, 2023
995ccf2
update file /path/to convention
gspetro-NOAA Aug 8, 2023
67c17af
update I/O ch
gspetro-NOAA Aug 8, 2023
b917456
resolve merge conflict from develop
gspetro-NOAA Aug 8, 2023
351141a
add FAQ update & link update
gspetro-NOAA Aug 8, 2023
bf48e21
Defining Wflow updates
gspetro-NOAA Aug 8, 2023
c3e0ba0
Defining Wflow updates
gspetro-NOAA Aug 9, 2023
f6d0b9b
Intro updates
gspetro-NOAA Aug 9, 2023
a8335a1
Intro updates
gspetro-NOAA Aug 9, 2023
a8f0b81
minor details
gspetro-NOAA Aug 10, 2023
6d30954
fix typo
gspetro-NOAA Aug 10, 2023
49c42af
resolve merge conflicts, add AQM data info
gspetro-NOAA Aug 10, 2023
d41c56f
add initial vertical level/layer section info
gspetro-NOAA Aug 10, 2023
0ea850a
revert changes to align w/v2.1.0 stable code
gspetro-NOAA Aug 10, 2023
ab6d093
add prdgen def
gspetro-NOAA Aug 11, 2023
1732415
minor edits
gspetro-NOAA Aug 11, 2023
df63c9d
1st draft vertical coordinates
gspetro-NOAA Aug 11, 2023
01ad8a3
Merge branch 'text/ug-updates' into text/grid
gspetro-NOAA Aug 11, 2023
d48deb3
fix #levels
gspetro-NOAA Aug 11, 2023
390da60
add more ak/bk gen info
gspetro-NOAA Aug 14, 2023
7f07032
minor updates
gspetro-NOAA Aug 14, 2023
fb7be06
minor fixes
gspetro-NOAA Aug 14, 2023
80b265e
minor updates
gspetro-NOAA Aug 14, 2023
95f7179
rm mention of any required file structure for *_OBS_DIR paths
gspetro-NOAA Aug 14, 2023
e16cdae
update to 5 supported physics suites
gspetro-NOAA Aug 15, 2023
e7efb8f
fix off-by-one error
gspetro-NOAA Aug 15, 2023
801465c
minor edits
gspetro-NOAA Aug 15, 2023
a686045
rm mentions of GSI/rrfs-utl
gspetro-NOAA Aug 15, 2023
ed4faf6
rework instructions to use pre-built vcoord_gen executable
gspetro-NOAA Aug 15, 2023
1f485d6
Merge branch 'ufs-community:develop' into text/grid
gspetro-NOAA Aug 16, 2023
ef77903
Merge branch 'ufs-community:develop' into text/ug-updates
gspetro-NOAA Aug 16, 2023
36b338f
Updates to WE2E tests
mkavulich Aug 16, 2023
7df67d5
Update WE2E testing doc umentation
mkavulich Aug 16, 2023
9aaafc4
fix typos/formatting
gspetro-NOAA Aug 16, 2023
51d7350
update # of CCPP suites
gspetro-NOAA Aug 16, 2023
6b11b2b
update table of comm config vals
gspetro-NOAA Aug 17, 2023
3084869
Add task_get_obs_nohrsc to VX tasks table
gspetro-NOAA Aug 17, 2023
b7c917b
Fix VX task name: metatask_PcpCombine_fcst_APCP_all_accums_all_mems
gspetro-NOAA Aug 17, 2023
8684019
Add VX task to table: metatask_PcpCombine_fcst_ASNOW_all_accums_all_mems
gspetro-NOAA Aug 17, 2023
fd0f849
Add VX task to table: metatask_GenEnsProd_EnsembleStat_NOHRSC
gspetro-NOAA Aug 17, 2023
389ab11
Fix VX task table: metatask_GridStat_NOHRSC_ensmeanprob_all_accums
gspetro-NOAA Aug 17, 2023
e2138b3
rm GSI from Glossary
gspetro-NOAA Aug 17, 2023
dcbd4c2
Merge branch 'text/ug-updates' of github.com:gspetro-NOAA/ufs-srweath…
gspetro-NOAA Aug 17, 2023
15eb7ae
fix typo
gspetro-NOAA Aug 17, 2023
c18f2b5
minor edits
gspetro-NOAA Aug 17, 2023
f4b7be8
Merge branch 'text/ug-updates' of github.com:gspetro-NOAA/ufs-srweath…
gspetro-NOAA Aug 17, 2023
7296127
Merge branch 'ufs-community:develop' into text/ug-updates
gspetro-NOAA Aug 21, 2023
c178e8f
Merge branch 'ufs-community:develop' into text/grid
gspetro-NOAA Aug 23, 2023
c1d250c
update to head of develop
gspetro-NOAA Aug 25, 2023
406693a
Merge branch 'text/ug-updates' of github.com:gspetro-NOAA/ufs-srweath…
gspetro-NOAA Aug 25, 2023
a242b3b
Update RRFS mention in Intro
gspetro-NOAA Aug 25, 2023
6403974
minor cholt edits
gspetro-NOAA Aug 25, 2023
a24e663
update I/O NOMADS mention to S3 bucket
gspetro-NOAA Aug 25, 2023
40c794b
remove stray Run ch from PR 883 & fix table formatting
gspetro-NOAA Aug 25, 2023
79ef602
Update 18h to 18 UTC
gspetro-NOAA Aug 25, 2023
82202e1
rm stray RRFS/gsi mentions
gspetro-NOAA Aug 25, 2023
9f1aa91
Merge branch 'text/ug-updates' of github.com:gspetro-NOAA/ufs-srweath…
gspetro-NOAA Aug 25, 2023
0eba803
expand list of supported components
gspetro-NOAA Aug 25, 2023
5a8eb8d
update notes in Container ch
gspetro-NOAA Aug 25, 2023
1c8c3b9
QS and container QS updates
gspetro-NOAA Aug 25, 2023
0d0257d
rm package list; add uwtools env instructions
gspetro-NOAA Aug 25, 2023
31cc9ef
clarify re EXPTDIR
gspetro-NOAA Aug 28, 2023
629186b
rm confusing csh ref
gspetro-NOAA Aug 28, 2023
4713c3e
clarify bash/csh env commands
gspetro-NOAA Aug 28, 2023
9837c97
minor fixes
gspetro-NOAA Aug 29, 2023
1a84595
Update RunSRW to rm $PWD in config_utils cmd
gspetro-NOAA Aug 29, 2023
e606bda
Update Intro QS Description
gspetro-NOAA Aug 29, 2023
109b88c
Update CQS crosslink
gspetro-NOAA Aug 29, 2023
a6fb29d
Update instructions on providing error msg
gspetro-NOAA Aug 29, 2023
92aea33
update software prereqs
gspetro-NOAA Aug 29, 2023
edb8531
update ESMF SCRIP abbrev
gspetro-NOAA Aug 29, 2023
d0c8ee1
link to j-jobs in glossary
gspetro-NOAA Aug 29, 2023
0d95dcc
update instructions on filing GitHub issues
gspetro-NOAA Aug 29, 2023
705ea15
Update Intro info on QS
gspetro-NOAA Aug 29, 2023
3823a3c
rm redundant umbrella repo def
gspetro-NOAA Aug 29, 2023
d8c8407
Merge branch 'text/ug-updates' of github.com:gspetro-NOAA/ufs-srweath…
gspetro-NOAA Aug 29, 2023
1201e24
Update intro w/user support recs
gspetro-NOAA Aug 29, 2023
09e10ca
rm note re container binding on Jet
gspetro-NOAA Aug 29, 2023
62e54eb
Merge branch 'text/ug-updates' of github.com:gspetro-NOAA/ufs-srweath…
gspetro-NOAA Aug 29, 2023
4261f08
Update container docs w/Apptainer info
gspetro-NOAA Aug 29, 2023
6e55e60
fix j-job xref
gspetro-NOAA Aug 29, 2023
a4ca1d0
fix link
gspetro-NOAA Aug 29, 2023
61515b8
Change name of Ch 3 to 'Customizing the Workflow'
gspetro-NOAA Aug 30, 2023
5b045a0
Update CQS ch w/Gaea c5 info
gspetro-NOAA Aug 30, 2023
653fe01
rename to Customizing the Workflow
gspetro-NOAA Aug 30, 2023
4f6ae16
update link to ccpp sci docs
gspetro-NOAA Aug 30, 2023
ad35c2a
resolve conflicts
gspetro-NOAA Aug 30, 2023
30ab75a
Merge branch 'text/grid' of github.com:gspetro-NOAA/ufs-srweather-app…
gspetro-NOAA Aug 30, 2023
7c62989
Merge branch 'develop' into text/grid
gspetro-NOAA Aug 30, 2023
78204be
Jeff's updates
gspetro-NOAA Sep 1, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
config section updates/reorg
  • Loading branch information
gspetro-NOAA committed Jul 12, 2023
commit fdf7ed2092550ef43fcbd2be803d36bf53ecd40e
220 changes: 113 additions & 107 deletions docs/UsersGuide/source/BuildingRunningTesting/RunSRW.rst
Original file line number Diff line number Diff line change
Expand Up @@ -313,7 +313,12 @@ The user must set the specifics of their experiment configuration in a ``config.
+--------------------------------+-------------------+------------------------------------+
| NUM_ENS_MEMBERS | 1 | 2 |
+--------------------------------+-------------------+------------------------------------+


.. _GeneralConfig:

General Instructions for All Systems
```````````````````````````````````````

To get started with a basic forecast in *community* mode, make a copy of ``config.community.yaml``. From the ``ufs-srweather-app`` directory, run:

.. code-block:: console
Expand All @@ -323,20 +328,7 @@ To get started with a basic forecast in *community* mode, make a copy of ``confi

The default settings in this file include a predefined 25-km :term:`CONUS` grid (RRFS_CONUS_25km), the :term:`GFS` v16 physics suite (FV3_GFS_v16 :term:`CCPP`), and :term:`FV3`-based GFS raw external model data for initialization.

Next, users should edit the new ``config.yaml`` file to customize it for their machine. At a minimum, users will usually need to change the ``MACHINE`` and ``ACCOUNT`` variables. Then, select a name for the experiment directory by renaming ``EXPT_SUBDIR`` from ``test_community`` to a name describing the experiment (e.g., ``basic_wflow_test``). If users have pre-staged initialization data for the experiment, they can set ``USE_USER_STAGED_EXTRN_FILES: true`` and set the paths to the data for ``EXTRN_MDL_SOURCE_BASEDIR_ICS`` and ``EXTRN_MDL_SOURCE_BASEDIR_LBCS``. If the modulefile used to set up the build environment in :numref:`Section %s <BuildExecutables>` uses a GNU compiler, check that the line ``COMPILER: "gnu"`` appears in the ``workflow:`` section of the ``config.yaml`` file. On platforms where Rocoto and :term:`cron` are available, users can automate resubmission of their experiment workflow by adding the following lines to the ``workflow:`` section of the ``config.yaml`` file:

.. code-block:: console

USE_CRON_TO_RELAUNCH: true
CRON_RELAUNCH_INTVL_MNTS: 3

.. note::

Generic Linux and MacOS users should refer to :numref:`Section %s <LinuxMacEnvConfig>` for additional details on configuring an experiment and python environment.

Detailed information on additional parameter options can be viewed in :numref:`Section %s: Configuring the Workflow <ConfigWorkflow>`. Additionally, information about the four predefined Limited Area Model (LAM) Grid options can be found in :numref:`Section %s: Limited Area Model (LAM) Grids <LAMGrids>`.

On Level 1 systems, the following fields typically need to be updated or added to the appropriate section of the ``config.yaml`` file in order to run the out-of-the-box SRW App case:
Next, users should edit the new ``config.yaml`` file to customize it for their machine. On most systems, the following fields need to be updated or added to the appropriate section of the ``config.yaml`` file in order to run the out-of-the-box SRW App case:

.. code-block:: console

Expand Down Expand Up @@ -366,11 +358,20 @@ where:
* ``<data_type>`` refers to one of 3 possible data formats: ``grib2``, ``nemsio``, or ``netcdf``.
* ``<YYYYMMDDHH>`` refers to a subdirectory containing data for the :term:`cycle` date (in YYYYMMDDHH format).

On platforms where Rocoto and :term:`cron` are available, users can automate resubmission of their experiment workflow by adding the following lines to the ``workflow:`` section of the ``config.yaml`` file:

.. code-block:: console

USE_CRON_TO_RELAUNCH: true
CRON_RELAUNCH_INTVL_MNTS: 3

When running with GNU compilers (i.e., if the modulefile used to set up the build environment in :numref:`Section %s <BuildExecutables>` uses a GNU compiler), users must also set ``COMPILER: "gnu"`` in the ``workflow:`` section of the ``config.yaml`` file.

.. note::

On ``JET``, users should also add ``PARTITION_DEFAULT: xjet`` and ``PARTITION_FCST: xjet`` to the ``platform:`` section of the ``config.yaml`` file.

For example, to run the out-of-the-box experiment on Gaea, add or modify variables in the ``user``, ``workflow``, ``task_get_extrn_ics``, and ``task_get_extrn_lbcs`` sections of ``config.yaml`` (unmodified variables are not shown in this example):
For example, to run the out-of-the-box experiment on Gaea using cron to automate job submission, users should add or modify variables in the ``user``, ``workflow``, ``task_get_extrn_ics``, and ``task_get_extrn_lbcs`` sections of ``config.yaml`` (unmodified variables are not shown in this example):

.. code-block::

Expand All @@ -379,14 +380,16 @@ For example, to run the out-of-the-box experiment on Gaea, add or modify variabl
ACCOUNT: hfv3gfs
workflow:
EXPT_SUBDIR: run_basic_srw
USE_CRON_TO_RELAUNCH: true
CRON_RELAUNCH_INTVL_MNTS: 3
task_get_extrn_ics:
USE_USER_STAGED_EXTRN_FILES: true
EXTRN_MDL_SOURCE_BASEDIR_ICS: /lustre/f2/dev/role.epic/contrib/UFS_SRW_data/develop/input_model_data/FV3GFS/grib2/2019061518
EXTRN_MDL_DATA_STORES: disk
task_get_extrn_lbcs:
USE_USER_STAGED_EXTRN_FILES: true
EXTRN_MDL_SOURCE_BASEDIR_LBCS: /lustre/f2/dev/role.epic/contrib/UFS_SRW_data/develop/input_model_data/FV3GFS/grib2/2019061518
EXTRN_MDL_DATA_STORES: disk

Detailed information on these and other parameter options can be viewed in :numref:`Section %s: Configuring the Workflow <ConfigWorkflow>`. Additionally, information about the four predefined Limited Area Model (LAM) Grid options can be found in :numref:`Section %s: Limited Area Model (LAM) Grids <LAMGrids>`.

.. COMMENT: Delete?
To determine whether the ``config.yaml`` file adjustments are valid, users can run the following script from the ``ush`` directory:
Expand All @@ -406,97 +409,26 @@ For example, to run the out-of-the-box experiment on Gaea, add or modify variabl

The ``workflow_tools`` environment must be loaded for the ``config_utils.py`` script to validate the ``config.yaml`` file.

Valid values for configuration variables should be consistent with those in the ``ush/valid_param_vals.yaml`` script. In addition, various sample configuration files can be found within the subdirectories of ``tests/WE2E/test_configs``.

To configure an experiment and python environment for a general Linux or Mac system, see the :ref:`next section <LinuxMacEnvConfig>`. To configure an experiment to run METplus verification tasks, see :numref:`Section %s <VXConfig>`. Otherwise, skip to :numref:`Section %s <GenerateWorkflow>` to generate the workflow.

.. _PlotOutput:

Plotting Configuration (optional)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

An optional Python plotting task (PLOT_ALLVARS) can be activated in the workflow to generate plots for the :term:`FV3`-:term:`LAM` post-processed :term:`GRIB2`
output over the :term:`CONUS`. It generates graphics plots for a number of variables, including:

* 2-m temperature
* 2-m dew point temperature
* 10-m winds
* 250 hPa winds
* Accumulated precipitation
* Composite reflectivity
* Surface-based :term:`CAPE`/:term:`CIN`
* Max/Min 2-5 km updraft helicity
* Sea level pressure (SLP)

.. COMMENT: * 500 hPa heights, winds, and vorticity --> seems to be omitted? Why?

This workflow task can produce both plots from a single experiment and difference plots that compare the same cycle from two experiments. When plotting the difference, the two experiments must be on the same domain and available for
the same cycle starting date/time and forecast hours. Other parameters may differ (e.g., the experiments may use different physics suites).

.. _Cartopy:

Cartopy Shapefiles
`````````````````````

The Python plotting tasks require a path to the directory where the Cartopy Natural Earth shapefiles are located. The medium scale (1:50m) cultural and physical shapefiles are used to create coastlines and other geopolitical borders on the map. On `Level 1 <https://github.com/ufs-community/ufs-srweather-app/wiki/Supported-Platforms-and-Compilers>`__ systems, this path is already set in the system's machine file using the variable ``FIXshp``. Users on other systems will need to download the shapefiles and update the path of ``$FIXshp`` in the machine file they are using (e.g., ``$SRW/ush/machine/macos.yaml`` for a generic MacOS system, where ``$SRW`` is the path to the ``ufs-srweather-app`` directory). The subset of shapefiles required for the plotting task can be obtained from the `SRW Data Bucket <https://noaa-ufs-srw-pds.s3.amazonaws.com/NaturalEarth/NaturalEarth.tgz>`__. The full set of medium-scale (1:50m) Cartopy shapefiles can be downloaded `here <https://www.naturalearthdata.com/downloads/>`__.

Task Configuration
`````````````````````

Users will need to add or modify certain variables in ``config.yaml`` to run the plotting task(s). At a minimum, to activate the ``plot_allvars`` tasks, users must add it to the default list of ``taskgroups`` under the ``rocoto: tasks:`` section.

.. code-block:: console

rocoto:
tasks:
taskgroups: '{{ ["parm/wflow/prep.yaml", "parm/wflow/coldstart.yaml", "parm/wflow/post.yaml", "parm/wflow/plot.yaml"]|include }}'

Users may also wish to adjust the start, end, and increment value for the plotting task. For example:

.. code-block:: console

task_plot_allvars:
PLOT_FCST_START: 0
PLOT_FCST_INC: 6
PLOT_FCST_END: 12

If the user chooses not to set these values, the default values will be used (see :numref:`Section %s <PlotVars>`).

.. note::
If a forecast starts at 18h, this is considered the 0th forecast hour, so "starting forecast hour" should be 0, not 18.

When plotting output from a single experiment, no further adjustments are necessary. The output files (in ``.png`` format) will be located in the experiment directory under the ``$CDATE/postprd`` subdirectory where ``$CDATE``
corresponds to the cycle date and hour in YYYYMMDDHH format (e.g., ``2019061518``).

Plotting the Difference Between Two Experiments
""""""""""""""""""""""""""""""""""""""""""""""""""

When plotting the difference between two experiments (``expt1`` and ``expt2``), users must set the ``COMOUT_REF`` template variable in ``expt2``'s ``config.yaml`` file to point at forecast output from the ``expt1`` directory. For example, in *community* mode, users can set ``COMOUT_REF`` as follows in the ``expt2`` configuration file:

.. code-block:: console

task_plot_allvars:
COMOUT_REF: '${EXPT_BASEDIR}/expt1/${PDY}${cyc}/postprd'

This will ensure that ``expt2`` can produce a difference plot comparing ``expt1`` and ``expt2``. In *community* mode, using default directory names and settings, ``$COMOUT_REF`` will resemble ``/path/to/expt_dirs/test_community/2019061518/postprd``. Additional details on the plotting variables are provided in :numref:`Section %s <PlotVars>`.

The output files (in ``.png`` format) will be located in the ``postprd`` directory for the experiment.
.. note::

.. _LinuxMacEnvConfig:
Valid values for configuration variables should be consistent with those in the ``ush/valid_param_vals.yaml`` script. In addition, various sample configuration files can be found within the subdirectories of ``tests/WE2E/test_configs``.

User-Specific Configuration on a Generic Linux/MacOS System
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
**Next Steps:**

The configuration process for Linux and MacOS systems is similar to the process for other systems, but it requires a few extra steps.
* To configure an experiment for a general Linux or Mac system, see the :ref:`next section <LinuxMacEnvConfig>` for additional required steps.
* To add the graphics plotting tasks to the experiment workflow, go to section :numref:`Section %s: Plotting Configuration <PlotOutput>`.
* To configure an experiment to run METplus verification tasks, see :numref:`Section %s <VXConfig>`.
* Otherwise, skip to :numref:`Section %s <GenerateWorkflow>` to generate the workflow.

.. note::
Examples in this subsection presume that the user is running in the Terminal with a bash shell environment. If this is not the case, users will need to adjust the commands to fit their command line application and shell environment.

.. _LinuxMacExptConfig:

Configuring an Experiment on General Linux and MacOS Systems
``````````````````````````````````````````````````````````````

.. note::
Examples in this subsection presume that the user is running in the Terminal with a bash shell environment. If this is not the case, users will need to adjust the commands to fit their command line application and shell environment.

**Optional: Install Rocoto**

.. note::
Expand All @@ -505,14 +437,7 @@ Configuring an Experiment on General Linux and MacOS Systems

**Configure the SRW App:**

Configure an experiment using a template. Copy the contents of ``config.community.yaml`` into ``config.yaml``:

.. code-block:: console

cd /path/to/ufs-srweather-app/ush
cp config.community.yaml config.yaml

In the ``config.yaml`` file, set ``MACHINE: macos`` or ``MACHINE: linux``, and modify the account and experiment info. For example:
After following the steps in :numref:`Section %s: General Configuration <GeneralConfig>` above, users should have a ``config.yaml`` file that looks similar to this:

.. code-block:: console

Expand All @@ -537,6 +462,8 @@ In the ``config.yaml`` file, set ``MACHINE: macos`` or ``MACHINE: linux``, and m
PREDEF_GRID_NAME: RRFS_CONUS_25km
QUILTING: true

.. COMMENT: Edit above!

Due to the limited number of processors on MacOS systems, users must also configure the domain decomposition parameters directly in the section of the ``predef_grid_params.yaml`` file pertaining to the grid they want to use. Domain decomposition needs to take into account the number of available CPUs and configure the variables ``LAYOUT_X``, ``LAYOUT_Y``, and ``WRTCMP_write_tasks_per_group`` accordingly.

The example below is for systems with 8 CPUs:
Expand Down Expand Up @@ -610,6 +537,85 @@ The ``data:`` section of the machine file can point to various data sources that

This can be helpful when conducting multiple experiments with different types of data.

**Next Steps:**

* To add the graphics plotting tasks to the experiment workflow, go to section :numref:`Section %s: Plotting Configuration <PlotOutput>`.
* To configure an experiment to run METplus verification tasks, see :numref:`Section %s <VXConfig>`.
* Otherwise, skip to :numref:`Section %s <GenerateWorkflow>` to generate the workflow.


.. _PlotOutput:

Plotting Configuration (optional)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

An optional Python plotting task (PLOT_ALLVARS) can be activated in the workflow to generate plots for the :term:`FV3`-:term:`LAM` post-processed :term:`GRIB2`
output over the :term:`CONUS`. It generates graphics plots for a number of variables, including:

* 2-m temperature
* 2-m dew point temperature
* 10-m winds
* 250 hPa winds
* Accumulated precipitation
* Composite reflectivity
* Surface-based :term:`CAPE`/:term:`CIN`
* Max/Min 2-5 km updraft helicity
* Sea level pressure (SLP)

.. COMMENT: * 500 hPa heights, winds, and vorticity --> seems to be omitted? Why?

This workflow task can produce both plots from a single experiment and difference plots that compare the same cycle from two experiments. When plotting the difference, the two experiments must be on the same domain and available for
the same cycle starting date/time and forecast hours. Other parameters may differ (e.g., the experiments may use different physics suites).

.. _Cartopy:

Cartopy Shapefiles
`````````````````````

The Python plotting tasks require a path to the directory where the Cartopy Natural Earth shapefiles are located. The medium scale (1:50m) cultural and physical shapefiles are used to create coastlines and other geopolitical borders on the map. On `Level 1 <https://github.com/ufs-community/ufs-srweather-app/wiki/Supported-Platforms-and-Compilers>`__ systems, this path is already set in the system's machine file using the variable ``FIXshp``. Users on other systems will need to download the shapefiles and update the path of ``$FIXshp`` in the machine file they are using (e.g., ``$SRW/ush/machine/macos.yaml`` for a generic MacOS system, where ``$SRW`` is the path to the ``ufs-srweather-app`` directory). The subset of shapefiles required for the plotting task can be obtained from the `SRW Data Bucket <https://noaa-ufs-srw-pds.s3.amazonaws.com/NaturalEarth/NaturalEarth.tgz>`__. The full set of medium-scale (1:50m) Cartopy shapefiles can be downloaded `here <https://www.naturalearthdata.com/downloads/>`__.

Task Configuration
`````````````````````

Users will need to add or modify certain variables in ``config.yaml`` to run the plotting task(s). At a minimum, to activate the ``plot_allvars`` tasks, users must add it to the default list of ``taskgroups`` under the ``rocoto: tasks:`` section.

.. code-block:: console

rocoto:
tasks:
taskgroups: '{{ ["parm/wflow/prep.yaml", "parm/wflow/coldstart.yaml", "parm/wflow/post.yaml", "parm/wflow/plot.yaml"]|include }}'

Users may also wish to adjust the start, end, and increment value for the plotting task. For example:

.. code-block:: console

task_plot_allvars:
PLOT_FCST_START: 0
PLOT_FCST_INC: 6
PLOT_FCST_END: 12

If the user chooses not to set these values, the default values will be used (see :numref:`Section %s <PlotVars>`).

.. note::
If a forecast starts at 18h, this is considered the 0th forecast hour, so "starting forecast hour" should be 0, not 18.

When plotting output from a single experiment, no further adjustments are necessary. The output files (in ``.png`` format) will be located in the experiment directory under the ``$CDATE/postprd`` subdirectory where ``$CDATE``
corresponds to the cycle date and hour in YYYYMMDDHH format (e.g., ``2019061518``).

Plotting the Difference Between Two Experiments
""""""""""""""""""""""""""""""""""""""""""""""""""

When plotting the difference between two experiments (``expt1`` and ``expt2``), users must set the ``COMOUT_REF`` template variable in ``expt2``'s ``config.yaml`` file to point at forecast output from the ``expt1`` directory. For example, in *community* mode, users can set ``COMOUT_REF`` as follows in the ``expt2`` configuration file:

.. code-block:: console

task_plot_allvars:
COMOUT_REF: '${EXPT_BASEDIR}/expt1/${PDY}${cyc}/postprd'

This will ensure that ``expt2`` can produce a difference plot comparing ``expt1`` and ``expt2``. In *community* mode, using default directory names and settings, ``$COMOUT_REF`` will resemble ``/path/to/expt_dirs/test_community/2019061518/postprd``. Additional details on the plotting variables are provided in :numref:`Section %s <PlotVars>`.

The output files (in ``.png`` format) will be located in the ``postprd`` directory for the experiment.

.. _VXConfig:

Configure METplus Verification Suite (Optional)
Expand Down