4 ms·
My understanding was that the main benefit of quaternions in computer graphics was representing rotations in a way that doesn't result in gimble lock. And beyo
by monocasa 1y ago
My understanding was that the main benefit of quaternions in computer graphics was representing rotations in a way that doesn't result in gimble lock.
And beyond that, for those rotations, a quaternion doesn't scale nearly as well as you add dimensions. Complex numbers are a complex representation of two space, quaternions are a complex representation of three space, and to go to four space you have octonions, which have eight elements.
- eru 1y agoQuaternions have four dimensions.
- thomaskoopman 1y agoYes, but quaternions of unit length are a representation of the rotation group in 3D space ( https://en.wikipedia.org/wiki/Representation_theory_of_SU(2)#Relation_to_the_representations_of_SO(3) https://en.wikipedia.org/wiki/Representation_theory_of_SU(2)... ), which is how they are used for rotations.
- suspended_state 1y agoThe original question was: can quaternions be used in place of matrices to perform LLMs tasks, and the answer is: quaternions are 4 dimensions, with the implied meaning that matrices can cover different dimentionalities, which are needed for LLMs (and neural network in general).
- deleted 1y ago[deleted]
- eru 1y agoYes, if you have essentially 4d objects and you disable 1 dimension by requiring unit length, you end up with something that is effectively 3d. Of course, that the 3d thing you end up with represents rotations in 3d space is extremely neat; and not something all 3d things do.
- formerly_proven 1y agoAxis-angle also doesn't have gimbal lock - the main advantage of quaternions is that actually performing rotations with them only involves addition and multiplication, no trigonometry at all. The same is true for using proper rotation matrices, but those use a lot more memory. Plus, you can actually lerp between quaternions (more generally - they compose). That doesn't work with matrices (I think)
- monocasa 1y agoAxis angle has gimble lock when composed.