Thin plate spline explained

Thin plate splines (TPS) are a spline-based technique for data interpolation and smoothing. "A spline is a function defined by polynomials in a piecewise manner." They were introduced to geometric design by Duchon. They are an important special case of a polyharmonic spline. Robust Point Matching (RPM) is a common extension and shortly known as the TPS-RPM algorithm.

Physical analogy

The name thin plate spline refers to a physical analogy involving the bending of a plate or thin sheet of metal. Just as the metal has rigidity, the TPS fit resists bending also, implying a penalty involving the smoothness of the fitted surface. In the physical setting, the deflection is in the

z

direction, orthogonal to the plane. In order to apply this idea to the problem of coordinate transformation, one interprets the lifting of the plate as a displacement of the

x

or

y

coordinates within the plane. In 2D cases, given a set of

K

corresponding control points (knots), the TPS warp is described by

2(K+3)

parameters which include 6 global affine motion parameters and

2K

coefficients for correspondences of the control points. These parameters are computed by solving a linear system, in other words, TPS has a closed-form solution.

Smoothness measure

The TPS arises from consideration of the integral of the square of the second derivative—this forms its smoothness measure. In the case where

x

is two dimensional, for interpolation, the TPS fits a mapping function

f(x)

between corresponding point-sets

\{yi\}

and

\{xi\}

that minimizes the following energy function:

Etps(f)=

K
\sum
i=1

\|yi-f(xi)\|2

The smoothing variant, correspondingly, uses a tuning parameter

λ

to control the rigidity of the deformation, balancing the aforementioned criterion with the measure of goodness of fit, thus minimizing:

Etps,smooth(f)=

K
\sum
i=1

\|yi-f(xi)\|2+λ\iint\left[\left(

\partial2f
\partial
2
x
1

\right)2+2\left(

\partial2f
\partialx1\partialx2

\right)2+\left(

\partial2f
\partial
2
x
2

\right)2\right]rm{d}x1rm{d}x2

For this variational problem, it can be shown that there exists a unique minimizer

f

. The finite element discretization of this variational problem, the method of elastic maps, is used for data mining and nonlinear dimensionality reduction. In simple words, "the first term is defined as the error measurement term and the second regularisation term is a penalty on the smoothness of

f

." It is in a general case needed to make the mapping unique.

Radial basis function

See main article: Radial basis function.

The thin plate spline has a natural representation in terms of radial basis functions. Given a set of control points

\{ci,i=1,2,\ldots,K\}

, a radial basis function defines a spatial mapping which maps any location

x

in space to a new location

f(x)

, represented by

f(x)=

K
\sum
i=1

wi\varphi(\left\|x-ci\right\|)

where

\left\|\right\|

denotes the usual Euclidean norm and

\{wi\}

is a set of mapping coefficients. The TPS corresponds to the radial basis kernel

\varphi(r)=r2logr

.

Spline

Suppose the points are in 2 dimensions (

D=2

). One can use homogeneous coordinates for the point-set where a point

yi

is represented as a vector

(1,yix,yiy)

. The unique minimizer

f

is parameterized by

\alpha

which consists of two matrices

d

and

c

(

\alpha=\{d,c\}

).

ftps(z,\alpha)=ftps(z,d,c)=zd+\phi(z)c=zd+

K
\sum
i=1

\phii(z)ci

where d is a

(D+1) x (D+1)

matrix representing the affine transformation (hence

z

is a

1 x (D+1)

vector) and c is a

K x (D+1)

warping coefficient matrix representing the non-affine deformation. The kernel function

\phi(z)

is a

1 x K

vector for each point

z

, where each entry

\phii(z)=\|z-

2
x
i\|

log\|z-xi\|

. Note that for TPS, the control points

\{ci\}

are chosen to be the same as the set of points to be warped

\{xi\}

, so we already use

\{xi\}

in the place of the control points.

If one substitutes the solution for

f

,

Etps

becomes:

Etps(d,c)=\|Y-Xd-\Phic\|2+λcT\Phic

where

Y

and

X

are just concatenated versions of the point coordinates

yi

and

xi

, and

\Phi

is a

(K x K)

matrix formed from the

\phi(\|xi-xj\|)

. Each row of each newly formed matrix comes from one of the original vectors. The matrix

\Phi

represents the TPS kernel. Loosely speaking, the TPS kernel contains the information about the point-set's internal structural relationships. When it is combined with the warping coefficients

c

, a non-rigid warping is generated.

A nice property of the TPS is that it can always be decomposed into a global affine and a local non-affine component. Consequently, the TPS smoothness term is solely dependent on the non-affine components. This is a desirable property, especially when compared to other splines, since the global pose parameters included in the affine transformation are not penalized.

Applications

TPS has been widely used as the non-rigid transformation model in imagealignment and shape matching.An additional application is the analysis and comparisons of archaeological findings in 3D and was implemented for triangular meshes in the GigaMesh Software Framework.

The thin plate spline has a number of properties which have contributed to its popularity:

  1. It produces smooth surfaces, which are infinitely differentiable.
  2. There are no free parameters that need manual tuning.
  3. It has closed-form solutions for both warping and parameter estimation.
  4. There is a physical explanation for its energy function.

However, note that splines already in one dimension can cause severe "overshoots". In 2D such effects can be much more critical, because TPS are not objective.

See also

References

[1] [2] [3] [4] [5]

External links

Notes and References

  1. Book: Tahir, Anam . 2023 . Formation Control of Swarms of Unmanned Aerial Vehicles . Finland . University of Turku . 978-951-29-9411-3.
  2. Tahir . Anam . Haghbayan . Hashem . Böling . Jari M. . Plosila . Juha . 2023 . Energy-Efficient Post-Failure Reconfiguration of Swarms of Unmanned Aerial Vehicles . IEEE Access . 11 . 24768 – 24779 . 10.1109/ACCESS.2022.3181244 . free .
  3. J. Duchon, 1976, Splines minimizing rotation invariant semi-norms in Sobolev spaces. pp 85–100, In: Constructive Theory of Functions of Several Variables, Oberwolfach 1976, W. Schempp and K. Zeller, eds., Lecture Notes in Math., Vol. 571, Springer, Berlin, 1977. doi:10.1007/BFb0086566
  4. Bookstein. F. L.. Principal warps: thin plate splines and the decomposition of deformations. IEEE Transactions on Pattern Analysis and Machine Intelligence. June 1989. 11. 6. 567–585. 10.1109/34.24792.
  5. Web site: Tutorial No. 13: Apply TPS-RPM Tranformation . GigaMesh Software Framework. 3 March 2019.