Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use pdbufr to read DWD radar data in bufr format #482

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

gutzbenj
Copy link
Member

@gutzbenj gutzbenj commented Jul 19, 2021

As suggested by @meteoDaniel this adds pdbufr to the requirements and allows to parse the provided bufr radar data by DWD to a pandas DataFrame. (testing not possible atm as data is not available)

Fixes #364

UPDATE
This won't currently work as of the loose connection between eccodes (the core library) and its python bindings. Differences between versions can lead to an ImportError which is caused by the core library not being found. We should wait for this to be solved to be able to run ordinary checks on bufr files.

UPDATE2
Provision errors of eccodes library can now individually be solved by setting such environmental variable

@gutzbenj gutzbenj requested a review from amotl July 19, 2021 21:15
@codecov
Copy link

codecov bot commented Jul 19, 2021

Codecov Report

Attention: Patch coverage is 60.00000% with 4 lines in your changes are missing coverage. Please review.

Project coverage is 90.86%. Comparing base (6d06232) to head (b2c8bc2).
Report is 104 commits behind head on main.

❗ Current head b2c8bc2 differs from pull request most recent head 722c9d5. Consider uploading reports for the commit 722c9d5 to get more accurate results

Files Patch % Lines
wetterdienst/provider/dwd/radar/access.py 55.55% 3 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff            @@
##             main     #482     +/-   ##
=========================================
  Coverage   90.85%   90.86%             
=========================================
  Files         103       85     -18     
  Lines        9856     5263   -4593     
  Branches     1133      443    -690     
=========================================
- Hits         8955     4782   -4173     
+ Misses        703      372    -331     
+ Partials      198      109     -89     
Flag Coverage Δ
unittests 90.86% <60.00%> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Contributor

@meteoDaniel meteoDaniel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey @gutzbenj I hope you are fine.
I took a look to your first code for handling DWD bufr data. I hope this helps you.
If you want I can write some tests for it ;) Let me know.

wetterdienst/provider/dwd/radar/access.py Outdated Show resolved Hide resolved
"latitude",
"longitude",
"horizontalReflectivity",
),
Copy link
Contributor

@meteoDaniel meteoDaniel Sep 9, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think more meta data is required to work with radar data.

  1. Number of radial bins
  2. range
  3. azimuth

Take a look at step 11 at https://docs.wradlib.org/en/stable/notebooks/fileio/wradlib_load_DWD_opendata_volumes.html

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the hint! This was just a first guess as with pdbufr you will have to set everything you want to read in beforehand and can't just read everything that's being found in the file.

Copy link
Member Author

@gutzbenj gutzbenj May 1, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Dear @meteoDaniel , could you please check the latest state of the PR? I also couldn't figure out if the information of

  • Number of radial bins
  • range
  • azimuth
    is contained within the bufr files.

wetterdienst/provider/dwd/radar/api.py Outdated Show resolved Hide resolved
wetterdienst/provider/dwd/radar/access.py Outdated Show resolved Hide resolved
@gutzbenj gutzbenj force-pushed the bufr-dataframe branch 10 times, most recently from 2487b88 to c9900cb Compare May 1, 2022 17:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Enabling bufr data download and store into dataframe by using pdbufr
2 participants