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

Support providing a static additional predictor when applying EMOS coefficients #1591

Merged

Conversation

gavinevans
Copy link
Contributor

Closes #1547

Description
This PR adds support for providing a static additional predictor within the apply EMOS CLI. This PR therefore contains updates to the apply EMOS CLI and associated acceptance tests. Updates to the code to separate the additional predictors from the other inputs and updates to the associated unit tests. Minor edits to a few other files, most notably to support using a spot forecast (rather than a gridded forecast) as a probability template.

Testing:

  • Ran tests and they passed OK
  • Added new tests for the new feature(s)

@gavinevans gavinevans added this to the 1.0.0 milestone Oct 21, 2021
@gavinevans gavinevans self-assigned this Oct 21, 2021
@codecov
Copy link

codecov bot commented Oct 21, 2021

Codecov Report

Merging #1591 (e15edc5) into master (f63415a) will increase coverage by 0.02%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1591      +/-   ##
==========================================
+ Coverage   98.03%   98.05%   +0.02%     
==========================================
  Files         109      109              
  Lines        9817     9930     +113     
==========================================
+ Hits         9624     9737     +113     
  Misses        193      193              
Impacted Files Coverage Δ
improver/calibration/__init__.py 100.00% <100.00%> (ø)
improver/calibration/ensemble_calibration.py 100.00% <100.00%> (ø)
...semble_copula_coupling/ensemble_copula_coupling.py 99.05% <100.00%> (+<0.01%) ⬆️
improver/utilities/cube_checker.py 100.00% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update f63415a...e15edc5. Read the comment docs.

@gavinevans gavinevans removed their assignment Oct 22, 2021
Copy link
Contributor

@bayliffe bayliffe left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Small comments.

@MoseleyS MoseleyS self-assigned this Oct 25, 2021
Copy link
Contributor

@MoseleyS MoseleyS left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We ought to fix the title attributes of these files, but in the interests of time, this can be follow-on work.

a0112b5a48ba99a1a4a345d43b0c453caaf25181504fb9a13786b5722f84cc10 ./apply-emos-coefficients/sites/offset/coefficients.nc
22d950494dc9d76d642b0ecc75414e95bfb78fa693e5701fe7cd2fc462a0c6a7 ./apply-emos-coefficients/sites/offset/kgo.nc
2722b1d08a87cebf1f36ac914d5badb9af38859b2150da83311dc202ce9be4dd ./apply-emos-coefficients/sites/offset/offset_input.nc
3c496867a4a77a4627426b79d8d963a83590b5440984cc2d7a31085cc0efbe10 ./apply-emos-coefficients/sites/percentile_input.nc
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This file breaks the meta-data convention (title attribute needs "Post-Processed" in the right place)

Comment on lines +22 to +24
e610e4329ef038a5f91e190a3312c24b3e742000a35068268a8c17b9bc83944e ./apply-emos-coefficients/sites/additional_predictor/percentile_kgo.nc
60edea7a92af49d6afd10c687fd3f780caa8cd6f8a3bc29d33d5b3e618c949d8 ./apply-emos-coefficients/sites/additional_predictor/probability_kgo.nc
a3bfead4d08e7ec2ac66067cd16d041b1aabe32eb242f3e072c67efd1d10d8f2 ./apply-emos-coefficients/sites/additional_predictor/probability_template.nc
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These three files break the meta-data convention (title attributes needs "Post-Processed" in the right place)

@MoseleyS MoseleyS merged commit 69c141f into metoppv:master Oct 25, 2021
@MoseleyS MoseleyS assigned gavinevans and unassigned MoseleyS Oct 25, 2021
gavinevans added a commit to gavinevans/improver that referenced this pull request Oct 25, 2021
…lar_ingestion_cli_fp_format

* upstream/master:
  Add CLI for ingesting tabular forecasts and observations into EMOS (metoppv#1592)
  Support providing a static additional predictor when applying EMOS coefficients (metoppv#1591)
  Move dataframe to cube utilities (metoppv#1593)
  Added constant for ultraviolet_index_daytime_max. (metoppv#1590)
MoseleyS pushed a commit to MoseleyS/improver that referenced this pull request Aug 22, 2024
…efficients (metoppv#1591)

* Modifications to add support for passing in an additional predictor when applying the EMOS coefficients.

* Add check for a mismatch in sites between the forecast and the additional predictor.

* Minor updates following review comments.

* Black.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Support alternative output formats following application of EMOS
3 participants