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

Feature 413 surrogate severe calculation round 2 #450

Merged
merged 29 commits into from
May 15, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
a1c8732
Added surrogate_severe_Ens_fcstHRRR_lrb.conf which has step 4 (Regrid…
Apr 15, 2020
9de24c6
Updated surrogate_severe_Ens_fcstHRRR.conf to run all 4 steps for sur…
Apr 20, 2020
c3ebbd5
Combined surrogate_severe_Ens_fcstHRRR.conf and surrogate_severe_Ens_…
Apr 21, 2020
a89330e
Rename surrogate_severe_Ens_fcstHRRR.conf to PcpComb_EnsStat_Regrid_f…
CPKalb Apr 25, 2020
6f0eecb
Update and rename PcpComb_EnsStat_Regrid_fcstHRRR_fcstonly.conf to Pc…
CPKalb Apr 25, 2020
cd50db4
Rename surrogate_severe_fcstHRRR.conf to GridStat_fcstHRRR_obsPP_Surr…
CPKalb Apr 29, 2020
3832202
Rename surrogate_severe_pp_prob.conf to GridSta_fcstHrrr_obspp_Surrog…
CPKalb Apr 29, 2020
4f71a27
Delete GridStat_fcstHRRR_obsPP_SurrogateSevere.conf
CPKalb Apr 29, 2020
ebabf60
Rename surrogate_severe_pp_categorical.conf to GridStat_fcstHRRR_obsP…
CPKalb Apr 29, 2020
a7e220b
Rename GridSta_fcstHrrr_obspp_SurrogateSevereProb.conf to GridSta_fcs…
CPKalb Apr 29, 2020
74e2131
rename files, removed PARM_BASE from conf files, changed output dir t…
Apr 29, 2020
ef06f46
merged develop into branch
Apr 29, 2020
b627f28
merged from develop again and fixed conflicts
Apr 29, 2020
e8c1cbf
Update EnsembleStat_fcstHRRR_fcstOnly_SurrogateSevere.conf
CPKalb Apr 29, 2020
63adcab
Delete surrogate_severe_fcstHRRR.conf
CPKalb Apr 29, 2020
b2d7c2e
Rename surrogate_severe_pp_categorical.conf to cGridStat_fcstHRRR_obs…
CPKalb Apr 29, 2020
f673a66
Rename cGridStat_fcstHRRR_obsPP_SurrogateSevereCategorical.conf to Gr…
CPKalb Apr 29, 2020
8ac7252
Update GridStat_fcstHRRR_obsPP_SurrogateSevereCategorical.conf
CPKalb Apr 29, 2020
f2143a7
Update GridStat_fcstHRRR_obsPP_SurrogateSevereCategorical.conf
CPKalb Apr 29, 2020
bcb90bc
Update EnsembleStat_fcstHRRR_fcstOnly_SurrogateSevere.conf
CPKalb Apr 29, 2020
0c9d8ff
Updated surrogate severe calculation .conf file
Apr 29, 2020
7662199
Delete GridStat_fcstHRRR_obsPP_SurrogateSevereCategorical.conf
CPKalb Apr 30, 2020
73aa44d
Delete GridStatConfig_ss
CPKalb Apr 30, 2020
95d0abf
Delete GridStatConfig_ss_prob
CPKalb Apr 30, 2020
f6c62e7
Delete GridStat_fcstHRRR_obsPP_SurrogateSevereProb.conf
CPKalb Apr 30, 2020
525f645
Update EnsembleStat_fcstHRRR_fcstOnly_SurrogateSevere.conf
CPKalb Apr 30, 2020
ff709ba
Updated EnsembleStat_fcstHRRR_fcstOnly_SurrogateSevere.conf to addres…
Apr 30, 2020
fabe6cd
Documentation for surrogate severe calculation use case.
May 5, 2020
995e0b1
moved use case documentation file to docs
georgemccabe May 15, 2020
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
Original file line number Diff line number Diff line change
@@ -0,0 +1,116 @@
"""
Surrogate Severe Calculation: PCPCombine, EnsembleStat, and RegridDataPlane
===================================================================================================
EnsembleStat_fcstHRRR_fcstOnly_SurrogateSevere.conf

"""
###################################################################################################
# Scientific Objective
# --------------------
#
# Run PCPCombine, EnsembleStat, and RegridDataPlane tools to create surrogate severe probability
# forecasts (SSPFs) for a given date. SSPFs are a severe weather forecasting tool and is a techniqu
# used by the Storm Prediction Center (SPC) as well as others. SSPFs are based on updraft helicity
# (UH; UH = ∫z0 to zt (ω * ζ) dz) since certain thresholds of UH have been shown as good proxies for# severe weather. SSPFs can be thought of as the perfect model forecast. They are derived as follows:
# 1. Regrid the maximum UH value over the 2-5km layer at each grid point to the NCEP 211 grid (dx = ~80km).
# 2. Create a binary mask of points that meet a given threshold of UH)
# 3. Convert the binary mask into a probability field by applying a Gaussian filter.
#
# For more information, please reference Sobash et al. 2011 (https://journals.ametsoc.org/doi/full/10.1175/WAF-D-10-05046.1).

###################################################################################################
# Datasets
# --------
#
# There are two dates that can be used as input data for this use case 20190518 or 20200205.
#
# * Input Data: HRRR data
# - There should 24 grib2 files.
# - Variable of interest: MXUPHL; the maximum updraft helicity
# - Level: Z2000-5000; from 2 - 5km
# - Format: grib2
# - Projection: Lambert Conformal
#
# * Location: kiowa:/d1/projects/METplus/METplus_Data/model_applications/convection_allowing_models/surrogate_severe_calc/
#
# * Data Source: Originally received from Burkely Gallo at the Storm Prediction Center.

###################################################################################################
# METplus Components
# ------------------
#
# This use case runs the PCPCombine, EnsembleStat, and RegridDataPlane MET tools.

###################################################################################################
# METplus Workflow
# ----------------
#
# This workflow loops over the data by process, meaning that each MET tool will run over all times
# before moving onto the tool. PCPCombine is called first, followed by EnsembleStat,
# and then, finally, RegridDataPlane.

###################################################################################################
# METplus Configuration
# ---------------------
#
# METplus first loads all of the configuration files found in parm/metplus_config. Then, it loads
# any configuration files passed to METplus by the command line with the -c option.
#
# .. highlight:: bash
# .. literalinclude:: ../../../../parm/use_cases/model_applications/convection_allowing_models/EnsembleStat_fcstHRRR_fcstOnly_SurrogateSevere.conf

###################################################################################################
# MET Configuration
# -----------------
#
# METplus sets environment variables based on the values in the METplus configuration file.
# These variables are referenced in the MET configuration file. **YOU SHOULD NOT SET ANY OF THESE ENVIRONMENT VARIABLES YOURSELF! THEY WILL BE OVERWRITTEN BY METPLUS WHEN IT CALLS THE MET TOOLS!** If there is a setting in the MET configuration file that is not controlled by an environment variable, you can add additional environment variables to be set only within the METplus environment using the [user_env_vars] section of the METplus configuration files. See the 'User Defined Config' section on the 'System Configuration' page of the METplus User's Guide for more information.
#
# **EnsembleStatConfig_Surrogate_severe**
#
# .. highlight:: bash
# .. literalinclude:: ../../../../parm/use_cases/model_applications/convection_allowing_models/EnsembleStatConfig_Surrogate_severe
#
# See the following file for more information about the environment variables set in this configuration file:
# parm/use_cases/met_tool_wrapper/EnsembleStat/EnsembleStat.py

###################################################################################################
# Running METplus
# ---------------
#
# The command to run this use case is::
#
# master_metplus.py -c /path/to/METplus/parm/use_cases/model_applications/convection_allowing_models/EnsembleStat_fcstHRRR_fcstOnly_SurrogateSevere.conf

###################################################################################################
# Expected Output
# ---------------

# A successful run of this use case will output the following to the screen and logfile::
#
# INFO: METplus has successfully finished runing.
#
# A successful run will have the following output files in the location defined by {OUTPUT_BASE}, which
# is located in the metplus_system.conf configuration file located in /path/to/METplus/parm/metplus_config.
# This list of files should be found for every time run through METplus. Using the output for 20190518 as an example.
#
# **PCPCombine output**:
#
# * 20190518/hrrr_ncep_2019051800f036.nc
#
# **EnsembleStat output**:
#
# * ensemble_stat_20190519_120000V_ens.nc
#
# **RegridDataPlane output**:
#
# * surrogate_severe_20190518_036V_regrid.nc
#

###################################################################################################
# Keywords
# --------
#
# sphinx_gallery_thumbnail_path =
#
# .. note:: PCPCombineUseCase, EnsembleStatUseCase, RegridDataPlaneUseCase
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,10 @@ LOOP_BY = INIT
INIT_TIME_FMT = %Y%m%d%H

# Start time for METplus run
INIT_BEG=2019051800
INIT_BEG=2020020500

# End time for METplus run
INIT_END=2019051800
INIT_END=2020020500

# Increment between METplus runs in seconds. Must be >= 60
INIT_INCREMENT=86400
Expand All @@ -27,10 +27,9 @@ LEAD_SEQ = 36
LOOP_ORDER = processes

# List of applications to run
PROCESS_LIST = PcpCombine, EnsembleStat
PROCESS_LIST = PcpCombine, EnsembleStat, RegridDataPlane


# PCP_COMBINE
# PCP_COMBINE (Step 1)
# run pcp_combine on forecast data
FCST_PCP_COMBINE_RUN = True

Expand All @@ -48,8 +47,7 @@ FCST_PCP_COMBINE_OUTPUT_ACCUM = 24
FCST_PCP_COMBINE_DERIVE_LOOKBACK = 24
FCST_PCP_COMBINE_INPUT_DATATYPE = GRIB


#ENSEMBLE_STAT
#ENSEMBLE_STAT (Steps 2 and 3)
# number of expected members for ensemble. Should correspond with the
# number of items in the list for FCST_ENSEMBLE_STAT_INPUT_TEMPLATE
ENSEMBLE_STAT_N_MEMBERS = 1
Expand All @@ -69,32 +67,57 @@ ENS_VAR1_THRESH = >=14.2, >=19.0, >=26.0, >=38.0, >=61.0


# REGRID_DATA_PLANE (Step 4)
# run regrid_data_plane on observation data
# Run regrid_data_plane on forecast data
FCST_REGRID_DATA_PLANE_RUN = True

# method to run regrid_data_plane, not setting this will default to NEAREST
# If true, process each field individually and write a file for each
# If false, run once per run time passing in all fields specified
REGRID_DATA_PLANE_ONCE_PER_FIELD = False

# Name of input field to process
FCST_REGRID_DATA_PLANE_VAR1_INPUT_FIELD_NAME = MXUPHL_24_A1_ENS_FREQ_ge14.2
FCST_REGRID_DATA_PLANE_VAR2_INPUT_FIELD_NAME = MXUPHL_24_A1_ENS_FREQ_ge19.0
FCST_REGRID_DATA_PLANE_VAR3_INPUT_FIELD_NAME = MXUPHL_24_A1_ENS_FREQ_ge26.0
FCST_REGRID_DATA_PLANE_VAR4_INPUT_FIELD_NAME = MXUPHL_24_A1_ENS_FREQ_ge38.0
FCST_REGRID_DATA_PLANE_VAR5_INPUT_FIELD_NAME = MXUPHL_24_A1_ENS_FREQ_ge61.0

# Level of input field to process
FCST_REGRID_DATA_PLANE_VAR1_INPUT_LEVEL = "(*,*)"
FCST_REGRID_DATA_PLANE_VAR2_INPUT_LEVEL = "(*,*)"
FCST_REGRID_DATA_PLANE_VAR3_INPUT_LEVEL = "(*,*)"
FCST_REGRID_DATA_PLANE_VAR4_INPUT_LEVEL = "(*,*)"
FCST_REGRID_DATA_PLANE_VAR5_INPUT_LEVEL = "(*,*)"

# Name of output field to create
FCST_REGRID_DATA_PLANE_VAR1_OUTPUT_FIELD_NAME = MXUPHL_prob_75
FCST_REGRID_DATA_PLANE_VAR2_OUTPUT_FIELD_NAME = MXUPHL_prob_80
FCST_REGRID_DATA_PLANE_VAR3_OUTPUT_FIELD_NAME = MXUPHL_prob_85
FCST_REGRID_DATA_PLANE_VAR4_OUTPUT_FIELD_NAME = MXUPHL_prob_90
FCST_REGRID_DATA_PLANE_VAR5_OUTPUT_FIELD_NAME = MXUPHL_prob_95

# Mask to use for regridding
REGRID_DATA_PLANE_VERIF_GRID = G211

# Method to run regrid_data_plane, not setting this will default to NEAREST
REGRID_DATA_PLANE_METHOD = MAXGAUSS

# regridding width used in regrid_data_plane, not setting this will default to 1
# Regridding width used in regrid_data_plane, not setting this will default to 1
REGRID_DATA_PLANE_WIDTH = 1

# mask to use for regridding
REGRID_DATA_PLANE_VERIF_GRID=G211

FCST_REGRID_DATA_PLANE_VAR1_FIELD_NAME = MXUPHL_24_A1_ENS_FREQ_ge14.2
# Set Gaussian dx value to add as command line argument - not added if unset or blank
REGRID_DATA_PLANE_GAUSSIAN_DX = 81.271

# Set Gaussian filter radius value to add as command line argument - not added if unset or blank
REGRID_DATA_PLANE_GAUSSIAN_RADIUS = 120

[dir]
INPUT_BASE = /d3/projects/MET/METplus_Data
OUTPUT_BASE = /d3/personal/kalb/METplus_Data
PARM_BASE = /home/kalb/surrogate_severe/METplus/parm

# location of configuration files used by MET applications
CONFIG_DIR={PARM_BASE}/use_cases/model_applications/convection_allowing_models

# input and output data directories for each application in PROCESS_LIST
FCST_PCP_COMBINE_INPUT_DIR = {INPUT_BASE}/model_applications/convection_allowing_models/surrogate_severe_calc
FCST_PCP_COMBINE_OUTPUT_DIR = {OUTPUT_BASE}/model_applications/convection_allowing_models/surrogate_severe_calc
FCST_PCP_COMBINE_OUTPUT_DIR = {OUTPUT_BASE}/convection_allowing_models/surrogate_severe_calc

FCST_ENSEMBLE_STAT_INPUT_DIR = {FCST_PCP_COMBINE_OUTPUT_DIR}
ENSEMBLE_STAT_OUTPUT_DIR = {FCST_PCP_COMBINE_OUTPUT_DIR}
Expand All @@ -110,3 +133,7 @@ FCST_PCP_COMBINE_OUTPUT_TEMPLATE = {init?fmt=%Y%m%d}/hrrr_ncep_{init?fmt=%Y%m%d%

# To enemble_stat
FCST_ENSEMBLE_STAT_INPUT_TEMPLATE = {FCST_PCP_COMBINE_OUTPUT_TEMPLATE}

# To regrid_data_plane
FCST_REGRID_DATA_PLANE_INPUT_TEMPLATE = ensemble_stat_{valid?fmt=%Y%m%d}_120000V_ens.nc
FCST_REGRID_DATA_PLANE_OUTPUT_TEMPLATE = surrogate_severe_{init?fmt=%Y%m%d}_{lead?fmt=%HHH}V_regrid.nc
Loading