wradlib / wradlib-notebooks

wradlib jupyter notebooks
MIT License
13 stars 18 forks source link

Updated list of RADOLAN radar network locations #49

Closed amotl closed 3 years ago

amotl commented 3 years ago

Dear @kmuehlbauer and @heistermann,

I just wanted to let you know that we updated the list of RADOLAN radar network locations you are also using within [1]. You will find both a) some routines to parse the data from DWD's PDF file [2] as well as b) an updated data structure in Python format at [3].

I am currently unable to find back the reference, but I slightly remember Kai told us that he always wanted to bring your list [1] up to date, so here you go.

You can either copy RADAR_LOCATIONS to your notebook or directly reuse our wetterdienst library similar to the updated notebook [4] like

>>> from wetterdienst.dwd.radar.sites import RADAR_LOCATIONS
>>> print(RADAR_LOCATIONS)

With kind regards, Andreas.

[1] https://github.com/wradlib/wradlib-notebooks/blob/master/notebooks/radolan/radolan_network.ipynb [2] https://www.dwd.de/DE/derdwd/messnetz/atmosphaerenbeobachtung/_functions/HaeufigGesucht/koordinaten-radarverbund.pdf?__blob=publicationFile [3] https://github.com/earthobservations/wetterdienst/blob/v0.13.0/wetterdienst/dwd/radar/sites.py [4] https://docs.wradlib.org/en/stable/notebooks/fileio/wradlib_load_DWD_opendata_volumes.html#Download-radar-volumes-of-latest-2-hours-from-server-using-wetterdienst

kmuehlbauer commented 3 years ago

Hi @amotl thanks for raising this and providing a nice solution. I think that using wetterdienst to retrieve the DWD radar locations will be best. So expect this to change in the notebooks soon.

kmuehlbauer commented 3 years ago

@amotl The current pdf document does only contain current radar locations AFAICT. So it does not contain EMD (Emden) radar. But naturally all radar locations (past and present) should be available. Shall I open an issue over at wetterdienst?

amotl commented 3 years ago

The current pdf document koordinaten-radarverbund.pdf does not contain EMD (Emden) radar.

Thanks for the heads up, Kai. I've just submitted https://github.com/earthobservations/wetterdienst/pull/335. Can you verify it?

amotl commented 3 years ago

Hi Kai,

at https://github.com/earthobservations/wetterdienst/pull/335#issuecomment-773665067, I just reported that Emden (EMD) already went out of service. So, do you believe it would be make sense to remove it again?

With kind regards, Andreas.

amotl commented 3 years ago

At https://github.com/earthobservations/wetterdienst/pull/335#issuecomment-768498142, I said

Now, when looking at the situation again, the document Metadata on the radars of the DWD radar network (koordinaten-radarverbund.pdf) was updated in April, 2018 while the document Description of the "Komposit-Format" Version 2.5.1 (radolan_radvor_op_komposit_format_pdf.pdf) was updated in October, 2020.

So, I conclude we should actually adjust the PDF parser [1] to use the more recently updated document as a reference. After distilling a patch from that, we will see what might have changed. To go forward on this, I will merge this patch and then eventually submit another one.

[1] https://github.com/earthobservations/wetterdienst/blob/v0.13.0/wetterdienst/dwd/radar/sites.py#L178-L287

This is actually not required. I just compared the coordinates of the active radar sites within both PDF documents and they are identical. So, I believe we do not need to update the PDF parser unless you also would like to see the historical, now defunct sites to be available within the list wetterdienst.dwd.radar.sites.RADAR_LOCATIONS?

However, pages 17-19 within the second, more recent PDF document, also list other European sites where the RADOLAN-ME-Komposit is derived from. Do you have any need for them to be available in a machine readable format, Kai?

kmuehlbauer commented 3 years ago

However, pages 17-19 within the second, more recent PDF document, also list other European sites where the RADOLAN-ME-Komposit is derived from. Do you have any need for them to be available in a machine readable format, Kai?

I might not have immediate need, but usually users have. So the RADOLAN composite contains a string in the header which lists all radar sites used to create that composite. In some cases users might want to know where a particular site is located. So if there is a neat way of providing these radar sites this would be of benefit.

amotl commented 3 years ago

Thanks. While implementing the tests for radar data acquisition, I didn't see any European stations within the headers of the files I touched. But I also don't have the full picture.

At https://github.com/earthobservations/wetterdienst/pull/335#issuecomment-773805564, you also said:

