pysteps.cascade.bandpass_filters.filter_gaussian

pysteps.cascade.bandpass_filters.filter_gaussian#

pysteps.cascade.bandpass_filters.filter_gaussian(shape, n, gauss_scale=0.5, d=1.0, normalize=True, return_weight_funcs=False, include_mean=True)#

Implements a set of Gaussian bandpass filters in logarithmic frequency scale.

Parameters:
  • shape (int or tuple) – The dimensions (height, width) of the input field. If shape is an int, the domain is assumed to have square shape.

  • n (int) – The number of frequency bands to use. Must be greater than 2.

  • gauss_scale (float) – Optional scaling parameter. Proportional to the standard deviation of the Gaussian weight functions.

  • d (scalar, optional) – Sample spacing (inverse of the sampling rate). Defaults to 1.

  • normalize (bool) – If True, normalize the weights so that for any given wavenumber they sum to one.

  • return_weight_funcs (bool) – If True, add callable weight functions to the output dictionary with the key ‘weight_funcs’.

  • include_mean (bool) – If True, include the first Fourier wavenumber (corresponding to the field mean) to the first filter.

Returns:

out – A dictionary containing the bandpass filters corresponding to the specified frequency bands.

Return type:

dict

References

[PCH18b]