swirlspy.utils package

Utilities

swirlspy.utils.standardize_attr(frames: xarray.core.dataarray.DataArray, **kwargs) → xarray.core.dataarray.DataArray

Fill the missing attribute of data frames.

Parameters:

frames (xarray.DataArray) – Data frames data.

Other Parameters:
 
  • zero_value (float or numpy.nan, optional) – the value assigned to the no rain pixels with the same unit, transformation and accutime of the data. Default : numpy.nan
  • frame_type (swirlspy.utils.FrameType, optional) – the value indicated frames’ value type.
class swirlspy.utils.FrameType

Bases: enum.IntFlag

Data frame value type.

Z = 1

Reflectivity, Z

dBR = 10

Decibel relative to rainfall rate, dBmm/h

dBZ = 9

Decibel relative to reflectivity, dBZ

mm = 4

Accumulated rainfall depth, mm

mmph = 2

Rainfall rate, mm/h

swirlspy.utils.add_latlon_ticks(fig, ax, fontsize, frequency)

Adds ticks to projection.

Parameters:
  • fig (matplotlib.Figure) – The Figure instance in which the plot is drawn.
  • ax (matplotlib.axes) – The axes on which the plot is drawn.
  • fontsize (int) – The fontsize desired.
  • frequency (float) – The degree intervals.