deepof.utils.rotate

deepof.utils.rotate(p: array, angles: array, origin: array = array([0, 0])) array

Return a 2D numpy.ndarray with the initial values rotated by angles radians.

Parameters:
  • p (numpy.ndarray) – 2D Array containing positions of bodyparts over time.

  • angles (numpy.ndarray) – Set of angles (in radians) to rotate p with.

  • origin (numpy.ndarray) – Rotation axis (zero vector by default).

Returns:

rotated positions over time

Return type:

  • rotated (numpy.ndarray)