Biomedical Engineering Reference
In-Depth Information
For retinal image registration, the maximum horizontal translation t x is
100 pixels, the vertical translation t y is in the order of 10 pixels, the maximum
rotation angle θ is 5 and a typical scaling factor falls in [0.95, 1.05]. In the op-
timization process, we clamp the scaling factor to a certain range. A negative
scaling factor is relatively impossible. A zero scaling is also impractical and Java
2D would generate a runtime exception.
4.2.3
Interpolation
After a transformation is applied, the grid point in the floating image will typically
not coincide with another grid point in the transformed space. For a simple
example, consider translation t x = 0 . 25. Grids (0, 0), (1, 0) become (0.25, 0), and
(1.25, 0). Since the pixel values of the reference image are known on grid, and
under certain transformations, only the pixel value of the transformed floating
image on grid are of interest, the pixel values of the transformed floating image
on grid have to be estimated. The technique is called interpolation, which is to
estimate a pixel value based on the pixel values of its surrounding pixels.
There are different kinds of interpolation methods: nearest neighbor
(0-order), bilinear (first-order), etc. Tsao evaluated the interpolation effects on
registration performance [31]. Nearest neighbor uses the pixel value at the near-
est grid pixel to approximate the pixel value at the new position. That is, the
pixel value at ( x , y ) is approximated by that at (( int )( x + 0 . 5), ( int )( y + 0 . 5)).
The nearest neighbor interpolation is insensitive to the magnitude of transla-
tion up to one pixel. Therefore, it is not sufficient in order to achieve subpixel
registration accuracy.
Bilinear interpolation assumes the pixel value in each x and y direction
changes in a linear fashion. To get the pixel value at point ( x , y ), one can (a)
interpolate the value at ( x , j ) from ( i , j ) and ( i + 1 , j ), (b) interpolate the value
at ( x , j + 1) from ( i , j + 1) and ( i + 1 , j + 1), and (c) interpolate the value at
( x , y ) from ( x , j ) and ( x , j + 1), where integer i and j satisfy i x < i + 1 and
j y < j + 1.
In Java 2D, the interpolation method is governed by the rendering hints. To
specify a nearest neighbor interpolation, the rendering hints can be defined by
RenderingHints rh=new RenderingHints (
RenderingHints.KEY - INTERPOLATION,
RenderingHints.VALUE - INTERPOLATION - NEAREST - NEIGHBOR);
Search WWH ::




Custom Search