Skip to content

Use cases

A use case is a worked example you can actually run. It bundles a configuration file, a documentation page, and a known set of sample input data so that you can reproduce a complete verification workflow end to end — then adapt it to your own forecasts and observations. Use cases are how most people learn METplus and how many real evaluation pipelines begin.

The METplus documentation puts it plainly: use cases “provide a low-level workflow which includes setting paths to data, dates to process, the order of processing, and configuration options.” In other words, a use case is a complete recipe. Rather than starting from a blank configuration and guessing which variables matter, you start from a working example that someone has already wired together and documented.

Each use case is built around wrappers — the thin Python layers METplus places around the underlying MET tools. A wrapper translates plain configuration variables into the command line and parameter files that a MET tool expects, finds the right input files for each run time, and hands the results to the next step. A use case strings one or more wrappers together so that data flows from ingest, through statistics, to aggregated output.

The User’s Guide organizes every use case into two families. The split is about scope: is the example teaching you one tool, or is it solving a real evaluation problem in a particular science domain?

MET tool use cases

Focused on a single MET tool or feature. These are the building blocks — each one shows the minimal configuration needed to drive one wrapper (for example, converting observations, computing point statistics, or building a verification mask). They live under parm/use_cases/met_tool_wrapper/.

one tool · teaching examples · building blocks

Model applications use cases

Organized by application area — precipitation, medium range, tropical cyclones, and more. These typically chain several wrappers to answer a domain question with realistic data, and are closer to a production pipeline. They live under parm/use_cases/model_applications/.

chained wrappers · by science domain · realistic

The MET tool family covers the individual wrappers. Many tools ship more than one use case to show different modes — a basic run, a run that pulls data through Python embedding (feeding a tool data computed by your own Python instead of a file on disk), or a variation such as running once per field. A representative sample of the wrappers covered:

Pre-processing & ingest

ASCII2NC, PB2NC, MADIS2NC, IODA2NC, PCPCombine, RegridDataPlane, Point2Grid, GenVxMask, PyEmbedIngest, GempakToCF, DataIngest

Statistics & verification

PointStat, GridStat, EnsembleStat, GenEnsProd, MODE, MTD, SeriesAnalysis, WaveletStat, PairStat, GridDiag

Aggregation & analysis

StatAnalysis, METdbLoad, ExtractTiles, RMWAnalysis

Tropical cyclone

TCPairs, TCStat, TCGen, TCDiag, TCRMW, GFDLTracker, CyclonePlotter

Plotting

PlotDataPlane, PlotPointObs

Workflow & scripting

UserScript, Example

The model applications family is grouped by science domain. Each category collects use cases that address verification problems common to that area. The table below lists the categories exactly as the documentation names them, with a coarse sense of how deep coverage currently runs in each.

CategoryWhat it tends to evaluateCoverage
Air Quality and CompositionPollutants and atmospheric chemistry fieldslow
ClimateLong-period and climatological comparisonslow
CloudsCloud fields and satellite-derived productsmedium
Data AssimilationObservation feedback and analysis diagnosticslow
FireWildfire-related forecast fieldslow
Land SurfaceSurface and soil-related variablesmedium
Marine and CryosphereOcean, sea ice, and snow fieldshigh
Medium RangeSeveral-day forecast verificationhigh
Planetary Boundary LayerNear-surface vertical structurelow
PrecipitationAccumulated precipitation, often object-basedhigh
Subseasonal to SeasonalWeeks-to-months lead verificationmedium
Subseasonal to Seasonal: Mid-LatitudeMid-latitude S2S patternsmedium
Subseasonal to Seasonal: Madden-Julian OscillationMJO indices and diagnosticsmedium
Subseasonal to Seasonal: Soil MoistureS2S soil moisture signalslow
Subseasonal to Seasonal: StratosphereStratospheric S2S diagnosticsmedium
Short RangeShort-lead and convection-relevant forecastshigh
Space WeatherSpace-environment fieldslow
Tropical Cyclone and Extra Tropical CycloneTC and ET track / genesis verificationmedium
Unstructured GridsNative unstructured-mesh outputlow

Coverage is a coarse signal that grows with each release — Short Range, Medium Range, Marine and Cryosphere, and Precipitation are currently the deepest. Check the live index for the exact current set.

However simple or complex, every use case is made of the same three parts. Knowing them makes it obvious what to copy and what to change when you adapt one.

