[Met_help] [rt.rap.ucar.edu #80847] History for Using regrid_data_plane to Read in Poorly Constructed Grib2
Julie Prestopnik via RT
met_help at ucar.edu
Wed Jun 14 11:05:24 MDT 2017
----------------------------------------------------------------
Initial Request
----------------------------------------------------------------
Hello,
I apologize if this is a simple fix, but I am trying to read in a grib2
file using regrid_data_plane where most of the field metadata is
unspecified. There is only one field for each grib2 file, so all I have to
do is read in the first and only field.
An example of the metadata is shown below:
*wgrib2 -V
2017060212_acc01_ffg.grib21:0:vt=0017060212:surface:missing,missing=0:var
discipline=112 center=7 local_table=1 parmcat=1 parm=194:
ndata=859108:undef=384946:mean=49.4947:min=5.02:max=212.24
grid_template=20:winds(grid): polar stereographic grid: (1082 x 794)
input WE:SN output WE:SN res 56 North pole lat1 24.298999 lon1
240.705001 latD 60.000000 lonV 255.000000 dx 4762.453000 m dy 4762.443000 m*
And my command to read in the file and interpolate it to a 0.1 degree
lat/lon grid is:
*/opt/MET6/met6.0/bin/regrid_data_plane
/usr1/wpc_cpgffh/gribs/temp/ERO_20170603/2017060212_acc01_ffg.grib2 'latlon
701 301 20 -130 0.1 0.1'
/usr1/wpc_cpgffh/gribs/temp/ERO_20170603/2017060212_acc01_ffg.grib2.nc
<http://2017060212_acc01_ffg.grib2.nc> -field 'name="???"; level="(*,*)";'*
where I don't know the name or field name. Thanks!
Mike
--
Michael J. Erickson, Ph.D
Cooperative Institute for Research in Environmental Sciences (CIRES)
CIRES Contractor for the Weather Prediction Center (WPC)
Phone: 301-683-1546
----------------------------------------------------------------
Complete Ticket History
----------------------------------------------------------------
Subject: Using regrid_data_plane to Read in Poorly Constructed Grib2
From: Julie Prestopnik
Time: Tue Jun 13 11:01:03 2017
Hi Mike. I see that you are having trouble processing a grib file
with
regrid_data_plane. Thank you for sending the command you would like
to
use.
Could you please send me the grib2 file that you are trying to
process?
You can post it to our anonymous ftp site following these
instructions:
http://www.dtcenter.org/met/users/support/met_help.php#ftp
Please write back once you've posted it, and I'll go grab it.
Thanks!
Julie
On Tue, Jun 13, 2017 at 10:47 AM, Michael Erickson - NOAA Affiliate
via RT <
met_help at ucar.edu> wrote:
>
> Tue Jun 13 10:47:36 2017: Request 80847 was acted upon.
> Transaction: Ticket created by michael.j.erickson at noaa.gov
> Queue: met_help
> Subject: Using regrid_data_plane to Read in Poorly Constructed
Grib2
> Owner: Nobody
> Requestors: michael.j.erickson at noaa.gov
> Status: new
> Ticket <URL:
https://rt.rap.ucar.edu/rt/Ticket/Display.html?id=80847 >
>
>
> Hello,
>
> I apologize if this is a simple fix, but I am trying to read in a
grib2
> file using regrid_data_plane where most of the field metadata is
> unspecified. There is only one field for each grib2 file, so all I
have to
> do is read in the first and only field.
>
> An example of the metadata is shown below:
>
>
>
>
>
>
>
> *wgrib2 -V
>
2017060212_acc01_ffg.grib21:0:vt=0017060212:surface:missing,missing=0:var
> discipline=112 center=7 local_table=1 parmcat=1 parm=194:
> ndata=859108:undef=384946:mean=49.4947:min=5.02:max=212.24
> grid_template=20:winds(grid): polar stereographic grid: (1082 x
794)
> input WE:SN output WE:SN res 56 North pole lat1 24.298999 lon1
> 240.705001 latD 60.000000 lonV 255.000000 dx 4762.453000 m dy
4762.443000
> m*
> And my command to read in the file and interpolate it to a 0.1
degree
> lat/lon grid is:
>
> */opt/MET6/met6.0/bin/regrid_data_plane
> /usr1/wpc_cpgffh/gribs/temp/ERO_20170603/2017060212
<%28201%29%20706-0212>
> _acc01_ffg.grib2 'latlon
> 701 301 20 -130 0.1 0.1'
>
/usr1/wpc_cpgffh/gribs/temp/ERO_20170603/2017060212_acc01_ffg.grib2.nc
> <http://2017060212_acc01_ffg.grib2.nc> -field 'name="???";
> level="(*,*)";'*
>
> where I don't know the name or field name. Thanks!
>
> Mike
>
> --
>
> Michael J. Erickson, Ph.D
> Cooperative Institute for Research in Environmental Sciences (CIRES)
> CIRES Contractor for the Weather Prediction Center (WPC)
>
> Phone: 301-683-1546
>
>
------------------------------------------------
Subject: Using regrid_data_plane to Read in Poorly Constructed Grib2
From: Michael Erickson - NOAA Affiliate
Time: Tue Jun 13 11:04:33 2017
Hi Julie,
Thank you for your quick response. Unfortunately my linux machine does
not
have the ftp command, and the command "sftp ftp.rap.ucar.edu" does not
work.
Would I be able to email you the file? It is about 780 KB.
Thanks again!
Mike
On Tue, Jun 13, 2017 at 5:01 PM, Julie Prestopnik via RT
<met_help at ucar.edu>
wrote:
> Hi Mike. I see that you are having trouble processing a grib file
with
> regrid_data_plane. Thank you for sending the command you would like
to
> use.
>
> Could you please send me the grib2 file that you are trying to
process?
> You can post it to our anonymous ftp site following these
instructions:
> http://www.dtcenter.org/met/users/support/met_help.php#ftp
>
> Please write back once you've posted it, and I'll go grab it.
>
> Thanks!
>
> Julie
>
> On Tue, Jun 13, 2017 at 10:47 AM, Michael Erickson - NOAA Affiliate
via RT
> <
> met_help at ucar.edu> wrote:
>
> >
> > Tue Jun 13 10:47:36 2017: Request 80847 was acted upon.
> > Transaction: Ticket created by michael.j.erickson at noaa.gov
> > Queue: met_help
> > Subject: Using regrid_data_plane to Read in Poorly
Constructed Grib2
> > Owner: Nobody
> > Requestors: michael.j.erickson at noaa.gov
> > Status: new
> > Ticket <URL:
https://rt.rap.ucar.edu/rt/Ticket/Display.html?id=80847 >
> >
> >
> > Hello,
> >
> > I apologize if this is a simple fix, but I am trying to read in a
grib2
> > file using regrid_data_plane where most of the field metadata is
> > unspecified. There is only one field for each grib2 file, so all I
have
> to
> > do is read in the first and only field.
> >
> > An example of the metadata is shown below:
> >
> >
> >
> >
> >
> >
> >
> > *wgrib2 -V
> > 2017060212_acc01_ffg.grib21:0:vt=0017060212:surface:missing,
> missing=0:var
> > discipline=112 center=7 local_table=1 parmcat=1 parm=194:
> > ndata=859108:undef=384946:mean=49.4947:min=5.02:max=212.24
> > grid_template=20:winds(grid): polar stereographic grid: (1082 x
794)
> > input WE:SN output WE:SN res 56 North pole lat1 24.298999 lon1
> > 240.705001 latD 60.000000 lonV 255.000000 dx 4762.453000 m dy
4762.443000
> > m*
> > And my command to read in the file and interpolate it to a 0.1
degree
> > lat/lon grid is:
> >
> > */opt/MET6/met6.0/bin/regrid_data_plane
> > /usr1/wpc_cpgffh/gribs/temp/ERO_20170603/2017060212
> <%28201%29%20706-0212>
> > _acc01_ffg.grib2 'latlon
> > 701 301 20 -130 0.1 0.1'
> >
/usr1/wpc_cpgffh/gribs/temp/ERO_20170603/2017060212_acc01_ffg.grib2.nc
> > <http://2017060212_acc01_ffg.grib2.nc> -field 'name="???";
> > level="(*,*)";'*
> >
> > where I don't know the name or field name. Thanks!
> >
> > Mike
> >
> > --
> >
> > Michael J. Erickson, Ph.D
> > Cooperative Institute for Research in Environmental Sciences
(CIRES)
> > CIRES Contractor for the Weather Prediction Center (WPC)
> >
> > Phone: 301-683-1546
> >
> >
>
>
--
Michael J. Erickson, Ph.D
Cooperative Institute for Research in Environmental Sciences (CIRES)
CIRES Contractor for the Weather Prediction Center (WPC)
Phone: 301-683-1546
------------------------------------------------
Subject: Using regrid_data_plane to Read in Poorly Constructed Grib2
From: Julie Prestopnik
Time: Tue Jun 13 11:07:32 2017
Yes, please try to email the file. Thanks!
Julie
On Tue, Jun 13, 2017 at 11:04 AM, Michael Erickson - NOAA Affiliate
via RT <
met_help at ucar.edu> wrote:
>
> <URL: https://rt.rap.ucar.edu/rt/Ticket/Display.html?id=80847 >
>
> Hi Julie,
>
> Thank you for your quick response. Unfortunately my linux machine
does not
> have the ftp command, and the command "sftp ftp.rap.ucar.edu" does
not
> work.
>
> Would I be able to email you the file? It is about 780 KB.
>
> Thanks again!
>
> Mike
>
> On Tue, Jun 13, 2017 at 5:01 PM, Julie Prestopnik via RT <
> met_help at ucar.edu>
> wrote:
>
> > Hi Mike. I see that you are having trouble processing a grib file
with
> > regrid_data_plane. Thank you for sending the command you would
like to
> > use.
> >
> > Could you please send me the grib2 file that you are trying to
process?
> > You can post it to our anonymous ftp site following these
instructions:
> > http://www.dtcenter.org/met/users/support/met_help.php#ftp
> >
> > Please write back once you've posted it, and I'll go grab it.
> >
> > Thanks!
> >
> > Julie
> >
> > On Tue, Jun 13, 2017 at 10:47 AM, Michael Erickson - NOAA
Affiliate via
> RT
> > <
> > met_help at ucar.edu> wrote:
> >
> > >
> > > Tue Jun 13 10:47:36 2017: Request 80847 was acted upon.
> > > Transaction: Ticket created by michael.j.erickson at noaa.gov
> > > Queue: met_help
> > > Subject: Using regrid_data_plane to Read in Poorly
Constructed
> Grib2
> > > Owner: Nobody
> > > Requestors: michael.j.erickson at noaa.gov
> > > Status: new
> > > Ticket <URL:
https://rt.rap.ucar.edu/rt/Ticket/Display.html?id=80847
> >
> > >
> > >
> > > Hello,
> > >
> > > I apologize if this is a simple fix, but I am trying to read in
a grib2
> > > file using regrid_data_plane where most of the field metadata is
> > > unspecified. There is only one field for each grib2 file, so all
I have
> > to
> > > do is read in the first and only field.
> > >
> > > An example of the metadata is shown below:
> > >
> > >
> > >
> > >
> > >
> > >
> > >
> > > *wgrib2 -V
> > > 2017060212_acc01_ffg.grib21:0:vt=0017060212:surface:missing,
> > missing=0:var
> > > discipline=112 center=7 local_table=1 parmcat=1 parm=194:
> > > ndata=859108:undef=384946:mean=49.4947:min=5.02:max=212.24
> > > grid_template=20:winds(grid): polar stereographic grid: (1082
x 794)
> > > input WE:SN output WE:SN res 56 North pole lat1 24.298999
lon1
> > > 240.705001 latD 60.000000 lonV 255.000000 dx 4762.453000 m dy
> 4762.443000
> > > m*
> > > And my command to read in the file and interpolate it to a 0.1
degree
> > > lat/lon grid is:
> > >
> > > */opt/MET6/met6.0/bin/regrid_data_plane
> > > /usr1/wpc_cpgffh/gribs/temp/ERO_20170603/2017060212
> > <%28201%29%20706-0212>
> > > _acc01_ffg.grib2 'latlon
> > > 701 301 20 -130 0.1 0.1'
> > >
/usr1/wpc_cpgffh/gribs/temp/ERO_20170603/2017060212_acc01_ffg.grib2.nc
> > > <http://2017060212_acc01_ffg.grib2.nc> -field 'name="???";
> > > level="(*,*)";'*
> > >
> > > where I don't know the name or field name. Thanks!
> > >
> > > Mike
> > >
> > > --
> > >
> > > Michael J. Erickson, Ph.D
> > > Cooperative Institute for Research in Environmental Sciences
(CIRES)
> > > CIRES Contractor for the Weather Prediction Center (WPC)
> > >
> > > Phone: 301-683-1546
> > >
> > >
> >
> >
>
>
> --
>
> Michael J. Erickson, Ph.D
> Cooperative Institute for Research in Environmental Sciences (CIRES)
> CIRES Contractor for the Weather Prediction Center (WPC)
>
> Phone: 301-683-1546
>
>
------------------------------------------------
Subject: Using regrid_data_plane to Read in Poorly Constructed Grib2
From: Michael Erickson - NOAA Affiliate
Time: Tue Jun 13 11:09:54 2017
Thanks Julie,
It is attached.
Mike
On Tue, Jun 13, 2017 at 5:07 PM, Julie Prestopnik via RT
<met_help at ucar.edu>
wrote:
> Yes, please try to email the file. Thanks!
>
> Julie
>
> On Tue, Jun 13, 2017 at 11:04 AM, Michael Erickson - NOAA Affiliate
via RT
> <
> met_help at ucar.edu> wrote:
>
> >
> > <URL: https://rt.rap.ucar.edu/rt/Ticket/Display.html?id=80847 >
> >
> > Hi Julie,
> >
> > Thank you for your quick response. Unfortunately my linux machine
does
> not
> > have the ftp command, and the command "sftp ftp.rap.ucar.edu" does
not
> > work.
> >
> > Would I be able to email you the file? It is about 780 KB.
> >
> > Thanks again!
> >
> > Mike
> >
> > On Tue, Jun 13, 2017 at 5:01 PM, Julie Prestopnik via RT <
> > met_help at ucar.edu>
> > wrote:
> >
> > > Hi Mike. I see that you are having trouble processing a grib
file with
> > > regrid_data_plane. Thank you for sending the command you would
like to
> > > use.
> > >
> > > Could you please send me the grib2 file that you are trying to
process?
> > > You can post it to our anonymous ftp site following these
instructions:
> > > http://www.dtcenter.org/met/users/support/met_help.php#ftp
> > >
> > > Please write back once you've posted it, and I'll go grab it.
> > >
> > > Thanks!
> > >
> > > Julie
> > >
> > > On Tue, Jun 13, 2017 at 10:47 AM, Michael Erickson - NOAA
Affiliate via
> > RT
> > > <
> > > met_help at ucar.edu> wrote:
> > >
> > > >
> > > > Tue Jun 13 10:47:36 2017: Request 80847 was acted upon.
> > > > Transaction: Ticket created by michael.j.erickson at noaa.gov
> > > > Queue: met_help
> > > > Subject: Using regrid_data_plane to Read in Poorly
Constructed
> > Grib2
> > > > Owner: Nobody
> > > > Requestors: michael.j.erickson at noaa.gov
> > > > Status: new
> > > > Ticket <URL: https://rt.rap.ucar.edu/rt/
> Ticket/Display.html?id=80847
> > >
> > > >
> > > >
> > > > Hello,
> > > >
> > > > I apologize if this is a simple fix, but I am trying to read
in a
> grib2
> > > > file using regrid_data_plane where most of the field metadata
is
> > > > unspecified. There is only one field for each grib2 file, so
all I
> have
> > > to
> > > > do is read in the first and only field.
> > > >
> > > > An example of the metadata is shown below:
> > > >
> > > >
> > > >
> > > >
> > > >
> > > >
> > > >
> > > > *wgrib2 -V
> > > > 2017060212_acc01_ffg.grib21:0:vt=0017060212:surface:missing,
> > > missing=0:var
> > > > discipline=112 center=7 local_table=1 parmcat=1 parm=194:
> > > > ndata=859108:undef=384946:mean=49.4947:min=5.02:max=212.24
> > > > grid_template=20:winds(grid): polar stereographic grid:
(1082 x
> 794)
> > > > input WE:SN output WE:SN res 56 North pole lat1 24.298999
lon1
> > > > 240.705001 latD 60.000000 lonV 255.000000 dx 4762.453000 m dy
> > 4762.443000
> > > > m*
> > > > And my command to read in the file and interpolate it to a 0.1
degree
> > > > lat/lon grid is:
> > > >
> > > > */opt/MET6/met6.0/bin/regrid_data_plane
> > > > /usr1/wpc_cpgffh/gribs/temp/ERO_20170603/2017060212
> > > <%28201%29%20706-0212>
> > > > _acc01_ffg.grib2 'latlon
> > > > 701 301 20 -130 0.1 0.1'
> > > > /usr1/wpc_cpgffh/gribs/temp/ERO_20170603/2017060212_acc01_
> ffg.grib2.nc
> > > > <http://2017060212_acc01_ffg.grib2.nc> -field 'name="???";
> > > > level="(*,*)";'*
> > > >
> > > > where I don't know the name or field name. Thanks!
> > > >
> > > > Mike
> > > >
> > > > --
> > > >
> > > > Michael J. Erickson, Ph.D
> > > > Cooperative Institute for Research in Environmental Sciences
(CIRES)
> > > > CIRES Contractor for the Weather Prediction Center (WPC)
> > > >
> > > > Phone: 301-683-1546
> > > >
> > > >
> > >
> > >
> >
> >
> > --
> >
> > Michael J. Erickson, Ph.D
> > Cooperative Institute for Research in Environmental Sciences
(CIRES)
> > CIRES Contractor for the Weather Prediction Center (WPC)
> >
> > Phone: 301-683-1546
> >
> >
>
>
--
Michael J. Erickson, Ph.D
Cooperative Institute for Research in Environmental Sciences (CIRES)
CIRES Contractor for the Weather Prediction Center (WPC)
Phone: 301-683-1546
------------------------------------------------
Subject: Using regrid_data_plane to Read in Poorly Constructed Grib2
From: Julie Prestopnik
Time: Tue Jun 13 14:32:50 2017
Hi Mike.
First, you can run regrid_data_plane by giving a level of "R1"
(telling MET
to use the first record), using a name of any name that would be in a
grib
table. For example, running:
/usr/local/met-6.0/bin/regrid_data_plane 2017060212_acc01_ffg.grib2
'latlon
701 301 20 -130 0.1 0.1' 2017060212_acc01_ffg.nc -field 'name="APCP";
level="R1";'
will successfully create an output NetCDF file.
If you would like to name your field you can use a grib table file
that you
create yourself. For example, I have attached grib2_custom.txt. The
contents of this file is simply:
GRIB2
112 2 0 255 7 1 1 194 "MYDATA" "Testing Custom GRIB Table" "NA"
In order to use this file you would set the environment variable
MET_GRIB_TABLES to the full path and filename where grib2_custom.txt
is
located. For example:
setenv MET_GRIB_TABLES /home/jpresto/grib2_custom.txt
Then, if you run:
/usr/local/met-6.0/bin/regrid_data_plane 2017060212_acc01_ffg.grib2
'latlon
701 301 20 -130 0.1 0.1' 2017060212_acc01_ffg.nc -field
'name="MYDATA";
level="R1";'
You'd see the variable MYDATA_R1 in the output NetCDF file. The use
of
MET_GRIB_TABLES is described on page 47 of the MET User's Guide:
http://www.dtcenter.org/met/users/docs/users_guide/MET_Users_Guide_v6.0.pdf
Something to note - when I ran regrid_data_plane I received the
following
warning:
WARNING: MetGrib2DataFile::read_grib2_grid() -> MET does not currently
support Polar Stereographic grids where dx (4.76245) != dy (4.76244)
and
may produce unexpected results!
dx and dy are expected to be equal. They are very similar, but please
know
unexpected results could be produced.
More importantly, by running "wgrib2 -V 2017060212_acc01_ffg.grib2", I
see
a problem with the valid time (vt):
1:0:vt=0017060212:surface:CodeTable 4.11=missing,missing=0:var
discipline=112 center=7 local_table=1 parmcat=1 parm=194:
ndata=859108:undef=384946:mean=49.4947:min=5.02:max=212.24
grid_template=20:winds(grid):
polar stereographic grid: (1082 x 794) input WE:SN output
WE:SN res
56
North pole lat1 24.298999 lon1 240.705001 latD 60.000000 lonV
255.000000 dx 4762.453000 m dy 4762.443000 m
Note that the value is "0017060212", but it should be "2017060212".
MET
has a problem with this and in our resulting NetCDF file you'll see
that
the init time is correct, but the valid time is not:
MYDATA_R1:init_time = "20170601_120000" ;
MYDATA_R1:init_time_ut = "1496318400" ;
MYDATA_R1:valid_time = "00170602_120000" ;
MYDATA_R1:valid_time_ut = "-61617499200" ;
So, MET is getting a bad valid time because something is encoded
incorrectly in this GRIB2 file.
I hope this helps!
Julie
On Tue, Jun 13, 2017 at 11:09 AM, Michael Erickson - NOAA Affiliate
via RT <
met_help at ucar.edu> wrote:
>
> <URL: https://rt.rap.ucar.edu/rt/Ticket/Display.html?id=80847 >
>
> Thanks Julie,
>
> It is attached.
>
> Mike
>
> On Tue, Jun 13, 2017 at 5:07 PM, Julie Prestopnik via RT <
> met_help at ucar.edu>
> wrote:
>
> > Yes, please try to email the file. Thanks!
> >
> > Julie
> >
> > On Tue, Jun 13, 2017 at 11:04 AM, Michael Erickson - NOAA
Affiliate via
> RT
> > <
> > met_help at ucar.edu> wrote:
> >
> > >
> > > <URL: https://rt.rap.ucar.edu/rt/Ticket/Display.html?id=80847 >
> > >
> > > Hi Julie,
> > >
> > > Thank you for your quick response. Unfortunately my linux
machine does
> > not
> > > have the ftp command, and the command "sftp ftp.rap.ucar.edu"
does not
> > > work.
> > >
> > > Would I be able to email you the file? It is about 780 KB.
> > >
> > > Thanks again!
> > >
> > > Mike
> > >
> > > On Tue, Jun 13, 2017 at 5:01 PM, Julie Prestopnik via RT <
> > > met_help at ucar.edu>
> > > wrote:
> > >
> > > > Hi Mike. I see that you are having trouble processing a grib
file
> with
> > > > regrid_data_plane. Thank you for sending the command you
would like
> to
> > > > use.
> > > >
> > > > Could you please send me the grib2 file that you are trying to
> process?
> > > > You can post it to our anonymous ftp site following these
> instructions:
> > > > http://www.dtcenter.org/met/users/support/met_help.php#ftp
> > > >
> > > > Please write back once you've posted it, and I'll go grab it.
> > > >
> > > > Thanks!
> > > >
> > > > Julie
> > > >
> > > > On Tue, Jun 13, 2017 at 10:47 AM, Michael Erickson - NOAA
Affiliate
> via
> > > RT
> > > > <
> > > > met_help at ucar.edu> wrote:
> > > >
> > > > >
> > > > > Tue Jun 13 10:47:36 2017: Request 80847 was acted upon.
> > > > > Transaction: Ticket created by michael.j.erickson at noaa.gov
> > > > > Queue: met_help
> > > > > Subject: Using regrid_data_plane to Read in Poorly
Constructed
> > > Grib2
> > > > > Owner: Nobody
> > > > > Requestors: michael.j.erickson at noaa.gov
> > > > > Status: new
> > > > > Ticket <URL: https://rt.rap.ucar.edu/rt/
> > Ticket/Display.html?id=80847
> > > >
> > > > >
> > > > >
> > > > > Hello,
> > > > >
> > > > > I apologize if this is a simple fix, but I am trying to read
in a
> > grib2
> > > > > file using regrid_data_plane where most of the field
metadata is
> > > > > unspecified. There is only one field for each grib2 file, so
all I
> > have
> > > > to
> > > > > do is read in the first and only field.
> > > > >
> > > > > An example of the metadata is shown below:
> > > > >
> > > > >
> > > > >
> > > > >
> > > > >
> > > > >
> > > > >
> > > > > *wgrib2 -V
> > > > > 2017060212_acc01_ffg.grib21:0:vt=0017060212:surface:missing,
> > > > missing=0:var
> > > > > discipline=112 center=7 local_table=1 parmcat=1 parm=194:
> > > > > ndata=859108:undef=384946:mean=49.4947:min=5.02:max=212.24
> > > > > grid_template=20:winds(grid): polar stereographic grid:
(1082 x
> > 794)
> > > > > input WE:SN output WE:SN res 56 North pole lat1 24.298999
lon1
> > > > > 240.705001 latD 60.000000 lonV 255.000000 dx 4762.453000 m
dy
> > > 4762.443000
> > > > > m*
> > > > > And my command to read in the file and interpolate it to a
0.1
> degree
> > > > > lat/lon grid is:
> > > > >
> > > > > */opt/MET6/met6.0/bin/regrid_data_plane
> > > > > /usr1/wpc_cpgffh/gribs/temp/ERO_20170603/2017060212
> > > > <%28201%29%20706-0212>
> > > > > _acc01_ffg.grib2 'latlon
> > > > > 701 301 20 -130 0.1 0.1'
> > > > > /usr1/wpc_cpgffh/gribs/temp/ERO_20170603/2017060212_acc01_
> > ffg.grib2.nc
> > > > > <http://2017060212_acc01_ffg.grib2.nc> -field 'name="???";
> > > > > level="(*,*)";'*
> > > > >
> > > > > where I don't know the name or field name. Thanks!
> > > > >
> > > > > Mike
> > > > >
> > > > > --
> > > > >
> > > > > Michael J. Erickson, Ph.D
> > > > > Cooperative Institute for Research in Environmental Sciences
> (CIRES)
> > > > > CIRES Contractor for the Weather Prediction Center (WPC)
> > > > >
> > > > > Phone: 301-683-1546
> > > > >
> > > > >
> > > >
> > > >
> > >
> > >
> > > --
> > >
> > > Michael J. Erickson, Ph.D
> > > Cooperative Institute for Research in Environmental Sciences
(CIRES)
> > > CIRES Contractor for the Weather Prediction Center (WPC)
> > >
> > > Phone: 301-683-1546
> > >
> > >
> >
> >
>
>
> --
>
> Michael J. Erickson, Ph.D
> Cooperative Institute for Research in Environmental Sciences (CIRES)
> CIRES Contractor for the Weather Prediction Center (WPC)
>
> Phone: 301-683-1546
>
>
------------------------------------------------
Subject: Using regrid_data_plane to Read in Poorly Constructed Grib2
From: Julie Prestopnik
Time: Tue Jun 13 14:32:50 2017
GRIB2
112 2 0 255 7 1 1 194 "MYDATA" "Testing Custom GRIB Table" "NA"
------------------------------------------------
Subject: Using regrid_data_plane to Read in Poorly Constructed Grib2
From: Michael Erickson - NOAA Affiliate
Time: Wed Jun 14 06:37:52 2017
Hi Julie,
Thank you for your helpful response. These grib2 files were converted
(by
me) in haste from GEMPAK, so I'm not surprised about the bad date
stamp and
other metadata. I'll probably need to revisit that again. Your
suggestion
works great! Thank you!
Mike
On Tue, Jun 13, 2017 at 8:32 PM, Julie Prestopnik via RT
<met_help at ucar.edu>
wrote:
> Hi Mike.
>
> First, you can run regrid_data_plane by giving a level of "R1"
(telling MET
> to use the first record), using a name of any name that would be in
a grib
> table. For example, running:
>
> /usr/local/met-6.0/bin/regrid_data_plane 2017060212_acc01_ffg.grib2
> 'latlon
> 701 301 20 -130 0.1 0.1' 2017060212_acc01_ffg.nc -field
'name="APCP";
> level="R1";'
>
> will successfully create an output NetCDF file.
>
>
> If you would like to name your field you can use a grib table file
that you
> create yourself. For example, I have attached grib2_custom.txt.
The
> contents of this file is simply:
>
> GRIB2
> 112 2 0 255 7 1 1 194 "MYDATA" "Testing Custom GRIB Table" "NA"
>
> In order to use this file you would set the environment variable
> MET_GRIB_TABLES to the full path and filename where grib2_custom.txt
is
> located. For example:
>
> setenv MET_GRIB_TABLES /home/jpresto/grib2_custom.txt
>
> Then, if you run:
>
> /usr/local/met-6.0/bin/regrid_data_plane 2017060212_acc01_ffg.grib2
> 'latlon
> 701 301 20 -130 0.1 0.1' 2017060212_acc01_ffg.nc -field
'name="MYDATA";
> level="R1";'
>
> You'd see the variable MYDATA_R1 in the output NetCDF file. The use
of
> MET_GRIB_TABLES is described on page 47 of the MET User's Guide:
>
> http://www.dtcenter.org/met/users/docs/users_guide/MET_
> Users_Guide_v6.0.pdf
>
>
> Something to note - when I ran regrid_data_plane I received the
following
> warning:
>
> WARNING: MetGrib2DataFile::read_grib2_grid() -> MET does not
currently
> support Polar Stereographic grids where dx (4.76245) != dy (4.76244)
and
> may produce unexpected results!
>
> dx and dy are expected to be equal. They are very similar, but
please know
> unexpected results could be produced.
>
>
> More importantly, by running "wgrib2 -V 2017060212_acc01_ffg.grib2",
I see
> a problem with the valid time (vt):
>
> 1:0:vt=0017060212:surface:CodeTable 4.11=missing,missing=0:var
> discipline=112 center=7 local_table=1 parmcat=1 parm=194:
> ndata=859108:undef=384946:mean=49.4947:min=5.02:max=212.24
> grid_template=20:winds(grid):
> polar stereographic grid: (1082 x 794) input WE:SN output
WE:SN res
> 56
> North pole lat1 24.298999 lon1 240.705001 latD 60.000000
lonV
> 255.000000 dx 4762.453000 m dy 4762.443000 m
>
> Note that the value is "0017060212", but it should be "2017060212".
MET
> has a problem with this and in our resulting NetCDF file you'll see
that
> the init time is correct, but the valid time is not:
>
> MYDATA_R1:init_time = "20170601_120000" ;
> MYDATA_R1:init_time_ut = "1496318400" ;
> MYDATA_R1:valid_time = "00170602_120000" ;
> MYDATA_R1:valid_time_ut = "-61617499200" ;
>
> So, MET is getting a bad valid time because something is encoded
> incorrectly in this GRIB2 file.
>
>
> I hope this helps!
>
> Julie
>
>
>
>
>
>
>
> On Tue, Jun 13, 2017 at 11:09 AM, Michael Erickson - NOAA Affiliate
via RT
> <
> met_help at ucar.edu> wrote:
>
> >
> > <URL: https://rt.rap.ucar.edu/rt/Ticket/Display.html?id=80847 >
> >
> > Thanks Julie,
> >
> > It is attached.
> >
> > Mike
> >
> > On Tue, Jun 13, 2017 at 5:07 PM, Julie Prestopnik via RT <
> > met_help at ucar.edu>
> > wrote:
> >
> > > Yes, please try to email the file. Thanks!
> > >
> > > Julie
> > >
> > > On Tue, Jun 13, 2017 at 11:04 AM, Michael Erickson - NOAA
Affiliate via
> > RT
> > > <
> > > met_help at ucar.edu> wrote:
> > >
> > > >
> > > > <URL: https://rt.rap.ucar.edu/rt/Ticket/Display.html?id=80847
>
> > > >
> > > > Hi Julie,
> > > >
> > > > Thank you for your quick response. Unfortunately my linux
machine
> does
> > > not
> > > > have the ftp command, and the command "sftp ftp.rap.ucar.edu"
does
> not
> > > > work.
> > > >
> > > > Would I be able to email you the file? It is about 780 KB.
> > > >
> > > > Thanks again!
> > > >
> > > > Mike
> > > >
> > > > On Tue, Jun 13, 2017 at 5:01 PM, Julie Prestopnik via RT <
> > > > met_help at ucar.edu>
> > > > wrote:
> > > >
> > > > > Hi Mike. I see that you are having trouble processing a
grib file
> > with
> > > > > regrid_data_plane. Thank you for sending the command you
would
> like
> > to
> > > > > use.
> > > > >
> > > > > Could you please send me the grib2 file that you are trying
to
> > process?
> > > > > You can post it to our anonymous ftp site following these
> > instructions:
> > > > >
http://www.dtcenter.org/met/users/support/met_help.php#ftp
> > > > >
> > > > > Please write back once you've posted it, and I'll go grab
it.
> > > > >
> > > > > Thanks!
> > > > >
> > > > > Julie
> > > > >
> > > > > On Tue, Jun 13, 2017 at 10:47 AM, Michael Erickson - NOAA
Affiliate
> > via
> > > > RT
> > > > > <
> > > > > met_help at ucar.edu> wrote:
> > > > >
> > > > > >
> > > > > > Tue Jun 13 10:47:36 2017: Request 80847 was acted upon.
> > > > > > Transaction: Ticket created by michael.j.erickson at noaa.gov
> > > > > > Queue: met_help
> > > > > > Subject: Using regrid_data_plane to Read in Poorly
> Constructed
> > > > Grib2
> > > > > > Owner: Nobody
> > > > > > Requestors: michael.j.erickson at noaa.gov
> > > > > > Status: new
> > > > > > Ticket <URL: https://rt.rap.ucar.edu/rt/
> > > Ticket/Display.html?id=80847
> > > > >
> > > > > >
> > > > > >
> > > > > > Hello,
> > > > > >
> > > > > > I apologize if this is a simple fix, but I am trying to
read in a
> > > grib2
> > > > > > file using regrid_data_plane where most of the field
metadata is
> > > > > > unspecified. There is only one field for each grib2 file,
so all
> I
> > > have
> > > > > to
> > > > > > do is read in the first and only field.
> > > > > >
> > > > > > An example of the metadata is shown below:
> > > > > >
> > > > > >
> > > > > >
> > > > > >
> > > > > >
> > > > > >
> > > > > >
> > > > > > *wgrib2 -V
> > > > > >
2017060212_acc01_ffg.grib21:0:vt=0017060212:surface:missing,
> > > > > missing=0:var
> > > > > > discipline=112 center=7 local_table=1 parmcat=1 parm=194:
> > > > > > ndata=859108:undef=384946:mean=49.4947:min=5.02:max=212.24
> > > > > > grid_template=20:winds(grid): polar stereographic grid:
(1082
> x
> > > 794)
> > > > > > input WE:SN output WE:SN res 56 North pole lat1
24.298999 lon1
> > > > > > 240.705001 latD 60.000000 lonV 255.000000 dx 4762.453000 m
dy
> > > > 4762.443000
> > > > > > m*
> > > > > > And my command to read in the file and interpolate it to a
0.1
> > degree
> > > > > > lat/lon grid is:
> > > > > >
> > > > > > */opt/MET6/met6.0/bin/regrid_data_plane
> > > > > > /usr1/wpc_cpgffh/gribs/temp/ERO_20170603/2017060212
> > > > > <%28201%29%20706-0212>
> > > > > > _acc01_ffg.grib2 'latlon
> > > > > > 701 301 20 -130 0.1 0.1'
> > > > > > /usr1/wpc_cpgffh/gribs/temp/ERO_20170603/2017060212_acc01_
> > > ffg.grib2.nc
> > > > > > <http://2017060212_acc01_ffg.grib2.nc> -field 'name="???";
> > > > > > level="(*,*)";'*
> > > > > >
> > > > > > where I don't know the name or field name. Thanks!
> > > > > >
> > > > > > Mike
> > > > > >
> > > > > > --
> > > > > >
> > > > > > Michael J. Erickson, Ph.D
> > > > > > Cooperative Institute for Research in Environmental
Sciences
> > (CIRES)
> > > > > > CIRES Contractor for the Weather Prediction Center (WPC)
> > > > > >
> > > > > > Phone: 301-683-1546
> > > > > >
> > > > > >
> > > > >
> > > > >
> > > >
> > > >
> > > > --
> > > >
> > > > Michael J. Erickson, Ph.D
> > > > Cooperative Institute for Research in Environmental Sciences
(CIRES)
> > > > CIRES Contractor for the Weather Prediction Center (WPC)
> > > >
> > > > Phone: 301-683-1546
> > > >
> > > >
> > >
> > >
> >
> >
> > --
> >
> > Michael J. Erickson, Ph.D
> > Cooperative Institute for Research in Environmental Sciences
(CIRES)
> > CIRES Contractor for the Weather Prediction Center (WPC)
> >
> > Phone: 301-683-1546
> >
> >
>
>
--
Michael J. Erickson, Ph.D
Cooperative Institute for Research in Environmental Sciences (CIRES)
CIRES Contractor for the Weather Prediction Center (WPC)
Phone: 301-683-1546
------------------------------------------------
More information about the Met_help
mailing list