Skip to content

Conversation

@kgoebber
Copy link
Collaborator

@kgoebber kgoebber commented May 5, 2020

Description Of Changes

This is an attempt to overcome some challenges introduced by Cartopy 0.18. It mainly hit the states and counties that are a part of MetPy. Some changes also touched the declarative portion of MetPy with the AdaptiveScale. I don't love my solution, but it works. Although I am getting a lot of test failures due to different choices being made by the AdaptiveScale functionality (as well as my own free type issues).

The issue with the AdaptiveScale was that it was not returning the scale value and needed some additions to be able to choose a different scale and not always default to the coarsest scale.

In addition, now some tests are plotting point data outside the graphics area. Sigh...

I'll continue to look as I have time, but someone can feel free to run with this PR if they wish.

Please feel free to adapt or come up with a better solution.

Checklist

def __init__(self, name, scale, **kwargs):
"""Create USCountiesFeature instance."""
super().__init__('', name, scale, **kwargs)
super(MetPyMapFeature, self).__init__(ccrs.PlateCarree(), **kwargs)
Copy link
Member

Choose a reason for hiding this comment

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

Since we're Python 3 only here, we should be able to leave as super().

@dopplershift
Copy link
Member

Interesting...this is a a different solution than discussed in #1368. I like it in some ways, but would love to find a way to not need to do anything to our existing plotting code...

@kgoebber
Copy link
Collaborator Author

kgoebber commented May 5, 2020

Yeah, I didn't see @jthielen comment until this morning when I was going to submit after working on this last night. I'll make the change you suggested and we can stew on this and/or wait for other potential solutions.

@jthielen
Copy link
Collaborator

jthielen commented May 5, 2020

Would we want #1368 (comment) for now to get a quick patch out the door in v0.12.2 (it works without needing to modify any existing plotting code, but it also relies upon the current set of attributes of NaturalEarthFeature and its use of Feature's __init__ staying the same), and then work out a better fix here for 1.0 after some discussion?

@kgoebber
Copy link
Collaborator Author

kgoebber commented May 6, 2020 via email

@jthielen
Copy link
Collaborator

All these fixes should have been taken care of by #1416.

@jthielen jthielen closed this Jul 27, 2020
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.

Cartopy 0.18.0 USCOUNTIES '20m' invalid

3 participants