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

Fix geostationary axis handling in CF writer #1040

Merged
merged 4 commits into from
Jan 10, 2020

Conversation

djhoese
Copy link
Member

@djhoese djhoese commented Jan 9, 2020

This is a solution suitable for a 0.19.1 release since it still works on python 2.7 and doesn't require pyproj 2.0+. See #1038 for the 0.20 long term solution.

This PR does two main things:

  1. Get the a/b parameters for the geostationary projection by using pyresample's utilities. This is important for pyproj 2.0+ where a/b combinations may be replaced by their associated datum/ellipsoid name (meaning a/b are not available from the PROJ dict).
  2. Fixes the tests so they actually check the attributes.

@coveralls
Copy link

coveralls commented Jan 9, 2020

Coverage Status

Coverage increased (+0.02%) to 87.312% when pulling 9ba406e on djhoese:bugfix-cf-projections2 into c2de7cc on pytroll:master.

@codecov
Copy link

codecov bot commented Jan 9, 2020

Codecov Report

Merging #1040 into master will increase coverage by 0.03%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1040      +/-   ##
==========================================
+ Coverage   87.29%   87.32%   +0.03%     
==========================================
  Files         188      188              
  Lines       28715    28736      +21     
==========================================
+ Hits        25066    25094      +28     
+ Misses       3649     3642       -7
Impacted Files Coverage Δ
satpy/tests/writer_tests/test_cf.py 98.55% <100%> (+0.05%) ⬆️
satpy/writers/cf_writer.py 92.65% <100%> (+1.97%) ⬆️
satpy/scene.py 89.8% <0%> (+0.17%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update c2de7cc...9ba406e. Read the comment docs.

Copy link
Member

@mraspaud mraspaud left a comment

Choose a reason for hiding this comment

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

LGTM

@mraspaud mraspaud merged commit b642616 into pytroll:master Jan 10, 2020
@djhoese djhoese deleted the bugfix-cf-projections2 branch January 12, 2020 22:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

NetCDF (CF) writer doesn't include semi_minor_axis/semi_major_axis for new versions of pyproj
3 participants