METplus Practical Session Guide (Version 5.0) | Session 5: MODE and MTD > End of Session 5 and Additional Exercises

End of Practical Session 5

Congratulations! You have completed Session 5!

If you have extra time, you may want to try these additional METplus exercises.

Instructions: Modify the METplus configuration files to change the forecast leads that are processed by MTD. Following these instructions will give you more insight on how METplus configures MTD.
To do this, copy your MTD configuration file and rename it to mtd.skip.conf for this exercise.
cp \
${METPLUS_BUILD_BASE}/parm/use_cases/met_tool_wrapper/MTD/MTD.conf \
$METPLUS_TUTORIAL_DIR/user_config/mtd.skip.conf
Open mtd.skip.conf with an editor to change forecast lead values and add an additional lead time.
vi ${METPLUS_TUTORIAL_DIR}/user_config/mtd.skip.conf
Change LEAD_SEQ to process the same forecasts but using an increment rather than listing the explicit values
LEAD_SEQ = begin_end_incr(6, 15, 3)
Close the file and rerun master_metplus passing in your new custom config file for this exercise and changing OUTPUT_BASE to a new location so you can keep it separate from the other runs.
run_metplus.py \
${METPLUS_TUTORIAL_DIR}/user_config/mtd.skip.conf \
${METPLUS_TUTORIAL_DIR}/tutorial.conf \
config.OUTPUT_BASE=${METPLUS_TUTORIAL_DIR}/output/exercises/mtd_skip

Did you see the WARNING message?

WARNING: Could not find OBS file /d1/projects/METplus/METplus_Data/met_test/new/ST2ml2005080715_A03h.nc using template ST2ml{valid?fmt=%Y%m%d%H}_A03h.nc

If you look in the data directories for this run, you will see that while the forecast for the 15 hour lead exists, the observation file does not. METplus will only add items to the MTD lists if both corresponding files are available.

ls -1 ${METPLUS_DATA}/met_test/data/sample_fcst/2005080700
ls -1 ${METPLUS_DATA}/met_test/new/ST2*
Now look at the file lists that were generated by METplus for MTD
less ${METPLUS_TUTORIAL_DIR}/output/exercises/mtd_skip/stage/file_lists/20050807060000_mtd_fcst_APCP.txt
less ${METPLUS_TUTORIAL_DIR}/output/exercises/mtd_skip/stage/file_lists/20050807060000_mtd_obs_APCP_03.txt
Check the log file for any differences from the last run that processed forecast leads 6, 9, and 12 hour.
ls ${METPLUS_TUTORIAL_DIR}/output/exercises/mtd_skip/logs/metplus.log.*
Instructions: Modify the METplus configuration files to change the forecast leads that are processed by MTD. Following these instructions will give you more insight on how METplus configures MTD.
To do this, copy your MTD configuration file and rename it to mtd.unzip.conf for this exercise.
cp ${METPLUS_BUILD_BASE}/parm/use_cases/met_tool_wrapper/MTD/MTD.conf ${METPLUS_TUTORIAL_DIR}/user_config/mtd.unzip.conf
Open mtd.unzip.conf with an editor and change the LEAD_SEQ to process forecast leads 3 and 6 hours.
vi ${METPLUS_TUTORIAL_DIR}/user_config/mtd.unzip.conf
LEAD_SEQ = 3H, 6H
Close the file and rerun METplus, passing in your new custom config file and OUTPUT_BASE for this exercise
run_metplus.py \
${METPLUS_TUTORIAL_DIR}/user_config/mtd.unzip.conf \
${METPLUS_TUTORIAL_DIR}/tutorial.conf \
config.OUTPUT_BASE=${METPLUS_TUTORIAL_DIR}/output/exercises/unzip
Now look at the file list that were generated by METplus for MTD observation files
less ${METPLUS_TUTORIAL_DIR}/output/exercises/unzip/stage/file_lists/20050807030000_mtd_obs_APCP_03.txt

Notice that the path of the 3 hour file is under your ${METPLUS_TUTORIAL_DIR}, while the 6 hour file is under ${METPLUS_DATA}.  If you look in the data directories for this run, you will see that the 3 hour observation file is gzipped in ${METPLUS_DATA}.

ls -1 ${METPLUS_DATA}/met_test/new/ST2*

METplus can recognize that files with gz, bzip2, or zip extensions are compressed and will do so automatically, placing the uncompressed file in the staging directory so that METplus doesn't modify any data in the input directory. METplus can be configured to scrub the staging directory after the run completes to save space, or leave the files so that they may be used by subsequent METplus runs without having to uncompress again (See SCRUB_STAGING_DIR and STAGING_DIR in the METplus User's Guide).