-
Notifications
You must be signed in to change notification settings - Fork 303
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
Fix handling of file attributes in seviri_l1b_nc reader #791
Conversation
…lays HRV channel data
@ColinDuff that's great, thanks ! Will this work also with older files from the archive ? |
Codecov Report
@@ Coverage Diff @@
## master #791 +/- ##
==========================================
- Coverage 82.27% 82.27% -0.01%
==========================================
Files 159 159
Lines 22996 22998 +2
==========================================
Hits 18921 18921
- Misses 4075 4077 +2
Continue to review full report at Codecov.
|
Hi Martin - no it will not work with older files that users may have ordered and are stored locally. I assume any netcdf level1b file ordered from EUM now will have the correct attributes . So they may have to reorder any files they have issues with. |
In response to my assumption re older seviri Level1b netcdf files I tested succesfully on 2 seviri level1b netcdf files ordered from 2017. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice work! Just two comments, otherwise looks good to me. If you have time, it would be nice if you could add some tests for the reader :)
if earth_model == 2: | ||
ns_offset = 0 # north +ve | ||
we_offset = 0 # west +ve | ||
elif earth_model == 1: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe add a short comment that the data is shifted to N-W and to correct for it, we have to adjust the corners in the opposite direction, i.e. S-E
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the comment can be copied from the seviri_l1b_native
-reader.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Working on creating tests for this reader now
I will add the comment as suggested by sjoro
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
comment added
file_reader: !!python/name:satpy.readers.seviri_l1b_nc.NCSEVIRIFileHandler | ||
file_patterns: ['W_XX-EUMETSAT-Darmstadt,VIS+IR+IMAGERY,{satid:4s}+SEVIRI_C_EUMG_{processing_time:%Y%m%d%H%M%S}.nc'] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Isn't the VIS+IR+IMAGERY
pattern still needed if one de-selects HRV in the order (EUM data centre)?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hi, when i ordered the data the Netcdf option didnt allow me to deselect any channels. But now I see that the Netcdf (GSICS) option does so i will update the yaml and test this.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
so there is an issue with the netcdf data ordered using netcdf (GSICS) as some attributes are missing, Also spacecraft id is missing from the filename. EUM has been informed
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh, too bad. Shall we wait for them to fix it or merge now and add support for GSICS nc-files later?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
after talking to @ColinDuff, I suggest we merge this now and deal with GSICS nc-files later. this way users can use the reader for "regular" nc-files.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if i remember correctly, this reader works for certain file_patterns
, but not all? some netCDF-files do not contain all the relevant info for the reader, right? if this is the case, please add all possible file_patterns
(VIS+IR, HRV, VIS+IR+HRV) to the reader yaml-file. raise a NotImplemented
error for the ones the reader does not work.
…to Level1.5 Image data format was added
EUMETSAT have corrected the netcdf attributes for the combined VIS/IR/HRV Level1b netcdf product.
This PR removes the previous workaround and also reads/displays the HRV data correctly
Closes #753
Test for netcdf Level1b data is WIP - as the reader is currently available i thought best to fix it first then add the reader later
No issues raised with flake8