ewoksfluo.math.grid_utils.closest_point#
- ewoksfluo.math.grid_utils.closest_point(coordinates1, coordinates2)[source]#
Find the closest points in coordinates1 for each point in coordinates2.
- Parameters:
coordinates1 (
ndarray
) – Coordinates with shape (N1, Ndim)coordinates2 (
ndarray
) – Coordinates with shape (N2, Ndim)
- Return type:
Tuple
[ndarray
,ndarray
]- Returns:
A tuple containing: - indices of the closest points in coordinates2 for each point in coordinates1 with shape (N1,) - distances to the closest points with shape (N1,)