MCPcopy Create free account
hub / github.com/MotrixLab/ViMoGen / axis_angle_to_mat3x3

Function axis_angle_to_mat3x3

motion_rep/rotation_transform.py:59–68  ·  view source on GitHub ↗

Convert 3d vector of axis-angle rotation to 3x3 rotation matrix. Shape: - Input: :Torch:`(N, 3)` - Output: :Torch:`(N, 3, 3)`

(angle_axis)

Source from the content-addressed store, hash-verified

57 return axis_angle
58
59def axis_angle_to_mat3x3(angle_axis):
60 """
61 Convert 3d vector of axis-angle rotation to 3x3 rotation matrix.
62 Shape:
63 - Input: :Torch:`(N, 3)`
64 - Output: :Torch:`(N, 3, 3)`
65 """
66 rot_mat = tgm.angle_axis_to_rotation_matrix(angle_axis) # 4x4 rotation matrix
67
68 return rot_mat[:, :3, :3]
69
70def mat3x3_to_axis_angle(rot_mat):
71 """

Callers 2

collect_motion_rep_DARTFunction · 0.85
apply_rotationFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected