deepof.utils.point_in_polygon
- deepof.utils.point_in_polygon(points: array, polygon: Polygon) array
Check if a set of points is inside a polygon.
- Parameters:
points (np.ndarray) – An array of shape (M, 2) containing the coordinates of the points.
polygon (shapely.geometry.polygon.Polygon) – Shapely polygon.
- Returns:
A boolean array of shape (M,) indicating whether each point is inside the polygon.
- Return type:
np.ndarray