5.1.24.2. TCPairs: Basic Use Case for Tropical Cyclones

met_tool_wrapper/TCPairs/TCPairs_tropical.conf

Scientific Objective

Once this method is complete, a forecast and reference track analysis file will have been paired up, allowing statistical information to be extracted.

Datasets

Forecast: A Deck
/path/to/hwrf/adeck
Observation: Best Track - B Deck
/path/to/hwrf/bdeck
Location: All of the input data required for this use case can be found in the met_test sample data tarball. Click here to the METplus releases page and download sample data for the appropriate release: https://github.com/dtcenter/METplus/releases
The tarball should be unpacked into the directory that you will set the value of INPUT_BASE. See Running METplus section for more information.
Data Source: HWRF

METplus Components

This use case utilizes the METplus TCPairs wrapper to search for files that are valid at a given run time and generate a command to run the MET tool tc_pairs.

METplus Workflow

TCPairs is the only tool called in this example. It processes the following run times:

Init: 2018-08-30_06Z, 2018-08-30_12Z, 2018-08-30_18Z

METplus Configuration

METplus first loads all of the configuration files found in parm/metplus_config, then it loads any configuration files passed to METplus via the command line with the -c option, i.e. -c /path/to/TCPairs_tropical.conf

#
#  CONFIGURATION
#
[config]

# Looping by times: steps through each 'task' in the PROCESS_LIST for each
# defined time, and repeats until all times have been evaluated.
LOOP_ORDER = times

# Configuration files
TC_PAIRS_CONFIG_FILE = {PARM_BASE}/met_config/TCPairsConfig_wrapped

# 'Tasks' to be run
PROCESS_LIST = TCPairs

LOOP_BY = INIT

# The init time begin and end times, increment, and last init hour.
INIT_TIME_FMT = %Y%m%d%H
INIT_BEG = 2018083006
INIT_END = 2018083018

# This is the step-size. Increment in seconds from the begin time to the end time
# set to 6 hours = 21600 seconds
INIT_INCREMENT = 21600 

# A list of times to include, in format YYYYMMDD_hh
TC_PAIRS_INIT_INCLUDE =

# A list of times to exclude, in format YYYYMMDD_hh
TC_PAIRS_INIT_EXCLUDE =

# Specify model init time window in format YYYYMM[DD[_hh]]
# Only tracks that fall within the initialization time window will be used
TC_PAIRS_INIT_BEG =
TC_PAIRS_INIT_END =

# Specify model valid time window in format YYYYMM[DD[_hh]]
# Only tracks that fall within the valid time window will be used
TC_PAIRS_VALID_BEG =
TC_PAIRS_VALID_END =

#
# Run MET tc_pairs by indicating the top-level directories for the A-deck and B-deck files. Set to 'yes' to
# run using top-level directories, 'no' if you want to run tc_pairs on files paired by the wrapper.
TC_PAIRS_READ_ALL_FILES = no

# set to true or yes to reformat track data into ATCF format expected by tc_pairs
TC_PAIRS_REFORMAT_DECK = no

# OVERWRITE OPTIONS
# Don't overwrite filter files if they already exist.
# Set to yes if you do NOT want to override existing files
# Set to no if you do want to override existing files
TC_PAIRS_SKIP_IF_OUTPUT_EXISTS = no

#
# MET TC-Pairs
#
# List of models to be used (white space or comma separated) eg: DSHP, LGEM, HWRF
# If no models are listed, then process all models in the input file(s).
MODEL = MYNN, H19C, H19M, CTRL, MYGF

#TC_PAIRS_DESC =

# List of storm ids of interest (space or comma separated) e.g.: AL112012, AL122012
# If no storm ids are listed, then process all storm ids in the input file(s).
#TC_PAIRS_STORM_ID = ML2092014
#TC_PAIRS_STORM_ID = al062018, al092018, al132018, al142018

# Basins (of origin/region).  Indicate with space or comma-separated list of regions, eg. AL: for North Atlantic,
# WP: Western North Pacific, CP: Central North Pacific, SH: Southern Hemisphere, IO: North Indian Ocean, LS: Southern
# Hemisphere
#TC_PAIRS_BASIN = AL
TC_PAIRS_BASIN =

# Cyclone, a space or comma-separated list of cyclone numbers. If left empty, all cyclones will be used.
TC_PAIRS_CYCLONE = 06
#TC_PAIRS_CYCLONE =

# Storm name, a space or comma-separated list of storm names to evaluate.  If left empty, all storms will be used.
TC_PAIRS_STORM_NAME =

# DLAND file, the full path of the file that contains the gridded representation of the
# minimum distance from land.
TC_PAIRS_DLAND_FILE = MET_BASE/tc_data/dland_global_tenth_degree.nc


#
#  DIRECTORIES
#
[dir]
# Location of input track data directory
# for ADECK and BDECK data
TC_PAIRS_ADECK_INPUT_DIR = {INPUT_BASE}/met_test/new/hwrf/adeck
TC_PAIRS_EDECK_INPUT_DIR =
TC_PAIRS_BDECK_INPUT_DIR = {INPUT_BASE}/met_test/new/hwrf/bdeck

TC_PAIRS_OUTPUT_DIR = {OUTPUT_BASE}/tc_pairs