As DWD keeps historic RADOLAN data and this data is widely used for scientific purposes it would be good to have all radar site locations available.

So, I will just go ahead and try to get all stations parsed into a machine readable format in the outlook that it will be useful for some people out there doing scientific work on top of those.

At https://github.com/earthobservations/wetterdienst/pull/335#issuecomment-768498142, I also said:

On the other hand, it obviously would be perfect if we could find a machine readable source for this data. But this is still amiss as far as you know?

Maybe some other organization in Europe already publishes a list of those radar sites including the ones in Germany in a machine readable format already? It would be too good to be true.

kmuehlbauer commented 3 years ago

@amotl There is some information on the OPERA website [1]. But it seems it is only available as a map overlay [2]. Maybe this information is also available via another mechanism. B

[1] https://www.eumetnet.eu/activities/observations-programme/current-activities/opera/ [2] https://www.eumetnet.eu/wp-content/themes/aeron-child/observations-programme/current-activities/opera/database/OPERA_Database/index.html

amotl commented 3 years ago

Maybe this information is also available via another mechanism.

Yes it is, see [3]. Very nice, thank you! I believe it will be no problem to adhere to their format and indexing this list by ODIM codes like deasb, deemd, deoft and so forth?

[3] https://www.eumetnet.eu/wp-content/themes/aeron-child/observations-programme/current-activities/opera/database/OPERA_Database/OPERA_RADARS_DB.json

amotl commented 3 years ago

The list also contains some of the stations already out of service, at least I can see "Emden" here:

$ http https://www.eumetnet.eu/wp-content/themes/aeron-child/observations-programme/current-activities/opera/database/OPERA_Database/OPERA_RADARS_DB.json | jq '[ .[] | select(.status == "0") | .location ] | sort'
[
  "Bajsa",
  "Beograd-LAWR",
  "Beograd-MRL5",
  "Besnjaja",
  "Bukulja",
  "Crni vrh",
  "De Bilt",
  "Emden",
  "Huginn - mobile",
  "Krusevac",
  "Kukavica",
  "Mont Colombis",
  "Moucherotte",
  "Muninn - mobile",
  "Nis",
  "Noyal-Pontivy",
  "Petrovac",
  "Porto Santo/Pico do Espig?o",
  "Saint-Rémy",
  "Sjenica",
  "Uzice",
  "Valjevo",
  "Vars"
]
amotl commented 3 years ago

The resolution of the location is not as precise as within the original DWD document, though.

DWD PDF

"name": "Boostedt",
"latitude": 54.004381,
"longitude": 10.046899,
"altitude": 125,

EUMETNET/OPERA

"location": "Boostedt",
"latitude": "54.0043",
"longitude": "10.0468",
"heightofstation": "124.5",

Will it do any harm?

kmuehlbauer commented 3 years ago

@amotl For this, I think, will do no harm.

amotl commented 3 years ago

All right, thanks. Then, within one of the next iterations, I will replace the list of radar sites provided by [1] through this list obtained from EUMETNET. A little enrichment will be needed in order to address a site by its three letter DWD ID (e.g. boo) instead of the five letter ODIM code (e.g. deboo), but this is nothing to worry about because Wetterdienst actually is the right place to do those kind of alignments for the benefit of its users.

That is, in order to satisfy this piece of wradlib code taken from [2]:

rwdata, rwattrs = wrl.io.read_radolan_composite(rw_filename)

for radar_id in rwattrs['radarlocations']:
    radar = radars[radar_id.upper()]

radar_id.upper() is currently, for example, BOO.

[1] https://github.com/earthobservations/wetterdienst/blob/v0.13.0/wetterdienst/dwd/radar/sites.py [2] https://github.com/wradlib/wradlib-notebooks/blob/master/notebooks/radolan/radolan_network.ipynb

amotl commented 3 years ago

Dear Kai,

we improved the list of radar sites made available through the Wetterdienst package by using the EUMETNET/OPERA source within https://github.com/earthobservations/wetterdienst/pull/346.

In order to query the information of a specific radar site operated by the @DeutscherWetterdienst, there is a convenience API method which can be used like this:

from wetterdienst.provider.dwd.radar.api import DwdRadarSites

site = DwdRadarSites().by_odimcode("ASB")
print(site)

With kind regards, Andreas.

P.S.: We will ping you as soon as this is available within a new release of Wetterdienst.