10
$\begingroup$

FindGeometricTransform returns "the alignment error together with the transformation function." How is the alignment error computed?

I ask because if you iterate FindGeometricTransform, applying the transformation each time, the transformation converges to the unitary transform, as one would expect, but the alignment error is monotonically increasing, which seems a little counter-intuitive.

Here are two sets of points:

a = {{9, 46.}, {10, 45.}, {11, 44.}, {12, 44.}, {13, 43.}, {14, 43.}, {15,   42.}, {16, 42.}, {17, 41.}, {18, 41.}, {19, 32.}, {20, 21.}, {21, 20.}, {22, 17.}, {23, 23.}}

and

b = {{9.18212, 45.4089}, {10., 45.}, {10.9782, 44.5109}, {12.,  44.}, 13.0683, 43.4658}, {14.1864, 42.9068}, {15.3579,  42.321}, {16., 42.}, {16.8475, 1.5762}, {18., 41.}, {18.804, 40.598}, {18.8214, 40.5893}, {19.7035, 40.1482}, 20.3818,  39.8091}, {23., 38.5}}

The application of

{e, t} = FindGeometricTransform[a, b]

yields an alignment error e = 0.288599.

Setting

b = t[b]

yields

b = {{9.18212, 45.4089}, {10., 45.}, {10.9782, 44.5109}, {12., 44.}, {13.0683, 43.4658}, {14.1864, 42.9068}, {15.3579, 42.321}, {16., 42.}, {16.8475, 41.5762}, {18., 41.}, {18.804,  40.598}, {18.8214, 40.5893}, {19.7035, 40.1482}, {20.3818, 39.8091}, {23., 38.5}}

and applying

{e, t} = FindGeometricTransform[a, b]

again, yields an alignment error ofe = 0.355193. The sum of the Euclidean distances between a and the second and third version of b is the same, 89.6673, so whatever alignment error is being measured doesn't seem to have to do with the location of the points.

$\endgroup$
4
  • $\begingroup$ I ask because if you iterate FindGeometricTransform, applying the transformation each time, the transformation converges to the unitary transform as one would expect but the alignment error is monotonically increasing which seems a little counter-intuitive. $\endgroup$ Commented Jun 28, 2017 at 21:56
  • 1
    $\begingroup$ Can you give a minimal example to illustrate the problem? $\endgroup$ Commented Jun 29, 2017 at 0:41
  • $\begingroup$ You have some braces missing in the first b. $\endgroup$
    – Michael E2
    Commented Jul 2, 2017 at 0:39
  • 1
    $\begingroup$ After adding the missing braces I get (with Mathematica 8.0.4) different outputs from given in your question: the first e is 0.720145, the second is 0.29502, and b is also different. $\endgroup$ Commented Jul 2, 2017 at 11:20

1 Answer 1

7
$\begingroup$

The alignment error is the mean Euclidean distance of the points after transformation.

{err, transform} = FindGeometricTransform[data2, data1];
err

0.315546

Mean@MapThread[EuclideanDistance, {transform@data1, data2}]

0.315546

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.