wradlib.zr.z_to_r_enhanced¶

wradlib.zr.
z_to_r_enhanced
(z, polar=True, shower=True)¶ Calculates rainrates from radar reflectivities using the enhanced threepart ZRrelationship used by the DWD (as of 2009)
To be used with polar representations so that one dimension is cyclical. i.e. z should be of shape (nazimuths, nbins) –> the first dimension is the cyclical one. For DWD DXData z’s shape is (360,128).
Neighborhoodmeans are taken only for available data via fast convolution sums. Refer to the RADOLAN final report or the RADOLAN System handbook for details on the calculations. Basically, for low reflectivities an index called the shower index is calculated as the mean of the differences along both axis in a neighborhood of 3x3 pixels. This means:
xdirection –>
yldir1
2
3
4
5
6
7
8
9
If 5 is the pixel in question, it’s shower index is calculated as:
\[\begin{split}( &12 + 23 + 45 + 56 + 78 + 89 + \\ &14 + 47 + 25 + 58 + 36 + 69 ) / 12.\end{split}\]then, the upper line of the sum would be diffx (DIFFerences in Xdirection), the lower line would be diffy (DIFFerences in Ydirection) in the code below.
 Parameters
z (
numpy.ndarray
) – Corresponds to reflectivity Z in mm**6/m**3 NDarray, at least 2Dpolar (bool) – defaults to to True (polar data), False for cartesian data.
shower (bool) – output shower index, defaults to True
 Returns
r (
numpy.ndarray
) – r  array of shape z.shape  calculated rain ratessi (
numpy.ndarray
) – si  array of shape z.shape  calculated shower index for control purposes. May be omitted in later versions