docs: def _drop_degenerate_inners(shape):
      """
      Drop degenerate (zero-size) inners from the polygon.
  
      This is implemented as dropping anything with a size less than 0.5, as the
      polygon is in integer coordinates and the smallest valid inner would be a
      triangle with height and width 1.
      """
  
      assert shape.geom_type == 'Polygon'
  
      new_inners = []
      for inner in shape.interiors:
          # need to make a polygon of the linearring to get the _filled_ area of
          # the closed ring.
          if abs(Polygon(inner).area) >= 0.5:
              new_inners.append(inner)
  
      return Polygon(shape.exterior, new_inners)