From 6e63582e023d7e75881ff925f4d3336e7835cf3c Mon Sep 17 00:00:00 2001 From: liwy <43266195+rxlqn@users.noreply.github.com> Date: Wed, 6 Jul 2022 13:26:01 +0800 Subject: [PATCH] update calc_average_acceleration in utils.py mistakes in calculating the v1 --- aist_plusplus/features/utils.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/aist_plusplus/features/utils.py b/aist_plusplus/features/utils.py index 8b57cc5..5a2c968 100644 --- a/aist_plusplus/features/utils.py +++ b/aist_plusplus/features/utils.py @@ -126,8 +126,8 @@ def calc_average_acceleration( ) / frame_time v1 = ( positions[i + j][joint_idx] - - positions[i + j - 1][joint_idx] / frame_time - ) + - positions[i + j - 1][joint_idx] + ) / frame_time average_acceleration += (v2 - v1) / frame_time current_window += 1 return np.linalg.norm(average_acceleration / current_window) @@ -180,4 +180,4 @@ def calc_average_velocity_vertical( ) else: raise NotImplementedError - return np.linalg.norm(average_velocity) \ No newline at end of file + return np.linalg.norm(average_velocity)