Skip to content

Commit

Permalink
Give internal method a more descriptive name
Browse files Browse the repository at this point in the history
  • Loading branch information
willGraham01 committed Feb 18, 2025
1 parent 2672938 commit 13526e2
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions movement/roi/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ def __str__(self) -> str: # noqa: D105
f"({n_points}{display_type})\n"
) + " -> ".join(f"({c[0]}, {c[1]})" for c in self.coords)

def _vector_from_keypoint_centroid(
def _vector_from_centroid_of_keypoints(
self,
data: xr.DataArray,
position_keypoint: Hashable | Sequence[Hashable],
Expand Down Expand Up @@ -498,7 +498,7 @@ def compute_allocentric_angle(
raise ValueError(f"Unknown angle convention: {angle_rotates}")

# Determine the approach vector, for all time-points.
approach_vector = self._vector_from_keypoint_centroid(
approach_vector = self._vector_from_centroid_of_keypoints(
data,
position_keypoint=position_keypoint,
boundary=boundary,
Expand Down Expand Up @@ -611,7 +611,7 @@ def compute_egocentric_angle(
raise ValueError(f"Unknown angle convention: {angle_rotates}")

# Determine the approach vector, for all time-points.
approach_vector = self._vector_from_keypoint_centroid(
approach_vector = self._vector_from_centroid_of_keypoints(
data,
position_keypoint=position_keypoint,
boundary=boundary,
Expand Down
2 changes: 1 addition & 1 deletion movement/roi/line.py
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@ def compute_angle_to_support_plane_of_segment(
if position_keypoint is None:
position_keypoint = [left_keypoint, right_keypoint]

normal = self._vector_from_keypoint_centroid(
normal = self._vector_from_centroid_of_keypoints(
data,
position_keypoint=position_keypoint,
renamed_dimension="normal",
Expand Down

0 comments on commit 13526e2

Please sign in to comment.