Skip to content

Commit 8da719d

Browse files
authored
Release 2.1.0
Merge from develop to main for release 2.1.0
2 parents 90d1c2f + b34eb8c commit 8da719d

38 files changed

+8482
-159
lines changed

.gitignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -110,3 +110,7 @@ dmypy.json
110110
# Cython debug symbols
111111
cython_debug/
112112

113+
# pixi environments
114+
.pixi
115+
pixi.lock
116+
*.egg-info

.zenodo.json

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,11 @@
7474
"orcid": "https://orcid.org/0009-0006-7361-163X",
7575
"affiliation": "Independent Contributor, Australia",
7676
"name": "Bluett, Liam"
77+
},
78+
{
79+
"orcid": "https://orcid.org/0000-0003-3271-6874",
80+
"affiliation": "Australian National University, Australia",
81+
"name": "Squire, Dougal T."
7782
}
7883
],
7984
"license": "Apache-2.0",

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,10 +20,10 @@ Below is a **curated selection** of the metrics, tools and statistical tests inc
2020
|----------------------- |----------------- |-------------- |
2121
| **[Continuous](https://scores.readthedocs.io/en/stable/included.html#continuous)** |Scores for evaluating single-valued continuous forecasts. |MAE, MSE, RMSE, Additive Bias, Multiplicative Bias, Percent Bias, Pearson's Correlation Coefficient, Kling-Gupta Efficiency, Flip-Flop Index, Quantile Loss, Quantile Interval Score, Interval Score, Murphy Score, and threshold weighted scores for expectiles, quantiles and Huber Loss. |
2222
| **[Probability](https://scores.readthedocs.io/en/stable/included.html#probability)** |Scores for evaluating forecasts that are expressed as predictive distributions, ensembles, and probabilities of binary events. |Brier Score, Continuous Ranked Probability Score (CRPS) for Cumulative Density Functions (CDF) and ensembles (including threshold weighted versions), Receiver Operating Characteristic (ROC), Isotonic Regression (reliability diagrams). |
23-
| **[Categorical](https://scores.readthedocs.io/en/stable/included.html#categorical)** |Scores for evaluating forecasts of categories. |18 binary contingency table (confusion matrix) metrics and the FIxed Risk Multicategorical (FIRM) Score. |
23+
| **[Categorical](https://scores.readthedocs.io/en/stable/included.html#categorical)** |Scores for evaluating forecasts of categories. |18 binary contingency table (confusion matrix) metrics, the FIxed Risk Multicategorical (FIRM) Score, and the SEEPS score. |
2424
| **[Spatial](https://scores.readthedocs.io/en/stable/included.html#spatial)** |Scores that take into account spatial structure. |Fractions Skill Score. |
2525
| **[Statistical Tests](https://scores.readthedocs.io/en/stable/included.html#statistical-tests)** |Tools to conduct statistical tests and generate confidence intervals. |Diebold Mariano. |
26-
| **[Processing Tools](https://scores.readthedocs.io/en/stable/included.html#processing-tools-for-preparing-data)** |Tools to pre-process data. |Data matching, Discretisation, Cumulative Density Function Manipulation. |
26+
| **[Processing Tools](https://scores.readthedocs.io/en/stable/included.html#processing-tools-for-preparing-data)** |Tools to pre-process data. |Data matching, Discretisation, Block Bootstrapping, and Cumulative Density Function Manipulation. |
2727
| **[Emerging](https://scores.readthedocs.io/en/stable/included.html#emerging)** |Emerging scores that are still undergoing mathematical peer review. They may change in line with the peer review process. |Risk Matrix Score. |
2828

2929
`scores` not only includes common scores (e.g., MAE, RMSE), it also includes novel scores not commonly found elsewhere (e.g., FIRM, Flip-Flop Index), complex scores (e.g., threshold weighted CRPS), and statistical tests (e.g., the Diebold Mariano test). Additionally, it provides pre-processing tools for preparing data for scores in a variety of formats including cumulative distribution functions (CDF). `scores` provides its own implementations where relevant to avoid extensive dependencies.

docs/api.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@
2424
.. autofunction:: scores.continuous.multiplicative_bias
2525
.. autofunction:: scores.continuous.pbias
2626
.. autofunction:: scores.continuous.kge
27+
.. autofunction:: scores.continuous.nse
2728
.. autofunction:: scores.continuous.isotonic_fit
2829
.. autofunction:: scores.continuous.consistent_expectile_score
2930
.. autofunction:: scores.continuous.consistent_quantile_score
@@ -68,6 +69,7 @@
6869
:members:
6970
.. autoclass:: scores.categorical.EventOperator
7071
:members:
72+
.. autofunction:: scores.categorical.seeps
7173
```
7274

7375
## scores.spatial
@@ -87,6 +89,7 @@
8789

8890
## scores.processing
8991
```{eval-rst}
92+
.. autofunction:: scores.processing.block_bootstrap
9093
.. autofunction:: scores.processing.isotonic_fit
9194
.. autofunction:: scores.processing.broadcast_and_match_nan
9295
.. autofunction:: scores.processing.comparative_discretise

docs/conf.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99

1010
project = "scores"
1111
copyright = "Licensed under Apache 2.0 - https://www.apache.org/licenses/LICENSE-2.0"
12-
release = "2.0.0"
12+
release = "2.1.0"
1313

1414
version = __version__
1515

docs/data.md

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ To use `scores` with [GRIB](https://codes.wmo.int/grib2) data, install [cfgrib](
2020

2121
### Working with NetCDF Data
2222

23-
To use `scores` with [NetCDF](https://doi.org/10.5065/D6H70CW6) or [HDF5](https://github.com/HDFGroup/hdf5) data, install [h5netcdf](https://github.com/h5netcdf/h5netcdf). The h5netcdf library is included in the `scores` ["all"](installation.md#all-dependencies-excludes-some-maintainer-only-packages) and ["tutorial"](installation.md#tutorial-dependencies) installation options. Opening NetCDF data is demonstrated in [this tutorial](project:./tutorials/First_Data_Fetching.md).
23+
To use `scores` with [NetCDF](https://doi.org/10.5065/D6H70CW6) or [HDF5](https://github.com/HDFGroup/hdf5) data, install [h5netcdf](https://github.com/h5netcdf/h5netcdf). The h5netcdf library is included in the `scores` ["all"](installation.md#all-dependencies-excludes-some-maintainer-only-packages) and ["tutorial"](installation.md#tutorial-dependencies) installation options. Opening NetCDF data is demonstrated in [this tutorial](project:./tutorials/First_Data_Fetching.md).
2424

2525
## Weather and Climate Data
2626

@@ -35,13 +35,17 @@ Global numerical weather prediction (NWP) models are used to generate medium ran
3535
Archived datasets are available for:
3636

3737
- Bureau of Meteorology's Australian Parallel Suite version 3 (APS3) Australian Community Climate and Earth-System Simulator (ACCESS), see [https://doi.org/10.25914/608a993391647](https://doi.org/10.25914/608a993391647).
38+
- [WeatherBench 2](https://weatherbench2.readthedocs.io/en/latest/data-guide.html) contains forecasts with data-driven (AI) and physical NWP models on a common grid. The [twCRPS for ensemble forecasts tutorial](project:./tutorials/Threshold_Weighted_CRPS_for_Ensembles.md) shows how to use this data with `scores`.
3839
- National Oceanic and Atmospheric Administration (NOAA) Global Forecast System (GFS), see [https://www.ncei.noaa.gov/products/weather-climate-models/global-forecast](https://www.ncei.noaa.gov/products/weather-climate-models/global-forecast).
40+
- An archive of AI weather models going back to October 2020 is hosted at [https://noaa-oar-mlwp-data.s3.amazonaws.com/index.html](https://noaa-oar-mlwp-data.s3.amazonaws.com/index.html) as part of the Open Data Dissemination program. It contains, FourCastNet v2-small, Pangu-Weather, and GraphCast Operational data. It is updated twice a day. You can read more about it in their [paper](https://doi.org/10.1175/BAMS-D-24-0057.1).
3941

4042
#### Point-Based Data
4143

4244
Point-based observations (e.g. from weather stations or buoys) are shared routinely between countries for the purposes of weather modelling.
4345

44-
The NOAA Integrated Surface Database (ISD) provides hourly point-based (*in-situ*) weather station data globally. It is a good starting point for understanding how to work with point-based data. For more information about the NOAA ISD see [https://www.ncei.noaa.gov/products/land-based-station/integrated-surface-database](https://www.ncei.noaa.gov/products/land-based-station/integrated-surface-database).
46+
- The NOAA Integrated Surface Database (ISD) provides hourly point-based (*in-situ*) weather station data globally. It is a good starting point for understanding how to work with point-based data. For more information about the NOAA ISD see [https://www.ncei.noaa.gov/products/land-based-station/integrated-surface-database](https://www.ncei.noaa.gov/products/land-based-station/integrated-surface-database).
47+
- [WeatherReal](https://github.com/microsoft/WeatherReal-Benchmark) contains quality controlled weather station data that uses the ISD. You can read more about WeatherReal in the [pre-print](https://doi.org/10.48550/arXiv.2409.09371).
48+
- The [Iowa Environmental Mesonet](https://mesonet.agron.iastate.edu/) contains a rich variety of datasets. One particularly useful dataset is the [1-minute Automated Surface Observing Network (ASOS) data](https://mesonet.agron.iastate.edu/request/asos/1min.phtml).
4549

4650
#### Gridded Model Reanalysis Data
4751

docs/included.md

Lines changed: 17 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -101,6 +101,10 @@
101101
[Tutorial](project:./tutorials/Murphy_Diagrams.md)
102102
-
103103
[Ehm et al. (2016) - Corollary 2 (p.521)](https://doi.org/10.1111/rssb.12154); [Taggart (2022) - Corollary 5.6](https://doi.org/10.1214/21-ejs1957)
104+
* - Nash-Sutcliffe Model Efficiency Coefficient (NSE)
105+
- [API](api.md#scores.continuous.nse)
106+
- [Tutorial](project:./tutorials/NSE.md)
107+
- [Nash and Sutcliffe (1970)](https://doi.org/10.1016/0022-1694%2870%2990255-6)
104108
* - Pearson's Correlation Coefficient
105109
- [API](api.md#scores.continuous.correlation.pearsonr)
106110
- [Tutorial](project:./tutorials/Pearsons_Correlation.md)
@@ -559,6 +563,10 @@
559563
- [API](api.md#scores.categorical.probability_of_false_detection)
560564
- [Tutorial](project:./tutorials/ROC.md)
561565
- [Probability of false detection (WWRP/WGNE Joint Working Group on Forecast Verification Research)](https://www.cawcr.gov.au/projects/verification/#POFD)
566+
* - Stable Equitable Error in Probability Space (SEEPS)
567+
- [API](api.md#scores.categorical.seeps)
568+
- [Tutorial](project:./tutorials/SEEPS.md)
569+
- [Rodwell et al. (2010)](https://doi.org/10.1002/qj.656)
562570
* - Threshold Event Operator
563571
- [API](api.md#scores.categorical.ThresholdEventOperator)
564572
- [Tutorial](project:./tutorials/Binary_Contingency_Scores.md)
@@ -649,6 +657,9 @@
649657
* - Binary Discretise Proportion
650658
- [API](api.md#scores.processing.binary_discretise_proportion)
651659
- Flip-Flop Index
660+
* - Block Bootstrap
661+
- [API](api.md#scores.processing.block_bootstrap)
662+
- Confidence intervals. See [tutorial](project:./tutorials/Block_Bootstrapping.md)
652663
* - Broadcast and Match Not-a-Number (NaN)
653664
- [API](api.md#scores.processing.broadcast_and_match_nan)
654665
- Murphy Score (Mean Elementary Score)
@@ -764,15 +775,18 @@
764775
- Risk Matrix Score
765776
- [API](api.md#scores.emerging.risk_matrix_score)
766777
- [Tutorial](project:./tutorials/Risk_Matrix_Score.md)
767-
- Taggart, R. J., & Wilke, D. J. (2024). Warnings based on risk matrices: a coherent framework with consistent evaluation. In preparation.
778+
- [Taggart and Wilke (2025)](https://doi.org/10.48550/arXiv.2502.08891)
779+
768780
* -
769781
- Risk Matrix Score - Matrix Weights to Array
770782
- [API](api.md#scores.emerging.matrix_weights_to_array)
771783
- [Tutorial](project:./tutorials/Risk_Matrix_Score.md)
772-
- Taggart, R. J., & Wilke, D. J. (2024). Warnings based on risk matrices: a coherent framework with consistent evaluation. In preparation.
784+
- [Taggart and Wilke (2025)](https://doi.org/10.48550/arXiv.2502.08891)
785+
773786
* -
774787
- Risk Matrix Score - Warning Scaling to Weight Array
775788
- [API](api.md#scores.emerging.weights_from_warning_scaling)
776789
- [Tutorial](project:./tutorials/Risk_Matrix_Score.md)
777-
- Taggart, R. J., & Wilke, D. J. (2024). Warnings based on risk matrices: a coherent framework with consistent evaluation. In preparation.
790+
- [Taggart and Wilke (2025)](https://doi.org/10.48550/arXiv.2502.08891)
791+
778792
```

docs/installation.md

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -126,3 +126,49 @@ A sample command to register a new kernel is:
126126

127127
[https://jupyter-tutorial.readthedocs.io/en/24.1.0/kernels/install.html](https://jupyter-tutorial.readthedocs.io/en/24.1.0/kernels/install.html) provides additional technical details regarding the registration of kernels.
128128

129+
## Using `pixi` for Environment Management (Optional)
130+
131+
An optional, alternative, approach that `scores` supports for installing environments is [`pixi`](https://pixi.sh).
132+
`pixi` is a powerful environment management tool.
133+
134+
It uses a combination of PyPI and Conda channels. `pixi` is configured in `pyproject.toml` in the
135+
root directory of the `scores` GitHub repository. It is configured with some default tasks that a
136+
user can run in ephemeral environments specific for those tasks (see examples below).
137+
138+
`pixi` handles creation, swapping, stacking and cleanup of environments automatically, depending on
139+
the task being run.
140+
141+
```{note}
142+
`scores` currently does not save `pixi.lock` files in its GitHub repository. While `pixi` is
143+
supported in `scores`, it is *not* part of the recommended development toolchain.
144+
145+
`pixi.lock` is intentionally filtered out in `.gitignore`, in order to prevent accidental commits of
146+
the lock file. This may change in the future if there is sufficient adoption.
147+
148+
`pixi` is mainly there for users who *already* are familiar with it, and those who prefer not to
149+
manually deal with python environments.
150+
```
151+
152+
### Installation
153+
154+
`pixi` supports multiple platforms. Its installation process is straightforward and can be found
155+
here: <https://pixi.sh/latest/#installation>.
156+
157+
### Examples
158+
159+
- **As a developer** I want to run some tests.
160+
- Command: `pixi run pytest-src`
161+
- Description: this will test the source code in the `dev` environment.
162+
- **As a researcher** I want to launch JupyterLab.
163+
- Command: `pixi run jupyterlab`
164+
- Description: this will launch a local JupyterLab server in the `tutorial` environment.
165+
- **As a maintainer** I want to render the docs as html.
166+
- Command: `pixi run make-docs`
167+
- Description: this will render the docs locally to "htmldocs" (similar to what the GitHub
168+
pipeline currently does).
169+
- **As any user** I want to run a specified command in a particular environment.
170+
- Command: `pixi run -e <env> <cmd>`, where `<env> = dev | tutorial | maintainer | all` - see
171+
section on [installation options](#installation-options) above.
172+
- Description: this will run the command in the specified environment, and return you back to the
173+
original shell once it has been executed.
174+

docs/release_notes.md

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,47 @@
11
# Release Notes (What's New)
22

3+
## Version 2.1.0 (April 30, 2025)
4+
5+
For a list of all changes in this release, see the [full changelog](https://github.com/nci/scores/compare/2.0.0...2.1.0). Below are the changes we think users may wish to be aware of.
6+
7+
### Features
8+
9+
- Added a new fuction:
10+
- Block bootstrap: `scores.processing.block_bootstrap`. See [PR #418](https://github.com/nci/scores/pull/418).
11+
- Added two new metrics:
12+
- Stable equitable error in probability space (SEEPS): `scores.categorical.seeps`. See [PR #809](https://github.com/nci/scores/pull/809) and [PR #833](https://github.com/nci/scores/pull/833).
13+
- Nash-Sutcliffe model efficiency coefficient (NSE): `scores.continuous.nse`. See [PR #815](https://github.com/nci/scores/pull/815).
14+
15+
### Documentation
16+
17+
- Added "Block Bootstrapping" tutorial. See [PR #418](https://github.com/nci/scores/pull/418).
18+
- Added "Stable Equitable Error in Probability Space (SEEPS)" tutorial. See [PR #809](https://github.com/nci/scores/pull/809).
19+
- Added "Nash-Sutcliffe Efficiency (NSE)" tutorial. See [PR #815](https://github.com/nci/scores/pull/815).
20+
- Updated the "Continuous Ranked Probability Score (CRPS) for Ensembles" tutorial:
21+
- Labelled dimensions in fcst/obs data.
22+
- Updated description of the plot to say the area squared corresponds to the CRPS.
23+
- Added an example with multiple coordinates along a dimension.
24+
See [PR #805](https://github.com/nci/scores/pull/805).
25+
- Updated "Data Sources":
26+
- Added links to two additional datasets for gridded global numerical weather prediction.
27+
- Added links to several additional datasets for point-based data.
28+
See [PR #823](https://github.com/nci/scores/pull/823) and [PR #831](https://github.com/nci/scores/pull/831).
29+
- Updated references in several sections of the documentation, following the publication of a [preprint](https://doi.org/10.48550/arXiv.2502.08891) for the risk matrix score. See [PR #827](https://github.com/nci/scores/pull/827).
30+
31+
### Internal Changes
32+
33+
- Tested and added compatibility for recent Xarray versions (2025 and onwards) and adjusted dependency specification so new year "major version" rollovers will be permitted by default in future. See [commit #f109f2f](https://github.com/nci/scores/commit/f109f2f434ac684b3d54f447c330466d33703279) and [commit #8428d64](https://github.com/nci/scores/commit/8428d64dcf2a5f5480c61b266284260d4b5078d2).
34+
- In `scores.emerging.weights_from_warning_scaling`, changed the name of the argument `assessment_weights` to `evaluation_weights`. See [PR #806](https://github.com/nci/scores/issues/806).
35+
***Note:** This is technically a breaking change, but does not trigger a major release as it is contained within the "emerging" section of the API. This area of the API is designated for metrics which are still undergoing peer review and as such are expected to undergo change. Once peer review is concluded, the implementation will be finalised and moved.*
36+
- Add support for developers of `scores` who choose to use the `pixi` tool for environment management. See [PR #835](https://github.com/nci/scores/pull/835), [PR #839](https://github.com/nci/scores/pull/839) and [PR #840](https://github.com/nci/scores/pull/840).
37+
38+
### Contributors to this Release
39+
40+
Dougal T. Squire* ([@dougiesquire](https://github.com/dougiesquire)), Mohammad Mahadi Hasan* ([@engrmahadi](https://github.com/engrmahadi)), Mohammadreza Khanarmuei ([@reza-armuei](https://github.com/reza-armuei)), Nikeeth Ramanathan ([@nikeethr](https://github.com/nikeethr)) Tennessee Leeuwenburg ([@tennlee](https://github.com/tennlee)), Nicholas Loveday ([@nicholasloveday](https://github.com/nicholasloveday)),
41+
Robert J. Taggart ([@rob-taggart](https://github.com/rob-taggart)), Durga Shrestha ([@durgals](https://github.com/durgals)) and Stephanie Chong ([@Steph-Chong](https://github.com/Steph-Chong)).
42+
43+
\* indicates that this release contains their first contribution to `scores`.
44+
345
## Version 2.0.0 (December 7, 2024)
446

547
For a list of all changes in this release, see the [full changelog](https://github.com/nci/scores/compare/1.3.0...2.0.0). Below are the changes we think users may wish to be aware of.

0 commit comments

Comments
 (0)