Quantcast
Channel: "Average" of multiple quaternions? - Stack Overflow
Browsing all 16 articles
Browse latest View live

Answer by Interpol8r for "Average" of multiple quaternions?

I wanted to comment on the solutions, but since I don't have 50 goo goo stars or whatever that are needed to be allowed to comment, I wanted to point out than when you're finding the max eigenvalue in...

View Article



Answer by Dilara Gokay for "Average" of multiple quaternions?

Here is my PyTorch implementation for computing the average quaterniondef mean(Q, weights=None): if weights is None: weights = torch.ones(len(Q), device=torch.device("cuda:0")) / len(Q) A =...

View Article

Answer by Zailux for "Average" of multiple quaternions?

Here is a GitHub Repo with the implementation of this suggested algorithmn :)https://github.com/christophhagen/averaging-quaternionsThanks and credits to christophhagen ofc ;)

View Article

Answer by Tolga Birdal for "Average" of multiple quaternions?

Check here for my solution to weighted averaging as well as Lp median of quaternions.

View Article

Answer by Mario García for "Average" of multiple quaternions?

The easiest implementation (with Numpy in Python>=3.6) of Markley's solution would be:import numpy as npdef q_average(Q, W=None): if W is not None: Q *= W[:, None] eigvals, eigvecs =...

View Article


Answer by Fritz for "Average" of multiple quaternions?

Since there are different approaches here, I wrote a Matlab script to compare them. These results seem to suggest that simply averaging and normalizing the quaternions (the approach from the unity...

View Article

Answer by Avatar for "Average" of multiple quaternions?

Quaternions are not an ideal set of DOF to use for rotations when computing an unconstrained average.Here is what I use most of the time ([MethodImpl(MethodImplOptions.AggressiveInlining)] internal...

View Article

Answer by consultit for "Average" of multiple quaternions?

This is my implementation in python of Tolga Birdal's algorithm:import numpy as npdef quatWAvgMarkley(Q, weights):''' Averaging Quaternions. Arguments: Q(ndarray): an Mx4 ndarray of quaternions....

View Article


Answer by Gouda for "Average" of multiple quaternions?

Here is the implementation for MATLAB function that I use to average Quaternions for orientation estimation.It is straightforward to convert the MATLAB to any other language, except that this...

View Article


Answer by Jonathan for "Average" of multiple quaternions?

Contrary to popular belief in the computer graphics industry, there is a straightforward algorithm to solve this problem which is robust, accurate, and simple that comes from the aerospace industry. It...

View Article

Answer by adrelino for "Average" of multiple quaternions?

There is a technical report from 2001 which states that the mean is actually quite a good approximation, provided that the quaternions lie close together. (for the case of -q=q, you could just flip the...

View Article

Answer by minorlogic for "Average" of multiple quaternions?

With quaternions you can do same thing, but with small correction: 1. Negate quaternion before averaging if its dot product with previous sum is negative. 2. Normalize average quaternion, a the end of...

View Article

Answer by Nathan Monteleone for "Average" of multiple quaternions?

Unfortunately it isn't terribly simple to do, but it is possible. Here's a whitepaper explaining the math behind it: http://ntrs.nasa.gov/archive/nasa/casi.ntrs.nasa.gov/20070017872_2007014421.pdfCheck...

View Article


Answer by jonathan for "Average" of multiple quaternions?

I tried Slerping the quaternions as suggested here but that didn't work for what I'm trying to do (model was distorted), so I simply ended up transforming the vectors by each quaternion and then doing...

View Article

Answer by burningbright for "Average" of multiple quaternions?

You cannot add quaternions. What you can do is find a quaternion that rotates continuously between two angles, including halfway. Quaternion interpolation is known as "slerp" and has a wikipedia page....

View Article


"Average" of multiple quaternions?

I'm trying to make the switch from matrices to quaternions for skeletal animation in my OpenGL program, but I've encountered a problem:Given a number of unit quaternions, I need to get a quaternion...

View Article
Browsing all 16 articles
Browse latest View live




Latest Images