MCPcopy Create free account
hub / github.com/Image-Py/imagepy / parse_mpoly

Function parse_mpoly

imagepy/core/roi/polygonroi.py:20–23  ·  view source on GitHub ↗
(geom)

Source from the content-addressed store, hash-verified

18 return [out, inn]
19
20def parse_mpoly(geom):
21 if geom.geom_type == 'Polygon':
22 return[i for i in [parse_poly(geom)] if i != None]
23 return [parse_poly(i) for i in list(geom)]
24
25def to_segment(pg):
26 p = Polygon(pg) if len(pg)>2 else Polygon(*pg)

Callers 1

commitMethod · 0.85

Calls 1

parse_polyFunction · 0.85

Tested by

no test coverage detected