wradlib.io.radolan.read_radolan_composite

wradlib.io.radolan.read_radolan_composite#

wradlib.io.radolan.read_radolan_composite(f, *, missing=-9999, loaddata=True, fillmissing=False)[source]#

Read quantitative radar composite format of the German Weather Service

The quantitative composite format of the DWD (German Weather Service) was established in the course of the RADOLAN project and includes several file types, e.g. RX, RO, RK, RZ, RP, RT, RC, RI, RG, PC, PG and many, many more. (see format description on the RADOLAN project homepage [DWD, 2009]). At the moment, the national RADOLAN composite is a 900 x 900 grid with 1 km resolution and in polar-stereographic projection. There are other grid resolutions for different composites (e.g. PC, PG)

Note

DWD also provides data in ASCII format, which have a very limited header and need to extract product and datetime from the filename. Use on your own risk.

Added in version 1.17.

Warning

This function already evaluates and applies the so-called PR factor which is specified in the header section of the RADOLAN files. The raw values in an RY file are in the unit 0.01 mm/5min, while read_radolan_composite returns values in mm/5min (e.g. factor 100 higher). The factor is also returned as part of attrs dictionary under keyword “precision”.

Note

You might also use wradlib.io.radolan.open_radolan_dataset or xarray.open_dataset with keyword engine=’radolan’ to import into xarray Dataset.

Parameters:
  • f (str or file-like) – path to the composite file or file-like object

  • missing (int) – value assigned to no-data cells

  • loaddata (bool) – True | False, If False function returns (None, attrs)

  • fillmissing (bool) – If True fills truncated values with “missing”. Defaults to False. Does not work for run-length encoded files (“PC” and “PG).

Returns:

output (tuple) –

tuple of two items (data, attrs):
  • data : numpy.ndarray of shape (number of rows, number of columns) or xarray.Dataset

  • attrs : dict of metadata information from the file header

Examples

See RADOLAN data formats.