1
0
mirror of https://gitee.com/sui-feng-cb/AzurLaneAutoScript1 synced 2026-03-12 06:18:21 +08:00

Fix: Flipped result if camera outside map

This commit is contained in:
LmeSzinc
2020-07-08 03:54:45 +08:00
parent a902f4f0d9
commit 9c7397ddde
2 changed files with 18 additions and 15 deletions

View File

@@ -208,6 +208,21 @@ def points_to_area_generator(points, shape):
yield ((x, y), area)
def get_map_inner(points):
"""
Args:
points (np.ndarray): N x 2 array.
Yields:
np.ndarray: (x, y).
"""
points = np.array(points)
if len(points.shape) == 1:
points = np.array([points])
return np.mean(points, axis=0)
def separate_edges(edges, inner):
"""
Args: