Skip to content

Grid-Diag does not correctly ignore missing data values. #1562

@JohnHalleyGotway

Description

@JohnHalleyGotway

Describe the Problem

This issue was found when applying the Grid-Diag tool to the Air Force cloud evaluation project.

When missing data values are present in the input gridded data, Grid-Diag includes their values in the resulting 1D and 2D PDF's.

Expected Behavior

The Grid-Diag tool should ignore missing data values and not include them in the output.

Environment

Describe your runtime environment:
1. Machine: behavior found on Cheyenne but reproduced anywhere
2. Software version number(s): bug in MET version 9.1

To Reproduce

Describe the steps to reproduce the behavior:
1. Edit test/config/GridDiagConfig_TMP
2. Reset mask.poly to an empty string to turn it off.
3. Run the unit test: perl/unit.pl xml/unit_grid_diag.xml
4. Use ncdump to inspect the output:

ncdump -v hist_TMP_Z2 /Volumes/d1/projects/MET/MET_unit_test/MET_test_output/grid_diag/grid_diag_temperature.nc
# Sum the counts and divide by the grid size
R
sum(c(87327, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 
    3, 23, 57, 93, 133, 329, 632, 565, 574, 821, 915, 1157, 1664, 3003, 5577, 
    6209, 6141, 5234, 5170, 6379, 7018, 6777, 6223, 5948, 5769, 6040, 7044, 
    8082, 10754, 6841, 3493, 2663, 2022, 1470, 1074, 632, 354, 251, 187, 93, 
    31, 11, 2, 0, 0))/(185*129)
> 9
quit("no")

The ratio of 9 matches the number of input files which means that all point, including the bad data values are included.

Relevant Deadlines

Include fix in met-9.1.1.

Funding Source

Define the source of funding and account keys here or state NONE.

Define the Metadata

Assignee

  • Select engineer(s) or no engineer required: John Halley Gotway
  • Select scientist(s) or no scientist required: Jamie Wolff

Labels

  • Select component(s)
  • Select priority
  • Select requestor(s)

Projects and Milestone

  • Review projects and select relevant Repository and Organization ones or add "alert:NEED PROJECT ASSIGNMENT" label
  • Select milestone to relevant bugfix version

Define Related Issue(s)

Consider the impact to the other METplus components.

Bugfix Checklist

See the METplus Workflow for details.

  • Complete the issue definition above, including the Time Estimate and Funding Source.
  • Fork this repository or create a branch of main_<Version>.
    Branch name: bugfix_<Issue Number>_main_<Version>_<Description>
  • Fix the bug and test your changes.
  • Add/update log messages for easier debugging.
  • Add/update unit tests.
  • Add/update documentation.
  • Push local changes to GitHub.
  • Submit a pull request to merge into main_<Version>.
    Pull request: bugfix <Issue Number> main_<Version> <Description>
  • Define the pull request metadata, as permissions allow.
    Select: Reviewer(s), Project(s), Milestone, and Linked issues
  • Iterate until the reviewer(s) accept and merge your changes.
  • Delete your fork or branch.
  • Complete the steps above to fix the bug on the develop branch.
    Branch name: bugfix_<Issue Number>_develop_<Description>
    Pull request: bugfix <Issue Number> develop <Description>
  • Close this issue.

Metadata

Metadata

Assignees

Labels

requestor: NCARNational Center for Atmospheric Researchtype: bugFix something that is not working

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions