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

Insert Nowcasting Model PhaSt in the pySTEPS package #329

Open
cescosilve opened this issue May 17, 2023 · 11 comments
Open

Insert Nowcasting Model PhaSt in the pySTEPS package #329

cescosilve opened this issue May 17, 2023 · 11 comments
Assignees
Labels
discussion an open discussion for whole community enhancement New feature or request

Comments

@cescosilve
Copy link

The proposal is to insert the Nowcasting Model PhaSt in the pySTEPS package.
PhaSt (phase-diffusion model for stochastic nowcasting) is a stochastic nowcasting model that uses as input the most recent radar rainfall observations and generates an ensemble of equiprobable rainfall scenarios.
The model is mainly described in Metta et al. (2009) and Poletti et al. (2019).
The use of the spectral space allows to preserve the spatial correlation within the rainfall fields. The evolution of Fourier phases trough the stochastic process generates many realizations, to be used as members of an ensemble of precipitation nowcasts. All the ensemble members are characterized by the same amplitude distribution and very similar power spectra. However, the phase evolution (i.e., the positioning of rainfall structures) evolves differently in the altered realizations, providing an estimate of the probability of occurrence of precipitation at a given point in space and a given instant in time.
PhaSt can be reasonably used stand alone to issue forecast on time windows of 1 to 3 hours, or in synergy with Numerical Weather Prediction Systems aiming at blending approaches.
The idea is implementing a Python code that satisfy the requirements needed to be added among the pySTEPS modules.

reference
Metta, S., Rebora, N., Ferraris, L., von Hardernberg, J., & Provenzale, A. (2009). PHAST: a phase-diffusion model for stochastic nowcasting. J. Hydrometeorol, 10, 1285-1297.
Poletti, M. L., Silvestro, F., Davolio, S., Pignone, F., and Rebora, N.: Using nowcasting technique and data assimilation in a meteorological model to improve very short range hydrological forecasts, Hydrol. Earth Syst. Sci., 23, 3823–3841, https://doi.org/10.5194/hess-23-3823-2019, 2019.

@dnerini dnerini added enhancement New feature or request discussion an open discussion for whole community labels May 17, 2023
@dnerini
Copy link
Member

dnerini commented May 17, 2023

Hi @cescosilve

Very exciting idea! A new PhaSt module would be a great addition to pysteps!

Few immediate questions from my side:

  • Do you plan to implement a radar-only nowcast or including blending, too? Currently these two types are separated in different modules: pysteps.nowcasts include nowcasting methods based on observed precipitation fields only, while pysteps.blending combine extrapolation with NWP forecasts. This is why you can find STEPS in both modules, since the same method can be used in both modes.

  • Do you already have a python implementation or some kind of prototype in python? It would be interesting to know if you need any particular dependency. My guess is that the current dependencies should be enough, but if need be we can also add new optional dependencies.

  • All nowcasting methods in pysteps implement the same interface: forecast(precip, velocity, timesteps, **keywords). Can this apply to PhaSt too or do you see any issue with that?

To make things easier in terms of collaboration, I'd suggest to make you a collaborator of pysteps so that you can create a new feature branch for PhaSt directly here in the pysteps project. This way, we could also actively contribute on the same branch. We would probably mostly help in terms of integration with the rest of the library (tests, docs,...). What do you think?

@cescosilve
Copy link
Author

Hi @dnerini , thanks!
I try to answer by point:

1)Currently we wuold start with radar-only nowcast, but it could be an idea to insert the blending in future. This latter is thought as a separate algorithm (potentially usable with other models)

2)We have a very rough python version of the model and it uses dependencies included in the link you sent. Anyway some modifications and improvements were done in Matlab, so we will explore if new dependencies in python are needed

3)In general yes forecast (precip, velocity, timesteps, **keywords) could be good. Certainly we have to well understand the exact meaning and form of each argument. Velocity is estimated by the phast algorithm so in general it is not needed as input.
In next months we will study a the pysteps package in order to write the code in a feasible way.

Regarding "to make you a collaborator of pysteps so that you can create a new feature branch for PhaSt directly here in the pysteps project". Ok grat thank you! I ask you if you can make as collaborator other my collegues, since we have to organize ourselves about how and who will write the code.

Thank you!!

@dnerini
Copy link
Member

dnerini commented May 18, 2023

1)Currently we wuold start with radar-only nowcast, but it could be an idea to insert the blending in future. This latter is thought as a separate algorithm (potentially usable with other models)

This makes perfect sense!

2)We have a very rough python version of the model and it uses dependencies included in the link you sent. Anyway some modifications and improvements were done in Matlab, so we will explore if new dependencies in python are needed

Very good. One strategy could also be to start with a very basic implementation and then add new features progressively. We can very easily release new versions. If you have a student that is interested in such a work, one option can also be to write a model description paper. It could be on GMD (as the original pysteps publications) or elsewhere. Recently, @RubenImhoff published a paper about his implementation of STEPS blending in pysteps, see https://doi.org/10.1002/qj.4461

3)In general yes forecast (precip, velocity, timesteps, **keywords) could be good. Certainly we have to well understand the exact meaning and form of each argument. Velocity is estimated by the phast algorithm so in general it is not needed as input. In next months we will study a the pysteps package in order to write the code in a feasible way.

This interface is not very strict and of course it should adapt to the specifications of each method. precip is a 3D numpy array with the input sequence of radar fields (n_t, n_y, n_x). velocity is a 3D array with the u and v components of the motion field (2, n_y, n_y). In your case it can be omitted. timesteps is either an integer specifying the number of lead times or the array of time steps to be forecasted. After this, any arbitrary keyword argument can be added.

Regarding "to make you a collaborator of pysteps so that you can create a new feature branch for PhaSt directly here in the pysteps project". Ok grat thank you! I ask you if you can make as collaborator other my collegues, since we have to organize ourselves about how and who will write the code.

Of course, just let me know the usernames of your colleagues that will be working on this.

@cescosilve
Copy link
Author

Ok thank you for the precious information. Fabio Delogu (user: fabiodelogu ) is one of the guys ,

@cescosilve
Copy link
Author

Other collegue: Flavio Pignone user: flaviopignone

@dnerini
Copy link
Member

dnerini commented May 19, 2023

Done! I created a dedicated PhaSt team (you should have received an invitation) which has write permissions to the pysteps repo.

@cescosilve
Copy link
Author

Hi PhaSt team can be accessed by flaviopignone and fabiodelogu? Or can I insert them in the team?

@dnerini
Copy link
Member

dnerini commented May 23, 2023

hi @cescosilve you are now maintainer of the team and can add new members. @flaviopignone and @fabiodelogu have pending invitations, didn't they receive it?

@cescosilve
Copy link
Author

Hi sorry for late, now they are in the phast teams. I need to add "laura-poletti", but it seems that i cannot do this from the teams. Is it??

@dnerini
Copy link
Member

dnerini commented Jun 5, 2023

mmh maybe you can only add users if they're already part of the pySTEPS organization? Anyway, I just sent an invitation to @laura-poletti.

@cescosilve
Copy link
Author

perfect, thanks, received!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
discussion an open discussion for whole community enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

4 participants