pysteps.noise.utils.compute_noise_stddev_adjs¶
-
pysteps.noise.utils.
compute_noise_stddev_adjs
(R, R_thr_1, R_thr_2, F, decomp_method, noise_filter, noise_generator, num_iter, conditional=True, num_workers=1, seed=None)¶ Apply a scale-dependent adjustment factor to the noise fields used in STEPS.
Simulates the effect of applying a precipitation mask to a Gaussian noise field obtained by the nonparametric filter method. The idea is to decompose the masked noise field into a cascade and compare the standard deviations of each level into those of the observed precipitation intensity field. This gives correction factors for the standard deviations [BPS06]. The calculations are done for n realizations of the noise field, and the correction factors are calculated from the average values of the standard deviations.
Parameters: - R : array_like
The input precipitation field, assumed to be in logarithmic units (dBR or reflectivity).
- R_thr_1 : float
Intensity threshold for precipitation/no precipitation.
- R_thr_2 : float
Intensity values below R_thr_1 are set to this value.
- F : dict
A bandpass filter dictionary returned by a method defined in pysteps.cascade.bandpass_filters. This defines the filter to use and the number of cascade levels.
- decomp_method : function
A function defined in pysteps.cascade.decomposition. Specifies the method to use for decomposing the observed precipitation field and noise field into different spatial scales.
- num_iter : int
The number of noise fields to generate.
- conditional : bool
If set to True, compute the statistics conditionally by excluding areas of no precipitation.
- num_workers : int
The number of workers to use for parallel computation. Applicable if dask is installed.
- seed : int
Optional seed number for the random generators.
Returns: - out : list
A list containing the standard deviation adjustment factor for each cascade level.