(shape)
| 73 | return r2s_polygon(roi.topolygon()) |
| 74 | |
| 75 | def shape2roi(shape): |
| 76 | if isinstance(shape, Point): |
| 77 | return s2r_point(shape) |
| 78 | if isinstance(shape, MultiPoint): |
| 79 | return s2r_points(shape) |
| 80 | if isinstance(shape, LineString): |
| 81 | return s2r_line(shape) |
| 82 | if isinstance(shape, MultiLineString): |
| 83 | return s2r_lines(shape) |
| 84 | if isinstance(shape, Polygon): |
| 85 | return s2r_polygon(shape) |
| 86 | if isinstance(shape, MultiPolygon): |
| 87 | return s2r_polygons(shape) |
| 88 | |
| 89 | if __name__ == '__main__': |
| 90 | import sys |
no test coverage detected