(self, angular_velocity,
                                           orientation)
return np.asarray(relative_velocity)
Transform the angular velocity from world frame to robot's frame.

    Args:
      angular_velocity: Angular velocity of the robot in world frame.
      orientation: Orientation of the robot represented as a quaternion.

    Returns:
      angular velocity of based on the given orientation.
Transform the angular velocity from world frame to robot's frame.
Transform the angular velocity from world frame to robot s frame .
def TransformAngularVelocityToLocalFrame(self, angular_velocity,
                                           orientation):
    """Transform the angular velocity from world frame to robot's frame.

    Args:
      angular_velocity: Angular velocity of the robot in world frame.
      orientation: Orientation of the robot represented as a quaternion.

    Returns:
      angular velocity of based on the given orientation.
    """
    # Treat angular velocity as a position vector, then transform based on the
    # orientation given by dividing (or multiplying with inverse).
    # Get inverse quaternion assuming the vector is at 0,0,0 origin.
    _, orientation_inversed = self._pybullet_client.invertTransform(
        [0, 0, 0], orientation)
    # Transform the angular_velocity at neutral orientation using a neutral
    # translation and reverse of the given orientation.
    relative_velocity, _ = self._pybullet_client.multiplyTransforms(
        [0, 0, 0], orientation_inversed, angular_velocity,
        self._pybullet_client.getQuaternionFromEuler([0, 0, 0]))
    return np.asarray(relative_velocity)
def TransformAngularVelocityToLocalFrame ( self , angular_velocity , orientation ) : # Treat angular velocity as a position vector, then transform based on the # orientation given by dividing (or multiplying with inverse). # Get inverse quaternion assuming the vector is at 0,0,0 origin. _ , orientation_inversed = self . _pybullet_client . invertTransform ( [ 0 , 0 , 0 ] , orientation ) # Transform the angular_velocity at neutral orientation using a neutral # translation and reverse of the given orientation. relative_velocity , _ = self . _pybullet_client . multiplyTransforms ( [ 0 , 0 , 0 ] , orientation_inversed , angular_velocity , self . _pybullet_client . getQuaternionFromEuler ( [ 0 , 0 , 0 ] ) ) return np . asarray ( relative_velocity )