[filename_templates]
TC_PAIRS_ADECK_TEMPLATE = {model?fmt=%s}/*{cyclone?fmt=%s}l.{date?fmt=%Y%m%d%H}.trak.hwrf.atcfunix
TC_PAIRS_EDECK_TEMPLATE =
TC_PAIRS_BDECK_TEMPLATE = b{basin?fmt=%s}{cyclone?fmt=%s}{date?fmt=%Y}.dat
TC_PAIRS_OUTPUT_TEMPLATE = tc_pairs_{basin?fmt=%s}{date?fmt=%Y%m%d%H}.dat

MET Configuration

METplus sets environment variables based on user settings in the METplus configuration file. See How METplus controls MET config file settings for more details.

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 currently not supported by METplus you’d like to control, please refer to: Overriding Unsupported MET config file settings

Note

See the TCPairs MET Configuration section of the User’s Guide for more information on the environment variables used in the file below:

////////////////////////////////////////////////////////////////////////////////
//
// Default TCPairs configuration file
//
////////////////////////////////////////////////////////////////////////////////

//
// ATCF file format reference:
//   http://www.nrlmry.navy.mil/atcf_web/docs/database/new/abrdeck.html
//

//
// Models
//
${METPLUS_MODEL}

//
// Description
//
${METPLUS_DESC}

//
// Storm identifiers
//
${METPLUS_STORM_ID}

//
// Basins
//
${METPLUS_BASIN}

//
// Cyclone numbers
//
${METPLUS_CYCLONE}

//
// Storm names
//
${METPLUS_STORM_NAME}

//
// Model initialization time windows to include or exclude
//
${METPLUS_INIT_BEG}
${METPLUS_INIT_END}
${METPLUS_INIT_INCLUDE}
${METPLUS_INIT_EXCLUDE}

//
// Valid model time window
//
${METPLUS_VALID_BEG}
${METPLUS_VALID_END}

//
// Model initialization hours
//
init_hour = [];

//
// Required lead time in hours
//
lead_req = [];

//
// lat/lon polylines defining masking regions
//
init_mask  = "";
valid_mask = "";

//
// Specify if the code should check for duplicate ATCF lines
//
check_dup = FALSE;

//
// Specify special processing to be performed for interpolated models.
// Set to NONE, FILL, or REPLACE.
//
interp12 = REPLACE;

//
// Specify how consensus forecasts should be defined
//
consensus = [];

//
// Forecast lag times
//
lag_time = [];

//
// CLIPER/SHIFOR baseline forecasts to be derived from the BEST
// and operational (CARQ) tracks.
//
best_technique = [ "BEST" ];
best_baseline  = [];
oper_technique = [ "CARQ" ];
oper_baseline  = [];

//
// Specify the datasets to be searched for analysis tracks (NONE, ADECK, BDECK,
// or BOTH).
//
anly_track = BDECK;

//
// Specify if only those track points common to both the ADECK and BDECK
// tracks be written out.
//
match_points = TRUE;

//
// Specify the NetCDF output of the gen_dland tool containing a gridded
// representation of the minimum distance to land.
//
${METPLUS_DLAND_FILE}

//
// Specify watch/warning information:
//   - Input watch/warning filename
//   - Watch/warning time offset in seconds
//
watch_warn = {
   file_name   = "MET_BASE/tc_data/wwpts_us.txt";
   time_offset = -14400;
}

//
// Indicate a version number for the contents of this configuration file.
// The value should generally not be modified.
//
//version = "V9.0";

${METPLUS_MET_CONFIG_OVERRIDES}

Running METplus

This use case can be run two ways:

  1. Passing in TCPairs_tropical.conf then a user-specific system configuration file:

    run_metplus.py -c /path/to/TCPairs_tropical.conf -c /path/to/user_system.conf
    
  2. Modifying the configurations in parm/metplus_config, then passing in TCPairs_tropical.conf::

    run_metplus.py -c /path/to/TCPairs_tropical.conf

The former method is recommended. Whether you add them to a user-specific configuration file or modify the metplus_config files, the following METplus configuration variables must be set correctly to run this example.:

  • INPUT_BASE - Path to directory where sample data tarballs are unpacked (See Datasets section to obtain tarballs).

  • OUTPUT_BASE - Path where METplus output will be written. This must be in a location where you have write permissions

  • MET_INSTALL_DIR - Path to location where MET is installed locally

Example User Configuration File:

[dir]
INPUT_BASE = /path/to/sample/input/data
OUTPUT_BASE = /path/to/output/dir
MET_INSTALL_DIR = /path/to/met-X.Y

NOTE: All of these items must be found under the [dir] section.

Expected Output

A successful run will output the following both to the screen and to the logfile:

INFO: METplus has successfully finished running.

Refer to the value set for OUTPUT_BASE to find where the output data was generated. Output for this use case will be found in tc_pairs and will contain the following files:

  • tc_pairs_al2018083006.dat.tcst

  • tc_pairs_al2018083012.dat.tcst

  • tc_pairs_al2018083018.dat.tcst

Keywords

sphinx_gallery_thumbnail_path = ‘_static/met_tool_wrapper-TCPairs.png’

Total running time of the script: ( 0 minutes 0.000 seconds)

Gallery generated by Sphinx-Gallery