polygon_area

sofia_redux.toolkit.image.fill.polygon_area(ppath)[source]

Uses the shoelace method to calculate area of a polygon

Goes as fast as I can, handling rounding errors as best I can.

Parameters:
ppathmatplotlib.path.Path
Returns:
float

Area of the polygon