Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update develop-ref after #1696 #1698

Merged
merged 20 commits into from
Mar 5, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
ab0f2c6
Per #1429, enhance error message from DataLine::get_item(). (#1682)
JohnHalleyGotway Feb 26, 2021
b2754b4
Feature 1429 tc_log second try (#1686)
JohnHalleyGotway Feb 26, 2021
a1aead4
Feature 1588 ps_log (#1687)
JohnHalleyGotway Feb 26, 2021
2ba6cd9
#1454 Disabled plot_data_plane_CESM_SSMI_microwave and plot_data_plan…
Feb 26, 2021
fe5f318
#1454 Moved NC attribute name to nc_utils.h
Feb 26, 2021
c1463b2
#1454 Corrected sanity checking for lat/lon projection based on the p…
Feb 26, 2021
ac4d7f9
#1454 Corrected sanity checking for lat/lon projection based on the p…
Feb 26, 2021
371dd2c
#1454 Corrected data.delta_lon
Mar 1, 2021
24c2bd8
#1454 Change bact to use diff instead of absolute value of diff
Mar 1, 2021
e224ce1
454 Deleted instea dof commenting out
Mar 1, 2021
c8e9049
454 Deleted instea dof commenting out
Mar 1, 2021
0f5366c
Merge pull request #1688 from dtcenter/feature_1454_nccf_grid_definition
hsoh-u Mar 1, 2021
996197c
Feature 1684 bss and 1685 single reference model (#1689)
JohnHalleyGotway Mar 2, 2021
40b57af
Per #1691, add met-10.0.0-beta4 release notes. (#1692)
JohnHalleyGotway Mar 2, 2021
23dc482
Updated Python documentation
jprestop Mar 3, 2021
9c9c54c
Per #1694, add VarInfo::magic_str_attr() to construct a field summary…
JohnHalleyGotway Mar 4, 2021
a16bebc
Per #1694, fixing 2 issues here. There was a bug in the computation o…
JohnHalleyGotway Mar 4, 2021
21e3eb7
Per #1694, just switching to consistent variable name.
JohnHalleyGotway Mar 5, 2021
0f84a5a
Just consistent spacing.
JohnHalleyGotway Mar 5, 2021
5f551d2
Merge pull request #1696 from dtcenter/bugfix_1694_grid_diag
davidfillmore Mar 5, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions met/docs/Users_Guide/appendixF.rst
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,11 @@ ________________________

In order to use Python embedding, the user's local Python installation must have the C-language Python header files and libraries. Sometimes when Python is installed locally, these header files and libraries are deleted at the end of the installation process, leaving only the binary executable and run-time shared object files. But the Python header files and libraries must be present to compile support in MET for Python embedding. Assuming the requisite Python files are present, and that Python embedding is enabled when building MET (which is done by passing the **--enable-python** option to the **configure** command line), the MET C++ code will use these in the compilation process to link directly to the Python libraries.

In addition to the **configure** option mentioned above, two variables, **MET_PYTHON_CC** and **MET_PYTHON_LD**, must also be set for the configuration process. These may either be set as environment variables or as command line options to **configure**. These constants are passed as compiler command line options when building MET to enable the compiler to find the requisite Python header files and libraries in the user's local filesystem. Fortunately, Python provides a way to set these variables properly. This frees the user from the necessity of having any expert knowledge of the compiling and linking process. Along with the **Python** executable, there should be another executable called **python-config**, whose output can be used to set these environment variables as follows:
In addition to the **configure** option mentioned above, two variables, **MET_PYTHON_CC** and **MET_PYTHON_LD**, must also be set for the configuration process. These may either be set as environment variables or as command line options to **configure**. These constants are passed as compiler command line options when building MET to enable the compiler to find the requisite Python header files and libraries in the user's local filesystem. Fortunately, Python provides a way to set these variables properly. This frees the user from the necessity of having any expert knowledge of the compiling and linking process. Along with the **Python** executable, there should be another executable called **python3-config**, whose output can be used to set these environment variables as follows:

• On the command line, run “**python-config --cflags**”. Set the value of **MET_PYTHON_CC** to the output of that command.
• On the command line, run “**python3-config --cflags**”. Set the value of **MET_PYTHON_CC** to the output of that command.

• Again on the command line, run “**python-config --ldflags**”. Set the value of **MET_PYTHON_LD** to the output of that command.
• Again on the command line, run “**python3-config --ldflags**”. Set the value of **MET_PYTHON_LD** to the output of that command.

Make sure that these are set as environment variables or that you have included them on the command line prior to running **configure**.

Expand Down
6 changes: 5 additions & 1 deletion met/docs/Users_Guide/ensemble-stat.rst
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,11 @@ The ranked probability score (RPS) is included in the Ranked Probability Score (
Climatology data
~~~~~~~~~~~~~~~~

The Ensemble-Stat output includes at least three statistics computed relative to external climatology data. The climatology is defined by mean and standard deviation fields, and both are required in the computation of ensemble skill score statistics. MET assumes that the climatology follows a normal distribution, defined by the mean and standard deviation at each point. When computing the CRPS skill score for (:ref:`Gneiting et al., 2004 <Gneiting-2004>`) the reference CRPS statistic is computed using the climatological mean and standard deviation directly. When computing the CRPS skill score for (:ref:`Hersbach, 2000 <Hersbach-2000>`) the reference CRPS statistic is computed by selecting equal-area-spaced values from the assumed normal climatological distribution. The number of points selected is determined by the *cdf_bins* setting in the *climo_cdf* dictionary. The reference CRPS is computed empirically from this ensemble of climatology values. The climatological distribution is also used for the RPSS. The forecast RPS statistic is computed from a probabilistic contingency table in which the probabilities are derived from the ensemble member values. In a simliar fashion, the climatogical probability for each observed value is derived from the climatological distribution. The area of the distribution to the left of the observed value is interpreted as the climatological probability. These climatological probabilities are also evaluated using a probabilistic contingency table from which the reference RPS score is computed. The skill scores are derived by comparing the forecast statistic to the reference climatology statistic.
The Ensemble-Stat output includes at least three statistics computed relative to external climatology data. The climatology is defined by mean and standard deviation fields, and typically both are required in the computation of ensemble skill score statistics. MET assumes that the climatology follows a normal distribution, defined by the mean and standard deviation at each point.

When computing the CRPS skill score for (:ref:`Gneiting et al., 2004 <Gneiting-2004>`) the reference CRPS statistic is computed using the climatological mean and standard deviation directly. When computing the CRPS skill score for (:ref:`Hersbach, 2000 <Hersbach-2000>`) the reference CRPS statistic is computed by selecting equal-area-spaced values from the assumed normal climatological distribution. The number of points selected is determined by the *cdf_bins* setting in the *climo_cdf* dictionary. The reference CRPS is computed empirically from this ensemble of climatology values. If the number bins is set to 1, the climatological CRPS is computed using only the climatological mean value. In this way, the empirical CRPSS may be computed relative to a single model rather than a climatological distribution.

The climatological distribution is also used for the RPSS. The forecast RPS statistic is computed from a probabilistic contingency table in which the probabilities are derived from the ensemble member values. In a simliar fashion, the climatogical probability for each observed value is derived from the climatological distribution. The area of the distribution to the left of the observed value is interpreted as the climatological probability. These climatological probabilities are also evaluated using a probabilistic contingency table from which the reference RPS score is computed. The skill scores are derived by comparing the forecast statistic to the reference climatology statistic.

Ensemble observation error
~~~~~~~~~~~~~~~~~~~~~~~~~~
Expand Down
55 changes: 54 additions & 1 deletion met/docs/Users_Guide/release-notes.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,64 @@ MET release notes
_________________

When applicable, release notes are followed by the GitHub issue number which
describes the bugfix, enhancement, or new feature: `MET Git-Hub issues. <https://github.com/dtcenter/MET/issues>`_
describes the bugfix, enhancement, or new feature: `MET GitHub issues. <https://github.com/dtcenter/MET/issues>`_

Version |version| release notes (|release_date|)
------------------------------------------------

Version `10.0.0-beta4 <https://github.com/dtcenter/MET/projects/26>`_ release notes (20210302)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

* Bugfixes:

* Fix the set_attr_accum option to set the accumulation time instead of the lead time (`#1646 <http://github.com/dtcenter/MET/issues/1646>`_).
* Correct the time offset for tests in unit_plot_data_plane.xml (`#1677 <http://github.com/dtcenter/MET/issues/1677>`_).

* Repository and build:

* Enhance the sample plotting R-script to read output from different versions of MET (`#1653 <http://github.com/dtcenter/MET/issues/1653>`_).

* Library code:

* Miscellaneous:

* Update GRIB1/2 table entries for the MXUPHL, MAXREF, MAXUVV, and MAXDVV variables (`#1658 <http://github.com/dtcenter/MET/issues/1658>`_).
* Update the Air Force GRIB tables to reflect current AF usage (`#1519 <http://github.com/dtcenter/MET/issues/1519>`_).
* Enhance the DataLine::get_item() error message to include the file name, line number, and column (`#1429 <http://github.com/dtcenter/MET/issues/1429>`_).

* NetCDF library:

* Add support for the NetCDF-CF conventions time bounds option (`#1657 <http://github.com/dtcenter/MET/issues/1657>`_).
* Error out when reading CF-compliant NetCDF data with incomplete grid definition (`#1454 <http://github.com/dtcenter/MET/issues/1454>`_).
* Reformat and simplify the magic_str() printed for NetCDF data files (`#1655 <http://github.com/dtcenter/MET/issues/1655>`_).

* Statistics computations:

* Add support for the Hersbach CRPS algorithm by add new columns to the ECNT line type (`#1450 <http://github.com/dtcenter/MET/issues/1450>`_).
* Enhance MET to derive the Hersbach CRPSCL_EMP and CRPSS_EMP statistics from a single deterministic reference model (`#1685 <http://github.com/dtcenter/MET/issues/1685>`_).
* Correct the climatological CRPS computation to match the NOAA/EMC VSDB method (`#1451 <http://github.com/dtcenter/MET/issues/1451>`_).
* Modify the climatological Brier Score computation to match the NOAA/EMC VSDB method (`#1684 <http://github.com/dtcenter/MET/issues/1684>`_).

* Application code:

* ASCII2NC and Point2Grid:

* Enhance ascii2nc and point2grid to gracefully process zero input observations rather than erroring out (`#1630 <http://github.com/dtcenter/MET/issues/1630>`_).

* Point-Stat Tool:

* Enhance the validation of masking regions to check for non-unique masking region names (`#1439 <http://github.com/dtcenter/MET/issues/1439>`_).
* Print the Point-Stat rejection code reason count log messages at verbosity level 2 for zero matched pairs (`#1644 <http://github.com/dtcenter/MET/issues/1644>`_).
* Add detailed log messages to Point-Stat when discarding observations (`#1588 <http://github.com/dtcenter/MET/issues/1588>`_).

* Stat-Analysis Tool:

* Add -fcst_init_inc/_exc and -fcst_valid_inc/_exc job command filtering options to Stat-Analysis (`#1135 <http://github.com/dtcenter/MET/issues/1135>`_).

* MODE Tool:

* Update the MODE AREA_RATIO output column to list the forecast area divided by the observation area (`#1643 <http://github.com/dtcenter/MET/issues/1643>`_).

Version `10.0.0-beta3 <https://github.com/dtcenter/MET/projects/25>`_ release notes (20210127)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Expand Down
2 changes: 1 addition & 1 deletion met/docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
verinfo = version
release = f'{version}'
release_year = '2021'
release_date = f'{release_year}0127'
release_date = f'{release_year}0302'
copyright = f'{release_year}, {author}'

# -- General configuration ---------------------------------------------------
Expand Down
11 changes: 11 additions & 0 deletions met/docs/requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
sphinx
sphinx-gallery
sphinx-rtd-theme
sphinxcontrib-applehelp
sphinxcontrib-bibtex
sphinxcontrib-devhelp
sphinxcontrib-htmlhelp
sphinxcontrib-jsmath
sphinxcontrib-qthelp
sphinxcontrib-serializinghtml

2 changes: 1 addition & 1 deletion met/docs/version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
10.0.0-beta3
10.0.0-beta4
16 changes: 12 additions & 4 deletions met/src/basic/vx_util/data_line.cc
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,12 @@ const char * DataLine::get_item(int k) const

if ( (k < 0) || (k >= N_items) ) {

mlog << Error << "\nDataLine::get_item(int) -> range check error\n\n";
ConcatString cs = (File ? File->filename() : "");

mlog << Error << "\nDataLine::get_item(int) -> "
<< "range check error reading line number " << LineNumber
<< ", item number " << k+1 << " of " << N_items
<< " from file \"" << cs << "\"\n\n";

exit ( 1 );

Expand Down Expand Up @@ -640,7 +645,8 @@ LineDataFile::LineDataFile(const LineDataFile &)

{

mlog << Error << "\nLineDataFile::LineDataFile(const LineDataFile &) -> should never be called!\n\n";
mlog << Error << "\nLineDataFile::LineDataFile(const LineDataFile &) -> "
<< "should never be called!\n\n";

exit ( 1 );

Expand All @@ -654,7 +660,8 @@ LineDataFile & LineDataFile::operator=(const LineDataFile &)

{

mlog << Error << "\nLineDataFile::operator=(const LineDataFile &) -> should never be called!\n\n";
mlog << Error << "\nLineDataFile::operator=(const LineDataFile &) -> "
<< "should never be called!\n\n";

exit ( 1 );

Expand Down Expand Up @@ -698,7 +705,8 @@ in = new ifstream;

if ( !in ) {

mlog << Error << "\nLineDataFile::open(const char *) -> can't allocate input stream\n\n";
mlog << Error << "\nLineDataFile::open(const char *) -> "
<< "can't allocate input stream\n\n";

exit ( 1 );

Expand Down
2 changes: 1 addition & 1 deletion met/src/basic/vx_util/interp_util.cc
Original file line number Diff line number Diff line change
Expand Up @@ -686,7 +686,7 @@ double interp_geog_match(const DataPlane &dp, const GridTemplate &gt,
}

if(!is_bad_data(interp_v)) {
mlog << Debug(4)
mlog << Debug(5)
<< "For observation value " << obs_v << " at grid (x, y) = ("
<< obs_x << ", " << obs_y << ") found forecast value "
<< interp_v << " at nearest matching geography point ("
Expand Down
16 changes: 14 additions & 2 deletions met/src/libcode/vx_analysis_util/stat_line.cc
Original file line number Diff line number Diff line change
Expand Up @@ -327,6 +327,18 @@ bool STATLine::has(const char *col_str) const

{

return ( !is_bad_data(get_offset(col_str)) );

}


////////////////////////////////////////////////////////////////////////


int STATLine::get_offset(const char *col_str) const

{

int offset = bad_data_int;
int dim = bad_data_int;

Expand All @@ -353,10 +365,10 @@ if ( is_bad_data(offset) ) {
}

//
// Return whether a valid offset value was found
// Return the offset value
//

return ( !is_bad_data(offset) );
return ( offset );

}

Expand Down
9 changes: 5 additions & 4 deletions met/src/libcode/vx_analysis_util/stat_line.h
Original file line number Diff line number Diff line change
Expand Up @@ -61,10 +61,11 @@ class STATLine : public DataLine {
// retrieve values of the header columns
//

bool has (const char *) const;
ConcatString get (const char *, bool check_na = true) const;
const char * get_item (const char *, bool check_na = true) const;
const char * get_item (int, bool check_na = true) const;
bool has (const char *) const;
int get_offset(const char *) const;
ConcatString get (const char *, bool check_na = true) const;
const char * get_item (const char *, bool check_na = true) const;
const char * get_item (int, bool check_na = true) const;

const char * version () const;
const char * model () const;
Expand Down
13 changes: 13 additions & 0 deletions met/src/libcode/vx_data2d/var_info.cc
Original file line number Diff line number Diff line change
Expand Up @@ -434,6 +434,19 @@ void VarInfo::set_magic(const ConcatString &nstr, const ConcatString &lstr) {

///////////////////////////////////////////////////////////////////////////////

ConcatString VarInfo::magic_str_attr() const {
ConcatString mstr(name_attr());
ConcatString lstr(level_attr());

// Format as {name}/{level} or {name}{level}
if(lstr.nonempty() && lstr[0] != '(') mstr << "/";
mstr << lstr;

return(mstr);
}

///////////////////////////////////////////////////////////////////////////////

void VarInfo::set_dict(Dictionary &dict) {
ThreshArray ta;
NumArray na;
Expand Down
1 change: 1 addition & 0 deletions met/src/libcode/vx_data2d/var_info.h
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,7 @@ class VarInfo

RegridInfo regrid() const;

ConcatString magic_str_attr() const;
ConcatString name_attr() const;
ConcatString units_attr() const;
ConcatString level_attr() const;
Expand Down
5 changes: 0 additions & 5 deletions met/src/libcode/vx_data2d_nc_met/met_file.cc
Original file line number Diff line number Diff line change
Expand Up @@ -41,11 +41,6 @@ static const string valid_time_ut_att_name = "valid_time_ut";
static const string init_time_ut_att_name = "init_time_ut";
static const string accum_time_att_name = "accum_time_sec";

static const string name_att_name = "name";
static const string long_name_att_name = "long_name";
static const string level_att_name = "level";
static const string units_att_name = "units";

static const int max_met_args = 30;

////////////////////////////////////////////////////////////////////////
Expand Down
3 changes: 0 additions & 3 deletions met/src/libcode/vx_data2d_nc_pinterp/pinterp_file.cc
Original file line number Diff line number Diff line change
Expand Up @@ -58,9 +58,6 @@ static const char hpa_units_str [] = "hPa";

static const string init_time_att_name = "START_DATE";

static const string description_att_name = "description";
static const string units_att_name = "units";

static const int max_pinterp_args = 30;

static const double pinterp_missing = 1.0e35;
Expand Down
Loading