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 notebooks/Dfsu - Export to shapefile.ipynb not compatible with matplotlib 3.10 #770

Open
ecomodeller opened this issue Dec 16, 2024 · 0 comments

Comments

@ecomodeller
Copy link
Member

https://pypi.org/project/matplotlib/3.10.0/

for collection,level in zip(cn.collections,contour_levels):
    for p in collection.get_paths():
        v = p.vertices
        x = v[:,0]
        y = v[:,1]
        poly = LineString([(i[0], i[1]) for i in zip(x,y)])
        if(poly.is_empty):
            print(f"{i} is empty")
        poly_list.append(dict(wind_speed = level, poly = poly))
------------------


---------------------------------------------------------------------------
AttributeError                            Traceback (most recent call last)
Cell In[13], line 5
      1 from shapely.geometry import LineString
      3 poly_list = []
----> 5 for collection,level in zip(cn.collections,contour_levels):
      6     for p in collection.get_paths():
      7         v = p.vertices

AttributeError: 'QuadContourSet' object has no attribute 'collections
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

No branches or pull requests

1 participant