perturbopy.postproc.utils.lattice.compute_distances
- perturbopy.postproc.utils.lattice.compute_distances(point_array1, point_array2)
Method to compute the distances between points
- Parameters:
point_array1 (array_like) – The points between which distances will be computed. They should have the same shape. Both will be reshaped to assume column-oriented points if needed. For example, arrays of shape (N, 3) will be reshaped to (3, N) if N != 3.
point_array2 (array_like) – The points between which distances will be computed. They should have the same shape. Both will be reshaped to assume column-oriented points if needed. For example, arrays of shape (N, 3) will be reshaped to (3, N) if N != 3.
- Returns:
distances – An array of distances between points in point_array1 and point_array2, computed across the columns.
- Return type:
array