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

Hackathon July 2023 #351

Merged
merged 18 commits into from
Apr 24, 2024
Merged

Hackathon July 2023 #351

merged 18 commits into from
Apr 24, 2024

Conversation

mpvginde
Copy link
Contributor

This pull request brings all developments made during the July 2023 pySTEPS-hackathon at the RMIB.
Many thanks to all contributors: @ladc, @RubenImhoff, Simon De Kock and Ricardo Reinoso-Rondinel.

The work was focussed on the STEPS blending routine.

NEW FEATURES

  1. Scientificaly correct handling of following cases when using STEPS blending (linked with How to handle no rain in pysteps? #309)
  • No rain in radar fields | No rain in NWP fields
  • No rain in rader fiels | Rain in NWP fields

REFACTORING (all linked with #332)

  1. Initialisation of the noise cascade with random noise (with correct spatial correlation) to have correct power
  2. Renormalize radar extrapolation cascade after AR(2)-evolution to not lose power
  3. STEPS Blending extrapolation component:
  • Precipiation and noise cascade are recomposed before advection
  • Both fields are advected
  • They are decomposed again for blending with NWP cascade
    This removes the loss of power in the smallest scales due to the interpolation needed for the semilagrangian advection.
    In addition computational cost is reduced because the number of extrapolation is greatly reduced.

BUGFIXES

  • Decoding issue for loading older (RMI) ODIM HDF5-files
  • Avoid accidentally masking precip arrays by passing a copy to spatial_correlation

mpvginde and others added 14 commits March 27, 2024 12:48
This allows some flexibility for when we consider the radar rainfall field to contain "no rain", since there will usually be some clutter present even when it's dry.
The same does not hold for NWP, since there is no clutter there.

This also introduces the new utility function blending.utils.check_norain
    -Precipiation and noise cascade are recomposed before extrapolation
    -Both fields are advected
    -They are decomposed again
This removes the loss of power in the smallest scales due to the interpolation needed for the
semilagrangian advection.
In addition computational cost is reduced because the number of
extrapolation is greatly reduced.
…t grid cells instead of the maximum per grid cell in NWP
- blending.utils.check_norain
- load NWP
- No rain cases
Copy link
Contributor

@RubenImhoff RubenImhoff left a comment

Choose a reason for hiding this comment

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

Great to see the PR, @mpvginde! :)

pysteps/blending/steps.py Outdated Show resolved Hide resolved
@dnerini
Copy link
Member

dnerini commented Apr 3, 2024

some of the tests were failing for the same reason as in #352 , @mpvginde can you please merge master into this branch to see if that solves the issue?

there are however many other failing tests, are you looking into these?

@RubenImhoff
Copy link
Contributor

I made some changes which should (hopefully) fix the issues that came from the tests. @ladc, which tests did you still want to add? We might be good to go after that.

@RubenImhoff
Copy link
Contributor

The tests on Ubuntu fail due to a problem with uploading the Codecov report - not sure what is causing it, but it seems unrelated to the PR.

@dnerini
Copy link
Member

dnerini commented Apr 23, 2024

yes I agree, we can ignore the failing test in the context of this PR. If @ladc has no further comments or changes to add, I think we can merge it!

@dnerini dnerini merged commit 2a408d8 into pySTEPS:master Apr 24, 2024
6 of 8 checks passed
@mpvginde
Copy link
Contributor Author

Thanks everyone for helping with this PR!

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

Successfully merging this pull request may close these issues.

4 participants