Skip to content

Shapely formatter returns invalid Polygons. #1

Description

@mrshannon

Matplotlib's contour generator does not always generate valid polygons and thus the Shapely formatter produces an invalid polygon. This invalid polygon can introduce many inconsistencies if shapely operations are performed on it since they in general are not well defined for invalid polygons. This is less of an issue with the NumPy and MATLAB formatters since they will not break if given invalid polygons.

contours needs to sanitize (make valid) the polygon before passing it to Shapely.

Until this is fixed the Shapely formatter should be considered broken and used with extreme caution.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions