[Met_help] [rt.rap.ucar.edu #91553] History for NetCDF MPAS output

John Halley Gotway via RT met_help at ucar.edu
Tue Sep 3 09:40:28 MDT 2019


----------------------------------------------------------------
  Initial Request
----------------------------------------------------------------

I am writing to seek your help. I have remapped MPAS output to WRF grids 
and in pressure levels. However, when I try to run point_stat, I always 
get the error message below:

"Met2dDataFileFactory::new_met_2d_data_file() -> error opening file 
"history2wrf.2017-02-01_00:00:00.nc"

(the datafile and config are saved at /glade/scratch/chenming/MET)

I also have some other questions related to MET. Can I drop by at your 
convenient time?

Thank you!

----------------------------------------------------------------
  Complete Ticket History
----------------------------------------------------------------

Subject: NetCDF MPAS output
From: John Halley Gotway
Time: Fri Aug 16 10:50:25 2019

Hi Ming,

Whenever getting going with a new gridded dataset in MET, I always
start by running the plot_data_plane tool.  That tells me whether or
not MET is able to read data from the input file and also creates a
plot to show me where the data lives on the earth.  That way I can
check that MET is reading the grid information correctly.

Below, I tried plotting the PSFC variable:
plot_data_plane history2wrf.2017-02-01_00:00:00.nc plot.ps
'name="PSFC"; level="(0,*,*)";'


But got this error:
ERROR  : MetNcPinterpDataFile::open(const char *) -> unable to open
NetCDF file "history2wrf.2017-02-01_00:00:00.nc"

Running through the debugger, I see that MET can't find the definition
of the grid/projection information in the file and that's why it's
failing.  Looking at some other output from the WRF p_interp utility,
I see Lambert Conformal grid information specified in a variable like
this:

        int Lambert_Conformal ;
                Lambert_Conformal:grid_mapping_name =
"lambert_conformal_conic" ;
                Lambert_Conformal:standard_parallel = 38.27f, 38.27f ;
                Lambert_Conformal:longitude_of_central_meridian =
-101.96f ;
                Lambert_Conformal:latitude_of_projection_origin =
14.80721f ;
                Lambert_Conformal:longitude_of_projection_origin =
-128.1814f ;
                Lambert_Conformal:false_easting = 0.f ;
                Lambert_Conformal:false_northing = 0.f ;

So we just need to add the grid definition to these NetCDF files.

Thanks,
John


------------------------------------------------
Subject: NetCDF MPAS output
From: John Halley Gotway
Time: Fri Aug 16 11:52:02 2019

Ming,

Here's the list of global attributes we found that are required for
NetCDF p_interp output files.  MET interprets NetCDF file as being
p_interp output when "ON PRES LEVELS" appears in the "TITLE" global
attribute.

You can also add "file_type = NETCDF_PINT;" to force MET to interpret
the input files as such.

// global attributes:
      :MAP_PROJ_CHAR = "Lambert Conformal" ;
      :DX = 15000.f ;
      :DY = 15000.f ;
      :TRUELAT1 = 38.27f ;
      :TRUELAT2 = 38.27f ;
      :CEN_LAT = 38.26999f ;
      :CEN_LON = -101.96f ;
      :STAND_LON = -101.96f ;

In the PB2NC Config file, add "D_WIND" to list of obs to be extracted
from the input PrepBUFR files:

//
// BUFR variable names to retain or derive.
// Use obs_bufr_map to rename variables in the output.
// If empty, process all available variables.
//
obs_bufr_var = [ "QOB", "TOB", "ZOB", "UOB", "VOB", "D_WIND" ];

That should result in "WIND" observations in the output.


To define masking regions in Point-Stat, set the "mask" dictionary in
the Point-Stat config file:
mask = {
   grid  = [ "FULL" ];
   poly  = [ "/path/to/mask.poly". "/path/to/mask_EAST.nc" ];
   sid   = [];
   llpnt = [];
}

Or, to run more efficiently, run gen_vx_mask first.  For example:
met-8.1/bin/gen_vx_mask history2wrf.2017-02-01_00:00:00_JHG.nc
/usr/local/met-8.1/share/met/poly/EAST.poly mask_EAST.nc -name
"My_East_Mask"








------------------------------------------------


More information about the Met_help mailing list