1 · The configuration file (.conf) — The runnable artifact. It sets the wrappers to use and their order (PROCESS_LIST), the time loop (init/valid times and forecast leads), the input file templates, the fields to verify, and tool-specific options. This is the file you point run_metplus.py at.

2 · The documentation page — A human-readable write-up of the example — what it does, which datasets it uses, what the output looks like, and the keywords it is tagged with. This is what you find through the documentation search and the use-case indexes.

3 · The expected sample data — A known set of input files, distributed in versioned tarballs, that the .conf is written to consume. Because the data is fixed, the example is reproducible: run it and you should get the documented output.

The clearest way to picture a model-applications use case is as a small assembly line: sample data enters on the left, each wrapper transforms it, and statistics and plots come out on the right. The example below is a classic point-verification chain — convert PrepBUFR observations to NetCDF, match forecasts against them, aggregate the resulting statistics, and plot.

A METplus use case as a chained-wrapper pipeline Versioned sample input data flows into PB2NC, then PointStat, then StatAnalysis, then a plotting step, producing NetCDF, ASCII statistics, aggregated statistics, and a final plot. Sample input data INPUT_BASE PB2NC PrepBUFR → NetCDF PointStat fcst vs obs StatAnalysis aggregate Plot OUTPUT_BASE obs NetCDF .stat lines aggregated stats .png / .ps PROCESS_LIST — order set in the .conf forecast files
Figure 1. A use case is a chain of wrappers. The PROCESS_LIST in the .conf fixes the order; each wrapper reads from sample data (or a previous step's output) and writes intermediate artifacts, ending in aggregated statistics and a plot. Tool names shown are illustrative of a point-verification chain.

Use cases are reproducible only because they run against a fixed, downloadable dataset. The data is not bundled with the METplus source — you obtain it separately and point METplus at it.

Sample tarballs are versioned to match a METplus Coordinated Release — a group of component releases (MET, METplus, and the companion packages) that were developed and tested together — and named by use-case category. Per the documentation, a tarball is “named with the X.Y version of the corresponding METplus Coordinated Release and the name of the use case category separated by a dash, e.g. 4.1-data_assimilation or 4.0-met_tool_wrapper.” The leading X.Y is the METplus release line, so download the tarball whose X.Y matches the METplus version you cloned. The MET tool examples pull from a met_tool_wrapper tarball, and each model-applications category has its own.

Running a use case is a single command: run_metplus.py <use_case.conf> <user_system.conf>. The first argument is the shipped example; the second is your own configuration that supplies the paths above. Here is the full path from nothing to output.

  1. Get the sample data. Download the tarball that matches your METplus release and the category you want — for the introductory examples, the one that starts with sample_data-met_tool_wrapper. Uncompress it somewhere you can write to.

  2. Write a user configuration file. Create a small user_system.conf that sets INPUT_BASE to the uncompressed sample-data directory, OUTPUT_BASE to an output directory, and MET_INSTALL_DIR to your MET install. You reuse this file for every use case.

  3. Run the simplest example first. Confirm your install works before touching real data:

    Terminal window
    run_metplus.py \
    /path/to/METplus/parm/use_cases/met_tool_wrapper/Example/Example.conf \
    /path/to/user_system.conf

    This exercises the common config variables and time loop without invoking any MET tool.

  4. Run a real tool use case. Point at a use case that drives an actual tool, for example GridStat:

    Terminal window
    run_metplus.py \
    /path/to/METplus/parm/use_cases/met_tool_wrapper/GridStat/GridStat.conf \
    /path/to/user_system.conf
  5. Confirm success. A complete run ends with the message METplus has successfully finished running. Find your results under OUTPUT_BASE.

  6. Chain configs to sweep combinations. You can pass several .conf files in sequence; later files override earlier ones (the same override-by-order rule covered in Getting started). This is how you reuse one use case across multiple forecast/observation pairs by layering small config fragments. Here forecastA.conf, observationA.conf, and use_case_name.conf are use-case fragments; your machine-specific user_system.conf still belongs last so its paths win:

    Terminal window
    run_metplus.py forecastA.conf observationA.conf use_case_name.conf user_system.conf
    run_metplus.py forecastA.conf observationB.conf use_case_name.conf user_system.conf
    run_metplus.py forecastB.conf observationA.conf use_case_name.conf user_system.conf
    run_metplus.py forecastB.conf observationB.conf use_case_name.conf user_system.conf

A derived, human-readable re-presentation — not official documentation. Sources: metplus.readthedocs.io · Users_Guide/usecases.html