[Met_help] [rt.rap.ucar.edu #90526] History for MET input NetCDF file error
John Halley Gotway via RT
met_help at ucar.edu
Tue Jul 2 08:57:35 MDT 2019
----------------------------------------------------------------
Initial Request
----------------------------------------------------------------
Dear Colleague,
I am trying to use MET’s “grid_stat” tool to evaluate a 2-D model simulation against observation. However I ran into the error below.
DEBUG 1: Default Config File: /usr/local/share/met/config/GridStatConfig_default
DEBUG 1: User Config File: /met/met-8.1/tutorial/MET_Tutorial//config/GridStatConfig_APCP_12
DEBUG 4: Met2dDataFileFactory::new_met_2d_data_file() -> created new Met2dDataFile object of type "FileType_None".
ERROR :
ERROR : Trouble reading forecast file "/met/met-8.1/tutorial/MET_Tutorial/input/bao_data/fv3_model_output.nc"
ERROR :
I have attached the 2 NetCDF files here. I ran a NetCDF file checker (http://cfconventions.org/compliance-checker.html) and it appears these 2 files are both CF-compliant.
I wonder if you could please help with this issue?
Thanks,
Shaowu
----------------------------------------------------------------
Complete Ticket History
----------------------------------------------------------------
Subject: MET input NetCDF file error
From: John Halley Gotway
Time: Mon Jun 10 12:08:32 2019
Shaowu,
I see you're having trouble using some NetCDF files in MET. Whenever
starting with a new gridded dataset, I always recommend running MET's
plot_data_plane tool to make a quick plot of the data. That ensures
that
MET can read the data and interpret the metadata correctly. I get a
similar error from plot_data_plane:
*met-8.1/bin/plot_data_plane fv3_model_output.nc
<http://fv3_model_output.nc> fv3_model_output.ps
<http://fv3_model_output.ps> 'name="model"; level="(*,*)";'*
*ERROR : plot_data_plane -> file "fv3_model_output.nc
<http://fv3_model_output.nc>" not a valid data file*
Looking in your file, I see that it lacks the global "Conventions"
attribute which MET expects to see in CF-compliant NetCDF files. You
can
tell MET explicitly to interpret this data as being CF-compliant by
setting
"file_type=NETCDF_NCCF;"
*met-8.1/bin/plot_data_plane fv3_model_output.nc
<http://fv3_model_output.nc> fv3_model_output.ps
<http://fv3_model_output.ps> 'name="model"; level="(*,*)";
file_type=NETCDF_NCCF;'*
Or you could simply add the "Conventions" attribute and you wouldn't
need
to use the "file_type" option.
*ncatted -a Conventions,global,a,c,CF-1.7 fv3_model_output.nc
<http://fv3_model_output.nc> fv3_model_output_MOD.nc*
*met-8.1/bin/plot_data_plane fv3_model_output_MOD.nc
fv3_model_output_MOD.ps 'name="model";
level="(*,*)";'*
WARNING: NcCfFile::open() -> could not determine the valid time, using
0.
I've attached the resulting image. Does that data look right to you?
As you can see, there is no timing information in these NetCDF files,
so
MET prints a warning about that.
Hope that helps get you going.
Thanks,
John Halley Gotway
On Sun, Jun 9, 2019 at 2:00 PM sbao at coastal.edu via RT
<met_help at ucar.edu>
wrote:
>
> Sun Jun 09 14:00:44 2019: Request 90526 was acted upon.
> Transaction: Ticket created by sbao at coastal.edu
> Queue: met_help
> Subject: MET input NetCDF file error
> Owner: Nobody
> Requestors: sbao at coastal.edu
> Status: new
> Ticket <URL:
https://rt.rap.ucar.edu/rt/Ticket/Display.html?id=90526 >
>
>
> Dear Colleague,
>
> I am trying to use MET’s “grid_stat” tool to evaluate a 2-D model
> simulation against observation. However I ran into the error below.
>
> DEBUG 1: Default Config File:
> /usr/local/share/met/config/GridStatConfig_default
> DEBUG 1: User Config File:
> /met/met-8.1/tutorial/MET_Tutorial//config/GridStatConfig_APCP_12
> DEBUG 4: Met2dDataFileFactory::new_met_2d_data_file() -> created new
> Met2dDataFile object of type "FileType_None".
> ERROR :
> ERROR : Trouble reading forecast file
> "/met/met-
8.1/tutorial/MET_Tutorial/input/bao_data/fv3_model_output.nc"
> ERROR :
>
> I have attached the 2 NetCDF files here. I ran a NetCDF file checker
(
> http://cfconventions.org/compliance-checker.html) and it appears
these 2
> files are both CF-compliant.
> I wonder if you could please help with this issue?
>
> Thanks,
> Shaowu
>
>
>
------------------------------------------------
Subject: Re: [rt.rap.ucar.edu #90526] MET input NetCDF file error
From: sbao at coastal.edu
Time: Mon Jun 10 12:54:09 2019
John,
We followed your suggestion by adding the attribute using ncatted, and
it worked perfectly! Thank you so much for your quick response.
Best,
Shaowu
On 6/10/19, 2:09 PM, "John Halley Gotway via RT" <met_help at ucar.edu>
wrote:
Shaowu,
I see you're having trouble using some NetCDF files in MET.
Whenever
starting with a new gridded dataset, I always recommend running
MET's
plot_data_plane tool to make a quick plot of the data. That
ensures that
MET can read the data and interpret the metadata correctly. I get
a
similar error from plot_data_plane:
*met-8.1/bin/plot_data_plane fv3_model_output.nc
<http://fv3_model_output.nc> fv3_model_output.ps
<http://fv3_model_output.ps> 'name="model"; level="(*,*)";'*
*ERROR : plot_data_plane -> file "fv3_model_output.nc
<http://fv3_model_output.nc>" not a valid data file*
Looking in your file, I see that it lacks the global "Conventions"
attribute which MET expects to see in CF-compliant NetCDF files.
You can
tell MET explicitly to interpret this data as being CF-compliant
by setting
"file_type=NETCDF_NCCF;"
*met-8.1/bin/plot_data_plane fv3_model_output.nc
<http://fv3_model_output.nc> fv3_model_output.ps
<http://fv3_model_output.ps> 'name="model"; level="(*,*)";
file_type=NETCDF_NCCF;'*
Or you could simply add the "Conventions" attribute and you
wouldn't need
to use the "file_type" option.
*ncatted -a Conventions,global,a,c,CF-1.7 fv3_model_output.nc
<http://fv3_model_output.nc> fv3_model_output_MOD.nc*
*met-8.1/bin/plot_data_plane fv3_model_output_MOD.nc
fv3_model_output_MOD.ps 'name="model";
level="(*,*)";'*
WARNING: NcCfFile::open() -> could not determine the valid time,
using 0.
I've attached the resulting image. Does that data look right to
you?
As you can see, there is no timing information in these NetCDF
files, so
MET prints a warning about that.
Hope that helps get you going.
Thanks,
John Halley Gotway
On Sun, Jun 9, 2019 at 2:00 PM sbao at coastal.edu via RT
<met_help at ucar.edu>
wrote:
>
> Sun Jun 09 14:00:44 2019: Request 90526 was acted upon.
> Transaction: Ticket created by sbao at coastal.edu
> Queue: met_help
> Subject: MET input NetCDF file error
> Owner: Nobody
> Requestors: sbao at coastal.edu
> Status: new
> Ticket <URL:
https://nam03.safelinks.protection.outlook.com/?url=https%3A%2F%2Frt.rap.ucar.edu%2Frt%2FTicket%2FDisplay.html%3Fid%3D90526&data=02%7C01%7Csbao%40coastal.edu%7Ca754ac9e946947ad52b408d6edcece05%7Cbf1f856b8ef84e52be9387d3c3622797%7C0%7C1%7C636957869839298714&sdata=XomKoFCpcGFq9i5hS28otiWw%2BUtv6BH78wM7ra1hqEU%3D&reserved=0
>
>
>
> Dear Colleague,
>
> I am trying to use MET’s “grid_stat” tool to evaluate a 2-D
model
> simulation against observation. However I ran into the error
below.
>
> DEBUG 1: Default Config File:
> /usr/local/share/met/config/GridStatConfig_default
> DEBUG 1: User Config File:
> /met/met-
8.1/tutorial/MET_Tutorial//config/GridStatConfig_APCP_12
> DEBUG 4: Met2dDataFileFactory::new_met_2d_data_file() -> created
new
> Met2dDataFile object of type "FileType_None".
> ERROR :
> ERROR : Trouble reading forecast file
> "/met/met-
8.1/tutorial/MET_Tutorial/input/bao_data/fv3_model_output.nc"
> ERROR :
>
> I have attached the 2 NetCDF files here. I ran a NetCDF file
checker (
>
https://nam03.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcfconventions.org%2Fcompliance-
checker.html&data=02%7C01%7Csbao%40coastal.edu%7Ca754ac9e946947ad52b408d6edcece05%7Cbf1f856b8ef84e52be9387d3c3622797%7C0%7C1%7C636957869839298714&sdata=nWdeC68thzGad7RYkiKCIsWhIZHROS5z6KaDPG%2FRDyM%3D&reserved=0)
and it appears these 2
> files are both CF-compliant.
> I wonder if you could please help with this issue?
>
> Thanks,
> Shaowu
>
>
>
------------------------------------------------
Subject: Re: [rt.rap.ucar.edu #90526] MET input NetCDF file error
From: sbao at coastal.edu
Time: Mon Jul 01 13:53:29 2019
John,
Thanks for your help, now I'm able to run the MET on my files.
However, I have one more question. As you see, my files do not have
the time information.
So is there a way, maybe like the ncatted, to tell MET commands the
time information of my files?
For example, my file name is "fv3_model_output_MOD.nc", and there is
no time information in it.
But I know this is a 5-day forecast, initial time is, say, June 10,
2019, and this file's valid time is 48-hour.
What's the best way to provide these information when I run MET, so
that the output is not always assuming time 00000?
Your help is greatly appreciated!
Thanks,
Shaowu
On 6/10/19, 2:09 PM, "John Halley Gotway via RT" <met_help at ucar.edu>
wrote:
Shaowu,
I see you're having trouble using some NetCDF files in MET.
Whenever
starting with a new gridded dataset, I always recommend running
MET's
plot_data_plane tool to make a quick plot of the data. That
ensures that
MET can read the data and interpret the metadata correctly. I get
a
similar error from plot_data_plane:
*met-8.1/bin/plot_data_plane fv3_model_output.nc
<http://fv3_model_output.nc> fv3_model_output.ps
<http://fv3_model_output.ps> 'name="model"; level="(*,*)";'*
*ERROR : plot_data_plane -> file "fv3_model_output.nc
<http://fv3_model_output.nc>" not a valid data file*
Looking in your file, I see that it lacks the global "Conventions"
attribute which MET expects to see in CF-compliant NetCDF files.
You can
tell MET explicitly to interpret this data as being CF-compliant
by setting
"file_type=NETCDF_NCCF;"
*met-8.1/bin/plot_data_plane fv3_model_output.nc
<http://fv3_model_output.nc> fv3_model_output.ps
<http://fv3_model_output.ps> 'name="model"; level="(*,*)";
file_type=NETCDF_NCCF;'*
Or you could simply add the "Conventions" attribute and you
wouldn't need
to use the "file_type" option.
*ncatted -a Conventions,global,a,c,CF-1.7 fv3_model_output.nc
<http://fv3_model_output.nc> fv3_model_output_MOD.nc*
*met-8.1/bin/plot_data_plane fv3_model_output_MOD.nc
fv3_model_output_MOD.ps 'name="model";
level="(*,*)";'*
WARNING: NcCfFile::open() -> could not determine the valid time,
using 0.
I've attached the resulting image. Does that data look right to
you?
As you can see, there is no timing information in these NetCDF
files, so
MET prints a warning about that.
Hope that helps get you going.
Thanks,
John Halley Gotway
On Sun, Jun 9, 2019 at 2:00 PM sbao at coastal.edu via RT
<met_help at ucar.edu>
wrote:
>
> Sun Jun 09 14:00:44 2019: Request 90526 was acted upon.
> Transaction: Ticket created by sbao at coastal.edu
> Queue: met_help
> Subject: MET input NetCDF file error
> Owner: Nobody
> Requestors: sbao at coastal.edu
> Status: new
> Ticket <URL:
https://nam03.safelinks.protection.outlook.com/?url=https%3A%2F%2Frt.rap.ucar.edu%2Frt%2FTicket%2FDisplay.html%3Fid%3D90526&data=02%7C01%7Csbao%40coastal.edu%7Ca754ac9e946947ad52b408d6edcece05%7Cbf1f856b8ef84e52be9387d3c3622797%7C0%7C1%7C636957869839298714&sdata=XomKoFCpcGFq9i5hS28otiWw%2BUtv6BH78wM7ra1hqEU%3D&reserved=0
>
>
>
> Dear Colleague,
>
> I am trying to use MET’s “grid_stat” tool to evaluate a 2-D
model
> simulation against observation. However I ran into the error
below.
>
> DEBUG 1: Default Config File:
> /usr/local/share/met/config/GridStatConfig_default
> DEBUG 1: User Config File:
> /met/met-
8.1/tutorial/MET_Tutorial//config/GridStatConfig_APCP_12
> DEBUG 4: Met2dDataFileFactory::new_met_2d_data_file() -> created
new
> Met2dDataFile object of type "FileType_None".
> ERROR :
> ERROR : Trouble reading forecast file
> "/met/met-
8.1/tutorial/MET_Tutorial/input/bao_data/fv3_model_output.nc"
> ERROR :
>
> I have attached the 2 NetCDF files here. I ran a NetCDF file
checker (
>
https://nam03.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcfconventions.org%2Fcompliance-
checker.html&data=02%7C01%7Csbao%40coastal.edu%7Ca754ac9e946947ad52b408d6edcece05%7Cbf1f856b8ef84e52be9387d3c3622797%7C0%7C1%7C636957869839298714&sdata=nWdeC68thzGad7RYkiKCIsWhIZHROS5z6KaDPG%2FRDyM%3D&reserved=0)
and it appears these 2
> files are both CF-compliant.
> I wonder if you could please help with this issue?
>
> Thanks,
> Shaowu
>
>
>
------------------------------------------------
Subject: MET input NetCDF file error
From: John Halley Gotway
Time: Mon Jul 01 14:03:38 2019
Shaowu,
Unfortunately, the "best" way to do this is not yet implemented. I'd
like
to add a new config file setting option to enable users to modify or
add
metadata that does not exist in the input file. This development
request
is described in this GitHub issue:
https://github.com/NCAR/MET/issues/1020
Since that doesn't exist yet, we'll need to find another way. I can
see
two options...
(1) You could modify the contents of the NetCDF file, as you already
mentioned, adding metadata about the time. Unfortunately, it's not as
simple as running ncatted because defining time info in a CF-compliant
way
requires adding a new dimension (time) and 2 new variables (time and
forecast_reference_time).
Search for "forecast_reference_time" in this doc:
http://cfconventions.org/Data/cf-conventions/cf-conventions-1.7/cf-
conventions.html
(2) The other alternative would writing a python script to read your
data,
define the metadata, and then pass them in memory to the MET tools.
If you
like working with python, you may like this option. Examples of
python
embedding can be found here:
https://dtcenter.org/community-code/model-evaluation-tools-met/sample-
analysis-scripts
Either option would work. Let me know if you have more questions.
Thanks,
John
On Mon, Jul 1, 2019 at 1:53 PM sbao at coastal.edu via RT
<met_help at ucar.edu>
wrote:
>
> <URL: https://rt.rap.ucar.edu/rt/Ticket/Display.html?id=90526 >
>
> John,
>
> Thanks for your help, now I'm able to run the MET on my files.
> However, I have one more question. As you see, my files do not have
the
> time information.
> So is there a way, maybe like the ncatted, to tell MET commands the
time
> information of my files?
>
> For example, my file name is "fv3_model_output_MOD.nc", and there is
no
> time information in it.
> But I know this is a 5-day forecast, initial time is, say, June 10,
2019,
> and this file's valid time is 48-hour.
> What's the best way to provide these information when I run MET, so
that
> the output is not always assuming time 00000?
>
> Your help is greatly appreciated!
>
> Thanks,
> Shaowu
>
>
> On 6/10/19, 2:09 PM, "John Halley Gotway via RT"
<met_help at ucar.edu>
> wrote:
>
> Shaowu,
>
> I see you're having trouble using some NetCDF files in MET.
Whenever
> starting with a new gridded dataset, I always recommend running
MET's
> plot_data_plane tool to make a quick plot of the data. That
ensures
> that
> MET can read the data and interpret the metadata correctly. I
get a
> similar error from plot_data_plane:
>
> *met-8.1/bin/plot_data_plane fv3_model_output.nc
> <http://fv3_model_output.nc> fv3_model_output.ps
> <http://fv3_model_output.ps> 'name="model"; level="(*,*)";'*
> *ERROR : plot_data_plane -> file "fv3_model_output.nc
> <http://fv3_model_output.nc>" not a valid data file*
>
> Looking in your file, I see that it lacks the global
"Conventions"
> attribute which MET expects to see in CF-compliant NetCDF files.
You
> can
> tell MET explicitly to interpret this data as being CF-compliant
by
> setting
> "file_type=NETCDF_NCCF;"
>
> *met-8.1/bin/plot_data_plane fv3_model_output.nc
> <http://fv3_model_output.nc> fv3_model_output.ps
> <http://fv3_model_output.ps> 'name="model"; level="(*,*)";
> file_type=NETCDF_NCCF;'*
>
> Or you could simply add the "Conventions" attribute and you
wouldn't
> need
> to use the "file_type" option.
>
> *ncatted -a Conventions,global,a,c,CF-1.7 fv3_model_output.nc
> <http://fv3_model_output.nc> fv3_model_output_MOD.nc*
>
> *met-8.1/bin/plot_data_plane fv3_model_output_MOD.nc
> fv3_model_output_MOD.ps 'name="model";
> level="(*,*)";'*
>
>
> WARNING: NcCfFile::open() -> could not determine the valid time,
using
> 0.
>
>
> I've attached the resulting image. Does that data look right to
you?
>
>
> As you can see, there is no timing information in these NetCDF
files,
> so
> MET prints a warning about that.
>
>
> Hope that helps get you going.
>
>
> Thanks,
> John Halley Gotway
>
> On Sun, Jun 9, 2019 at 2:00 PM sbao at coastal.edu via RT <
> met_help at ucar.edu>
> wrote:
>
> >
> > Sun Jun 09 14:00:44 2019: Request 90526 was acted upon.
> > Transaction: Ticket created by sbao at coastal.edu
> > Queue: met_help
> > Subject: MET input NetCDF file error
> > Owner: Nobody
> > Requestors: sbao at coastal.edu
> > Status: new
> > Ticket <URL:
>
https://nam03.safelinks.protection.outlook.com/?url=https%3A%2F%2Frt.rap.ucar.edu%2Frt%2FTicket%2FDisplay.html%3Fid%3D90526&data=02%7C01%7Csbao%40coastal.edu%7Ca754ac9e946947ad52b408d6edcece05%7Cbf1f856b8ef84e52be9387d3c3622797%7C0%7C1%7C636957869839298714&sdata=XomKoFCpcGFq9i5hS28otiWw%2BUtv6BH78wM7ra1hqEU%3D&reserved=0
> >
> >
> >
> > Dear Colleague,
> >
> > I am trying to use MET’s “grid_stat” tool to evaluate a 2-D
model
> > simulation against observation. However I ran into the error
below.
> >
> > DEBUG 1: Default Config File:
> > /usr/local/share/met/config/GridStatConfig_default
> > DEBUG 1: User Config File:
> > /met/met-
8.1/tutorial/MET_Tutorial//config/GridStatConfig_APCP_12
> > DEBUG 4: Met2dDataFileFactory::new_met_2d_data_file() ->
created new
> > Met2dDataFile object of type "FileType_None".
> > ERROR :
> > ERROR : Trouble reading forecast file
> > "/met/met-8.1/tutorial/MET_Tutorial/input/bao_data/
> fv3_model_output.nc"
> > ERROR :
> >
> > I have attached the 2 NetCDF files here. I ran a NetCDF file
checker
> (
> >
>
https://nam03.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcfconventions.org%2Fcompliance-
checker.html&data=02%7C01%7Csbao%40coastal.edu%7Ca754ac9e946947ad52b408d6edcece05%7Cbf1f856b8ef84e52be9387d3c3622797%7C0%7C1%7C636957869839298714&sdata=nWdeC68thzGad7RYkiKCIsWhIZHROS5z6KaDPG%2FRDyM%3D&reserved=0)
> and it appears these 2
> > files are both CF-compliant.
> > I wonder if you could please help with this issue?
> >
> > Thanks,
> > Shaowu
> >
> >
> >
>
>
>
>
>
>
------------------------------------------------
Subject: Re: [rt.rap.ucar.edu #90526] MET input NetCDF file error
From: sbao at coastal.edu
Time: Mon Jul 01 15:25:06 2019
John,
Thank you for you quick reply. I would wait for the future
implementation.
Meanwhile, I think a work-around may be just to directly modify the
MET output (.stat, .mode files) to change the time in them, after the
MET tool is run.
For example, I see in the .stat file the fields that need change
include:
FCST_LEAD FCST_VALID_BEG FCST_VALID_END OBS_LEAD OBS_VALID_BEG
OBS_VALID_END
So I guess I could change, for example,
FCST_LEAD FCST_VALID_BEG FCST_VALID_END OBS_LEAD OBS_VALID_BEG
OBS_VALID_END FCST_VAR
000000 19700101_000000 19700101_000000 000000 19700101_000000
19700101_000000 model
To (for a model data whose forecast initial time=2019 06 01 at
fcst_lead time = 48 hour):
FCST_LEAD FCST_VALID_BEG FCST_VALID_END OBS_LEAD OBS_VALID_BEG
OBS_VALID_END FCST_VAR
480000 20190601_000000 20190601_000000 000000 20190601_000000
20190601_000000 model
Will that cause any problems for later process such as METviewer?
Also, one thing I am not clear is, for the FCST_LEAD column, if the
format is HHMMSS, how do I display a model data whose forecast lead
time has 3-digit hours, e.g. 120 hr fcst_lead?
Thanks again!
Shaowu
On 7/1/19, 4:04 PM, "John Halley Gotway via RT" <met_help at ucar.edu>
wrote:
Shaowu,
Unfortunately, the "best" way to do this is not yet implemented.
I'd like
to add a new config file setting option to enable users to modify
or add
metadata that does not exist in the input file. This development
request
is described in this GitHub issue:
https://nam03.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2FNCAR%2FMET%2Fissues%2F1020&data=02%7C01%7Csbao%40coastal.edu%7C5aa9f1a4dc344158b10808d6fe5f576e%7Cbf1f856b8ef84e52be9387d3c3622797%7C0%7C0%7C636976082787058166&sdata=Bh4WPa9bEqO%2BMM5WPgT45XNZaVPWaeKgewVIaSU4y0Y%3D&reserved=0
Since that doesn't exist yet, we'll need to find another way. I
can see
two options...
(1) You could modify the contents of the NetCDF file, as you
already
mentioned, adding metadata about the time. Unfortunately, it's
not as
simple as running ncatted because defining time info in a CF-
compliant way
requires adding a new dimension (time) and 2 new variables (time
and
forecast_reference_time).
Search for "forecast_reference_time" in this doc:
https://nam03.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcfconventions.org%2FData%2Fcf-
conventions%2Fcf-conventions-1.7%2Fcf-
conventions.html&data=02%7C01%7Csbao%40coastal.edu%7C5aa9f1a4dc344158b10808d6fe5f576e%7Cbf1f856b8ef84e52be9387d3c3622797%7C0%7C0%7C636976082787058166&sdata=outxZwqv2Mh3JLYHISTUq6fapH6wRS29sYhmjwE3EHs%3D&reserved=0
(2) The other alternative would writing a python script to read
your data,
define the metadata, and then pass them in memory to the MET
tools. If you
like working with python, you may like this option. Examples of
python
embedding can be found here:
https://nam03.safelinks.protection.outlook.com/?url=https%3A%2F%2Fdtcenter.org%2Fcommunity-
code%2Fmodel-evaluation-tools-met%2Fsample-analysis-
scripts&data=02%7C01%7Csbao%40coastal.edu%7C5aa9f1a4dc344158b10808d6fe5f576e%7Cbf1f856b8ef84e52be9387d3c3622797%7C0%7C0%7C636976082787058166&sdata=XRXGep8Cf7hfjuBF96OcJeDrwSJCGEAoDpQ1%2FTqj7Ig%3D&reserved=0
Either option would work. Let me know if you have more questions.
Thanks,
John
On Mon, Jul 1, 2019 at 1:53 PM sbao at coastal.edu via RT
<met_help at ucar.edu>
wrote:
>
> <URL:
https://nam03.safelinks.protection.outlook.com/?url=https%3A%2F%2Frt.rap.ucar.edu%2Frt%2FTicket%2FDisplay.html%3Fid%3D90526&data=02%7C01%7Csbao%40coastal.edu%7C5aa9f1a4dc344158b10808d6fe5f576e%7Cbf1f856b8ef84e52be9387d3c3622797%7C0%7C0%7C636976082787058166&sdata=btW1T%2BSeN1IGaMYm5ifclME2NROf%2B7rnTFrNlZyNGzo%3D&reserved=0
>
>
> John,
>
> Thanks for your help, now I'm able to run the MET on my files.
> However, I have one more question. As you see, my files do not
have the
> time information.
> So is there a way, maybe like the ncatted, to tell MET commands
the time
> information of my files?
>
> For example, my file name is "fv3_model_output_MOD.nc", and
there is no
> time information in it.
> But I know this is a 5-day forecast, initial time is, say, June
10, 2019,
> and this file's valid time is 48-hour.
> What's the best way to provide these information when I run MET,
so that
> the output is not always assuming time 00000?
>
> Your help is greatly appreciated!
>
> Thanks,
> Shaowu
>
>
> On 6/10/19, 2:09 PM, "John Halley Gotway via RT"
<met_help at ucar.edu>
> wrote:
>
> Shaowu,
>
> I see you're having trouble using some NetCDF files in MET.
Whenever
> starting with a new gridded dataset, I always recommend
running MET's
> plot_data_plane tool to make a quick plot of the data. That
ensures
> that
> MET can read the data and interpret the metadata correctly.
I get a
> similar error from plot_data_plane:
>
> *met-8.1/bin/plot_data_plane fv3_model_output.nc
> <http://fv3_model_output.nc> fv3_model_output.ps
> <http://fv3_model_output.ps> 'name="model"; level="(*,*)";'*
> *ERROR : plot_data_plane -> file "fv3_model_output.nc
> <http://fv3_model_output.nc>" not a valid data file*
>
> Looking in your file, I see that it lacks the global
"Conventions"
> attribute which MET expects to see in CF-compliant NetCDF
files. You
> can
> tell MET explicitly to interpret this data as being CF-
compliant by
> setting
> "file_type=NETCDF_NCCF;"
>
> *met-8.1/bin/plot_data_plane fv3_model_output.nc
> <http://fv3_model_output.nc> fv3_model_output.ps
> <http://fv3_model_output.ps> 'name="model"; level="(*,*)";
> file_type=NETCDF_NCCF;'*
>
> Or you could simply add the "Conventions" attribute and you
wouldn't
> need
> to use the "file_type" option.
>
> *ncatted -a Conventions,global,a,c,CF-1.7
fv3_model_output.nc
> <http://fv3_model_output.nc> fv3_model_output_MOD.nc*
>
> *met-8.1/bin/plot_data_plane fv3_model_output_MOD.nc
> fv3_model_output_MOD.ps 'name="model";
> level="(*,*)";'*
>
>
> WARNING: NcCfFile::open() -> could not determine the valid
time, using
> 0.
>
>
> I've attached the resulting image. Does that data look
right to you?
>
>
> As you can see, there is no timing information in these
NetCDF files,
> so
> MET prints a warning about that.
>
>
> Hope that helps get you going.
>
>
> Thanks,
> John Halley Gotway
>
> On Sun, Jun 9, 2019 at 2:00 PM sbao at coastal.edu via RT <
> met_help at ucar.edu>
> wrote:
>
> >
> > Sun Jun 09 14:00:44 2019: Request 90526 was acted upon.
> > Transaction: Ticket created by sbao at coastal.edu
> > Queue: met_help
> > Subject: MET input NetCDF file error
> > Owner: Nobody
> > Requestors: sbao at coastal.edu
> > Status: new
> > Ticket <URL:
>
https://nam03.safelinks.protection.outlook.com/?url=https%3A%2F%2Frt.rap.ucar.edu%2Frt%2FTicket%2FDisplay.html%3Fid%3D90526&data=02%7C01%7Csbao%40coastal.edu%7C5aa9f1a4dc344158b10808d6fe5f576e%7Cbf1f856b8ef84e52be9387d3c3622797%7C0%7C0%7C636976082787058166&sdata=btW1T%2BSeN1IGaMYm5ifclME2NROf%2B7rnTFrNlZyNGzo%3D&reserved=0
> >
> >
> >
> > Dear Colleague,
> >
> > I am trying to use MET’s “grid_stat” tool to evaluate a 2-
D model
> > simulation against observation. However I ran into the
error below.
> >
> > DEBUG 1: Default Config File:
> > /usr/local/share/met/config/GridStatConfig_default
> > DEBUG 1: User Config File:
> > /met/met-
8.1/tutorial/MET_Tutorial//config/GridStatConfig_APCP_12
> > DEBUG 4: Met2dDataFileFactory::new_met_2d_data_file() ->
created new
> > Met2dDataFile object of type "FileType_None".
> > ERROR :
> > ERROR : Trouble reading forecast file
> > "/met/met-8.1/tutorial/MET_Tutorial/input/bao_data/
> fv3_model_output.nc"
> > ERROR :
> >
> > I have attached the 2 NetCDF files here. I ran a NetCDF
file checker
> (
> >
>
https://nam03.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcfconventions.org%2Fcompliance-
checker.html&data=02%7C01%7Csbao%40coastal.edu%7C5aa9f1a4dc344158b10808d6fe5f576e%7Cbf1f856b8ef84e52be9387d3c3622797%7C0%7C0%7C636976082787058166&sdata=e4lNLalMH54FmnSAwk7rYnJyXf7nFZJ309VCY7W%2BW7w%3D&reserved=0)
> and it appears these 2
> > files are both CF-compliant.
> > I wonder if you could please help with this issue?
> >
> > Thanks,
> > Shaowu
> >
> >
> >
>
>
>
>
>
>
------------------------------------------------
Subject: MET input NetCDF file error
From: John Halley Gotway
Time: Mon Jul 01 15:30:28 2019
Shaowu,
Agreed, there's usually many ways to solve a problem. No, I don't
anticipate any problems in downstream processes, such as METviewer...
as
long as you format the timestamps in a consistent way. But, for
example,
the inter-column spacing doesn't matter... as long as there's some
white-space. You can specify a 3-digit FCST_LEAD (e.g. 120 hours) as
"1200000". The code parses it backwards and see seconds = 00, minutes
=
00, and hours = 120.
Thanks,
John
On Mon, Jul 1, 2019 at 3:25 PM sbao at coastal.edu via RT
<met_help at ucar.edu>
wrote:
>
> <URL: https://rt.rap.ucar.edu/rt/Ticket/Display.html?id=90526 >
>
> John,
>
> Thank you for you quick reply. I would wait for the future
implementation.
>
> Meanwhile, I think a work-around may be just to directly modify the
MET
> output (.stat, .mode files) to change the time in them, after the
MET tool
> is run.
>
> For example, I see in the .stat file the fields that need change
include:
> FCST_LEAD FCST_VALID_BEG FCST_VALID_END OBS_LEAD OBS_VALID_BEG
> OBS_VALID_END
>
> So I guess I could change, for example,
> FCST_LEAD FCST_VALID_BEG FCST_VALID_END OBS_LEAD OBS_VALID_BEG
> OBS_VALID_END FCST_VAR
> 000000 19700101_000000 19700101_000000 000000 19700101_000000
> 19700101_000000 model
>
> To (for a model data whose forecast initial time=2019 06 01 at
fcst_lead
> time = 48 hour):
>
> FCST_LEAD FCST_VALID_BEG FCST_VALID_END OBS_LEAD OBS_VALID_BEG
> OBS_VALID_END FCST_VAR
> 480000 20190601_000000 20190601_000000 000000 20190601_000000
> 20190601_000000 model
>
> Will that cause any problems for later process such as METviewer?
>
> Also, one thing I am not clear is, for the FCST_LEAD column, if the
format
> is HHMMSS, how do I display a model data whose forecast lead time
has
> 3-digit hours, e.g. 120 hr fcst_lead?
>
> Thanks again!
> Shaowu
>
>
>
> On 7/1/19, 4:04 PM, "John Halley Gotway via RT" <met_help at ucar.edu>
> wrote:
>
> Shaowu,
>
> Unfortunately, the "best" way to do this is not yet implemented.
I'd
> like
> to add a new config file setting option to enable users to
modify or
> add
> metadata that does not exist in the input file. This
development
> request
> is described in this GitHub issue:
>
>
https://nam03.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2FNCAR%2FMET%2Fissues%2F1020&data=02%7C01%7Csbao%40coastal.edu%7C5aa9f1a4dc344158b10808d6fe5f576e%7Cbf1f856b8ef84e52be9387d3c3622797%7C0%7C0%7C636976082787058166&sdata=Bh4WPa9bEqO%2BMM5WPgT45XNZaVPWaeKgewVIaSU4y0Y%3D&reserved=0
>
> Since that doesn't exist yet, we'll need to find another way. I
can
> see
> two options...
>
> (1) You could modify the contents of the NetCDF file, as you
already
> mentioned, adding metadata about the time. Unfortunately, it's
not as
> simple as running ncatted because defining time info in a CF-
compliant
> way
> requires adding a new dimension (time) and 2 new variables (time
and
> forecast_reference_time).
>
> Search for "forecast_reference_time" in this doc:
>
>
>
https://nam03.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcfconventions.org%2FData%2Fcf-
conventions%2Fcf-conventions-1.7%2Fcf-
conventions.html&data=02%7C01%7Csbao%40coastal.edu%7C5aa9f1a4dc344158b10808d6fe5f576e%7Cbf1f856b8ef84e52be9387d3c3622797%7C0%7C0%7C636976082787058166&sdata=outxZwqv2Mh3JLYHISTUq6fapH6wRS29sYhmjwE3EHs%3D&reserved=0
>
> (2) The other alternative would writing a python script to read
your
> data,
> define the metadata, and then pass them in memory to the MET
tools.
> If you
> like working with python, you may like this option. Examples of
python
> embedding can be found here:
>
>
>
https://nam03.safelinks.protection.outlook.com/?url=https%3A%2F%2Fdtcenter.org%2Fcommunity-
code%2Fmodel-evaluation-tools-met%2Fsample-analysis-
scripts&data=02%7C01%7Csbao%40coastal.edu%7C5aa9f1a4dc344158b10808d6fe5f576e%7Cbf1f856b8ef84e52be9387d3c3622797%7C0%7C0%7C636976082787058166&sdata=XRXGep8Cf7hfjuBF96OcJeDrwSJCGEAoDpQ1%2FTqj7Ig%3D&reserved=0
>
> Either option would work. Let me know if you have more
questions.
>
> Thanks,
> John
>
>
> On Mon, Jul 1, 2019 at 1:53 PM sbao at coastal.edu via RT <
> met_help at ucar.edu>
> wrote:
>
> >
> > <URL:
>
https://nam03.safelinks.protection.outlook.com/?url=https%3A%2F%2Frt.rap.ucar.edu%2Frt%2FTicket%2FDisplay.html%3Fid%3D90526&data=02%7C01%7Csbao%40coastal.edu%7C5aa9f1a4dc344158b10808d6fe5f576e%7Cbf1f856b8ef84e52be9387d3c3622797%7C0%7C0%7C636976082787058166&sdata=btW1T%2BSeN1IGaMYm5ifclME2NROf%2B7rnTFrNlZyNGzo%3D&reserved=0
> >
> >
> > John,
> >
> > Thanks for your help, now I'm able to run the MET on my files.
> > However, I have one more question. As you see, my files do not
have
> the
> > time information.
> > So is there a way, maybe like the ncatted, to tell MET
commands the
> time
> > information of my files?
> >
> > For example, my file name is "fv3_model_output_MOD.nc", and
there is
> no
> > time information in it.
> > But I know this is a 5-day forecast, initial time is, say,
June 10,
> 2019,
> > and this file's valid time is 48-hour.
> > What's the best way to provide these information when I run
MET, so
> that
> > the output is not always assuming time 00000?
> >
> > Your help is greatly appreciated!
> >
> > Thanks,
> > Shaowu
> >
> >
> > On 6/10/19, 2:09 PM, "John Halley Gotway via RT"
<met_help at ucar.edu>
> > wrote:
> >
> > Shaowu,
> >
> > I see you're having trouble using some NetCDF files in
MET.
> Whenever
> > starting with a new gridded dataset, I always recommend
running
> MET's
> > plot_data_plane tool to make a quick plot of the data.
That
> ensures
> > that
> > MET can read the data and interpret the metadata
correctly. I
> get a
> > similar error from plot_data_plane:
> >
> > *met-8.1/bin/plot_data_plane fv3_model_output.nc
> > <http://fv3_model_output.nc> fv3_model_output.ps
> > <http://fv3_model_output.ps> 'name="model";
level="(*,*)";'*
> > *ERROR : plot_data_plane -> file "fv3_model_output.nc
> > <http://fv3_model_output.nc>" not a valid data file*
> >
> > Looking in your file, I see that it lacks the global
> "Conventions"
> > attribute which MET expects to see in CF-compliant NetCDF
> files. You
> > can
> > tell MET explicitly to interpret this data as being CF-
compliant
> by
> > setting
> > "file_type=NETCDF_NCCF;"
> >
> > *met-8.1/bin/plot_data_plane fv3_model_output.nc
> > <http://fv3_model_output.nc> fv3_model_output.ps
> > <http://fv3_model_output.ps> 'name="model"; level="(*,*)";
> > file_type=NETCDF_NCCF;'*
> >
> > Or you could simply add the "Conventions" attribute and
you
> wouldn't
> > need
> > to use the "file_type" option.
> >
> > *ncatted -a Conventions,global,a,c,CF-1.7
fv3_model_output.nc
> > <http://fv3_model_output.nc> fv3_model_output_MOD.nc*
> >
> > *met-8.1/bin/plot_data_plane fv3_model_output_MOD.nc
> > fv3_model_output_MOD.ps 'name="model";
> > level="(*,*)";'*
> >
> >
> > WARNING: NcCfFile::open() -> could not determine the valid
time,
> using
> > 0.
> >
> >
> > I've attached the resulting image. Does that data look
right to
> you?
> >
> >
> > As you can see, there is no timing information in these
NetCDF
> files,
> > so
> > MET prints a warning about that.
> >
> >
> > Hope that helps get you going.
> >
> >
> > Thanks,
> > John Halley Gotway
> >
> > On Sun, Jun 9, 2019 at 2:00 PM sbao at coastal.edu via RT <
> > met_help at ucar.edu>
> > wrote:
> >
> > >
> > > Sun Jun 09 14:00:44 2019: Request 90526 was acted upon.
> > > Transaction: Ticket created by sbao at coastal.edu
> > > Queue: met_help
> > > Subject: MET input NetCDF file error
> > > Owner: Nobody
> > > Requestors: sbao at coastal.edu
> > > Status: new
> > > Ticket <URL:
> >
>
https://nam03.safelinks.protection.outlook.com/?url=https%3A%2F%2Frt.rap.ucar.edu%2Frt%2FTicket%2FDisplay.html%3Fid%3D90526&data=02%7C01%7Csbao%40coastal.edu%7C5aa9f1a4dc344158b10808d6fe5f576e%7Cbf1f856b8ef84e52be9387d3c3622797%7C0%7C0%7C636976082787058166&sdata=btW1T%2BSeN1IGaMYm5ifclME2NROf%2B7rnTFrNlZyNGzo%3D&reserved=0
> > >
> > >
> > >
> > > Dear Colleague,
> > >
> > > I am trying to use MET’s “grid_stat” tool to evaluate a
2-D
> model
> > > simulation against observation. However I ran into the
error
> below.
> > >
> > > DEBUG 1: Default Config File:
> > > /usr/local/share/met/config/GridStatConfig_default
> > > DEBUG 1: User Config File:
> > >
> /met/met-8.1/tutorial/MET_Tutorial//config/GridStatConfig_APCP_12
> > > DEBUG 4: Met2dDataFileFactory::new_met_2d_data_file() ->
> created new
> > > Met2dDataFile object of type "FileType_None".
> > > ERROR :
> > > ERROR : Trouble reading forecast file
> > > "/met/met-8.1/tutorial/MET_Tutorial/input/bao_data/
> > fv3_model_output.nc"
> > > ERROR :
> > >
> > > I have attached the 2 NetCDF files here. I ran a NetCDF
file
> checker
> > (
> > >
> >
>
https://nam03.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcfconventions.org%2Fcompliance-
checker.html&data=02%7C01%7Csbao%40coastal.edu%7C5aa9f1a4dc344158b10808d6fe5f576e%7Cbf1f856b8ef84e52be9387d3c3622797%7C0%7C0%7C636976082787058166&sdata=e4lNLalMH54FmnSAwk7rYnJyXf7nFZJ309VCY7W%2BW7w%3D&reserved=0
> )
> > and it appears these 2
> > > files are both CF-compliant.
> > > I wonder if you could please help with this issue?
> > >
> > > Thanks,
> > > Shaowu
> > >
> > >
> > >
> >
> >
> >
> >
> >
> >
>
>
>
>
>
>
------------------------------------------------
Subject: MET input NetCDF file error
From: sbao at coastal.edu
Time: Mon Jul 01 15:57:08 2019
Sounds good. Thanks!
Shaowu
On Jul 1, 2019 5:31 PM, John Halley Gotway via RT <met_help at ucar.edu>
wrote:
Shaowu,
Agreed, there's usually many ways to solve a problem. No, I don't
anticipate any problems in downstream processes, such as METviewer...
as
long as you format the timestamps in a consistent way. But, for
example,
the inter-column spacing doesn't matter... as long as there's some
white-space. You can specify a 3-digit FCST_LEAD (e.g. 120 hours) as
"1200000". The code parses it backwards and see seconds = 00, minutes
=
00, and hours = 120.
Thanks,
John
On Mon, Jul 1, 2019 at 3:25 PM sbao at coastal.edu via RT
<met_help at ucar.edu>
wrote:
>
> <URL:
https://nam03.safelinks.protection.outlook.com/?url=https%3A%2F%2Frt.rap.ucar.edu%2Frt%2FTicket%2FDisplay.html%3Fid%3D90526&data=02%7C01%7Csbao%40coastal.edu%7Cb96c171b6da04e76684008d6fe6b76b2%7Cbf1f856b8ef84e52be9387d3c3622797%7C0%7C0%7C636976134886164854&sdata=yjGho%2FlomTnqQmqUokBszJQB51kNcVHzeh9GPBlu5mQ%3D&reserved=0
>
>
> John,
>
> Thank you for you quick reply. I would wait for the future
implementation.
>
> Meanwhile, I think a work-around may be just to directly modify the
MET
> output (.stat, .mode files) to change the time in them, after the
MET tool
> is run.
>
> For example, I see in the .stat file the fields that need change
include:
> FCST_LEAD FCST_VALID_BEG FCST_VALID_END OBS_LEAD OBS_VALID_BEG
> OBS_VALID_END
>
> So I guess I could change, for example,
> FCST_LEAD FCST_VALID_BEG FCST_VALID_END OBS_LEAD OBS_VALID_BEG
> OBS_VALID_END FCST_VAR
> 000000 19700101_000000 19700101_000000 000000 19700101_000000
> 19700101_000000 model
>
> To (for a model data whose forecast initial time=2019 06 01 at
fcst_lead
> time = 48 hour):
>
> FCST_LEAD FCST_VALID_BEG FCST_VALID_END OBS_LEAD OBS_VALID_BEG
> OBS_VALID_END FCST_VAR
> 480000 20190601_000000 20190601_000000 000000 20190601_000000
> 20190601_000000 model
>
> Will that cause any problems for later process such as METviewer?
>
> Also, one thing I am not clear is, for the FCST_LEAD column, if the
format
> is HHMMSS, how do I display a model data whose forecast lead time
has
> 3-digit hours, e.g. 120 hr fcst_lead?
>
> Thanks again!
> Shaowu
>
>
>
> On 7/1/19, 4:04 PM, "John Halley Gotway via RT" <met_help at ucar.edu>
> wrote:
>
> Shaowu,
>
> Unfortunately, the "best" way to do this is not yet implemented.
I'd
> like
> to add a new config file setting option to enable users to
modify or
> add
> metadata that does not exist in the input file. This
development
> request
> is described in this GitHub issue:
>
>
https://nam03.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2FNCAR%2FMET%2Fissues%2F1020&data=02%7C01%7Csbao%40coastal.edu%7Cb96c171b6da04e76684008d6fe6b76b2%7Cbf1f856b8ef84e52be9387d3c3622797%7C0%7C0%7C636976134886164854&sdata=jTHllnOVgi1uCCc913bGM%2BBGvLdBoGAEz8SO5vwSS3M%3D&reserved=0
>
> Since that doesn't exist yet, we'll need to find another way. I
can
> see
> two options...
>
> (1) You could modify the contents of the NetCDF file, as you
already
> mentioned, adding metadata about the time. Unfortunately, it's
not as
> simple as running ncatted because defining time info in a CF-
compliant
> way
> requires adding a new dimension (time) and 2 new variables (time
and
> forecast_reference_time).
>
> Search for "forecast_reference_time" in this doc:
>
>
>
https://nam03.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcfconventions.org%2FData%2Fcf-
conventions%2Fcf-conventions-1.7%2Fcf-
conventions.html&data=02%7C01%7Csbao%40coastal.edu%7Cb96c171b6da04e76684008d6fe6b76b2%7Cbf1f856b8ef84e52be9387d3c3622797%7C0%7C0%7C636976134886164854&sdata=8ERHFHhq0qFf%2FR4pl%2Fr4E%2Bf3k3O%2F8JcSLkJIe97cNo4%3D&reserved=0
>
> (2) The other alternative would writing a python script to read
your
> data,
> define the metadata, and then pass them in memory to the MET
tools.
> If you
> like working with python, you may like this option. Examples of
python
> embedding can be found here:
>
>
>
https://nam03.safelinks.protection.outlook.com/?url=https%3A%2F%2Fdtcenter.org%2Fcommunity-
code%2Fmodel-evaluation-tools-met%2Fsample-analysis-
scripts&data=02%7C01%7Csbao%40coastal.edu%7Cb96c171b6da04e76684008d6fe6b76b2%7Cbf1f856b8ef84e52be9387d3c3622797%7C0%7C0%7C636976134886164854&sdata=oeBUyQ7wDYmxVM9k7Iv7K7I0vk84MFjSOgaEPD7pttk%3D&reserved=0
>
> Either option would work. Let me know if you have more
questions.
>
> Thanks,
> John
>
>
> On Mon, Jul 1, 2019 at 1:53 PM sbao at coastal.edu via RT <
> met_help at ucar.edu>
> wrote:
>
> >
> > <URL:
>
https://nam03.safelinks.protection.outlook.com/?url=https%3A%2F%2Frt.rap.ucar.edu%2Frt%2FTicket%2FDisplay.html%3Fid%3D90526&data=02%7C01%7Csbao%40coastal.edu%7Cb96c171b6da04e76684008d6fe6b76b2%7Cbf1f856b8ef84e52be9387d3c3622797%7C0%7C0%7C636976134886164854&sdata=yjGho%2FlomTnqQmqUokBszJQB51kNcVHzeh9GPBlu5mQ%3D&reserved=0
> >
> >
> > John,
> >
> > Thanks for your help, now I'm able to run the MET on my files.
> > However, I have one more question. As you see, my files do not
have
> the
> > time information.
> > So is there a way, maybe like the ncatted, to tell MET
commands the
> time
> > information of my files?
> >
> > For example, my file name is "fv3_model_output_MOD.nc", and
there is
> no
> > time information in it.
> > But I know this is a 5-day forecast, initial time is, say,
June 10,
> 2019,
> > and this file's valid time is 48-hour.
> > What's the best way to provide these information when I run
MET, so
> that
> > the output is not always assuming time 00000?
> >
> > Your help is greatly appreciated!
> >
> > Thanks,
> > Shaowu
> >
> >
> > On 6/10/19, 2:09 PM, "John Halley Gotway via RT"
<met_help at ucar.edu>
> > wrote:
> >
> > Shaowu,
> >
> > I see you're having trouble using some NetCDF files in
MET.
> Whenever
> > starting with a new gridded dataset, I always recommend
running
> MET's
> > plot_data_plane tool to make a quick plot of the data.
That
> ensures
> > that
> > MET can read the data and interpret the metadata
correctly. I
> get a
> > similar error from plot_data_plane:
> >
> > *met-8.1/bin/plot_data_plane fv3_model_output.nc
> > <http://fv3_model_output.nc> fv3_model_output.ps
> > <http://fv3_model_output.ps> 'name="model";
level="(*,*)";'*
> > *ERROR : plot_data_plane -> file "fv3_model_output.nc
> > <http://fv3_model_output.nc>" not a valid data file*
> >
> > Looking in your file, I see that it lacks the global
> "Conventions"
> > attribute which MET expects to see in CF-compliant NetCDF
> files. You
> > can
> > tell MET explicitly to interpret this data as being CF-
compliant
> by
> > setting
> > "file_type=NETCDF_NCCF;"
> >
> > *met-8.1/bin/plot_data_plane fv3_model_output.nc
> > <http://fv3_model_output.nc> fv3_model_output.ps
> > <http://fv3_model_output.ps> 'name="model"; level="(*,*)";
> > file_type=NETCDF_NCCF;'*
> >
> > Or you could simply add the "Conventions" attribute and
you
> wouldn't
> > need
> > to use the "file_type" option.
> >
> > *ncatted -a Conventions,global,a,c,CF-1.7
fv3_model_output.nc
> > <http://fv3_model_output.nc> fv3_model_output_MOD.nc*
> >
> > *met-8.1/bin/plot_data_plane fv3_model_output_MOD.nc
> > fv3_model_output_MOD.ps 'name="model";
> > level="(*,*)";'*
> >
> >
> > WARNING: NcCfFile::open() -> could not determine the valid
time,
> using
> > 0.
> >
> >
> > I've attached the resulting image. Does that data look
right to
> you?
> >
> >
> > As you can see, there is no timing information in these
NetCDF
> files,
> > so
> > MET prints a warning about that.
> >
> >
> > Hope that helps get you going.
> >
> >
> > Thanks,
> > John Halley Gotway
> >
> > On Sun, Jun 9, 2019 at 2:00 PM sbao at coastal.edu via RT <
> > met_help at ucar.edu>
> > wrote:
> >
> > >
> > > Sun Jun 09 14:00:44 2019: Request 90526 was acted upon.
> > > Transaction: Ticket created by sbao at coastal.edu
> > > Queue: met_help
> > > Subject: MET input NetCDF file error
> > > Owner: Nobody
> > > Requestors: sbao at coastal.edu
> > > Status: new
> > > Ticket <URL:
> >
>
https://nam03.safelinks.protection.outlook.com/?url=https%3A%2F%2Frt.rap.ucar.edu%2Frt%2FTicket%2FDisplay.html%3Fid%3D90526&data=02%7C01%7Csbao%40coastal.edu%7Cb96c171b6da04e76684008d6fe6b76b2%7Cbf1f856b8ef84e52be9387d3c3622797%7C0%7C0%7C636976134886164854&sdata=yjGho%2FlomTnqQmqUokBszJQB51kNcVHzeh9GPBlu5mQ%3D&reserved=0
> > >
> > >
> > >
> > > Dear Colleague,
> > >
> > > I am trying to use MET’s “grid_stat” tool to evaluate a
2-D
> model
> > > simulation against observation. However I ran into the
error
> below.
> > >
> > > DEBUG 1: Default Config File:
> > > /usr/local/share/met/config/GridStatConfig_default
> > > DEBUG 1: User Config File:
> > >
> /met/met-8.1/tutorial/MET_Tutorial//config/GridStatConfig_APCP_12
> > > DEBUG 4: Met2dDataFileFactory::new_met_2d_data_file() ->
> created new
> > > Met2dDataFile object of type "FileType_None".
> > > ERROR :
> > > ERROR : Trouble reading forecast file
> > > "/met/met-8.1/tutorial/MET_Tutorial/input/bao_data/
> > fv3_model_output.nc"
> > > ERROR :
> > >
> > > I have attached the 2 NetCDF files here. I ran a NetCDF
file
> checker
> > (
> > >
> >
>
https://nam03.safelinks.protection.outlook.com/?url=http%3A%2F%2Fcfconventions.org%2Fcompliance-
checker.html&data=02%7C01%7Csbao%40coastal.edu%7Cb96c171b6da04e76684008d6fe6b76b2%7Cbf1f856b8ef84e52be9387d3c3622797%7C0%7C0%7C636976134886164854&sdata=CtvoCh9g1FDF6LbKGAP2cCInmNIIygTUrNtJ2NPdd88%3D&reserved=0
> )
> > and it appears these 2
> > > files are both CF-compliant.
> > > I wonder if you could please help with this issue?
> > >
> > > Thanks,
> > > Shaowu
> > >
> > >
> > >
> >
> >
> >
> >
> >
> >
>
>
>
>
>
>
------------------------------------------------
More information about the Met_help
mailing list