PixInsight 1.5

The Officially Unofficial Reference Guide

Rev.0.1 – 3/29/2010

Section 10: ImageRegistration

DynamicAlignment

DynamicAlignment is a semi-automatic image registration system for deep-sky images. It works quite easily. After you've opened the DynamicAlignment dialog, click on an image (source image), then on a second image (target image). The target will be registered to match the source.

Then a set of alignment points are defined, which obviously are stars. DynamicAlignment's sophisticated interface includes an adaptive star-searching algorithm, which is independent on brightness/contrast. This means that you can register linear raw CCD images without problems (using ScreenTransferFunctions to see the stars without altering the images). DynamicAlignment also includes a useful prediction system: starting from the second star, it will predict the target position of every source star.

Selected Sample: x of z

Ref#: Index of the currently selected alignment reference.

Navigation toolbar: In order:

  • Select the first alignment reference.

  • Select the previous alignment reference.

  • Select the next alignment reference.

  • Select the last alignment reference.

  • Invert the current alignment reference. Normal (non inverted) references look for bright stars over a dark background. An inverted reference behaves just the opposite way: dark star over a bright background. By inverting references you can select arbitrary image structures, not only stars, as alignment features. For example, you can select dark alignment features on lunar and planetary images using this option.

  • Load the current alignment reference on the source and target views.

  • Delete the selected alignment reference(s).

  • Track alignment references on the source and target views.

    X/Y: Source star position x,y axis. These are the horizontal and vertical position of the computed star barycenter for the currently selected alignment reference in the source image.

    Rs/Rt: Source and target star radius. Half-size of the currently selected alignment reference in the source (Rs) and target (Rt) image. This value is computed automatically by DynamicAlignment's star detection/modeling algorithm.

    eX/eY: Error in the last predicted target position, x,y coordinates. Difference in pixels between the horizontal and vertical coordinates of the computed and predicted star barycenter in the target image. When two or more alignment references are defined, DynamicAlignment predicts target star positions for each newly selected star. Coordinate prediction is performed building an image registration model on the fly, based on all existing alignment references except the new one. You can use prediction errors to evaluate the quality of the image registration model being defined

    To force a new prediction of coordinates for any existing reference, just select and move it slightly with the mouse. In this way the alignment reference will be recalculated, along with its predicted coordinates.

    dX/dY: Differential star position (target-source) x,y coordinates. This is the difference in pixels between the horizontal and vertical coordinates of the target and source positions for the current reference. It measures the vertical displacement of the target image with respect to the source image for the current alignment reference.

    Reference generation

    Source search radius: Initial search radius in the source image. This parameter determines the size in pixels of the initial search box used to detect valid alignment references on the source image. Increase it to favor detection of larger structures. Decrease to facilitate finding relatively small features; for example to deal with dense star fields.

    Target search radius: Initial search radius in the target image. Everything said about the source search radius is applicable to the target search radius as well.

    Removed wavelet layers: Number of wavelet layers used for noise reduction. Noise reduction prevents detection of bright noise structures as false stars, including hot pixels and cosmic rays. This parameter can also be used to control the sizes of the smallest detected stars (increase to exclude more stars).

    Weighting function: Star profiling function. This is a mathematical model used to calculate star barycenter positions. In general, you should not need to change this parameter, since the default Gaussian model is appropriate in most cases. However, when one has to deal with saturated stars (which should be avoided as much as possible), a linear profiling function may be preferable because there is nothing similar to a Gaussian distribution in a strongly saturated star image.

    Background threshold: Threshold value for rejection of background pixels. This is a limiting value, expressed in sigma units, below which image pixels will be considered as part of the sky background. For each selected alignment reference, DynamicAlignment calculates the standard deviation – also known as sigma – of the set of pixels inside the reference search box (see the search radii parameters above). All pixels whose values are smaller than the computed sigma are considered as belonging to the sky background, and hence are rejected to gather pixels belonging to the reference star. When the alignment reference is inverted, background pixels are those above the computed sigma.

    Colors: Alignment references are drawn on the source and target images. These are the colors used to draw them. You can change them to different colors by clicking on the color square, then defining a new RGB value.

    Aligned Images

    Source: The identifier of the source image.

    Target: The identifier of the target image.

    Registered Image

    Identifier: Enter here the identifier for the registered image. If the default <Auto> is selected, the identifier will be the same as the target image plus the suffix _registered.

    Sample format: The format (bit depth) of the registered target image.

    StarAlignment

    The StarAlignment Process Module is used to register two or more images.

    Reference image: It has to point to the image the tool will use to align the other images to. If the object moved around during capture, we ideally want to select the frame where it is perfectly centered. You can chose whether to select a currently opened image inside PixInsight by leaving the default View in the little drop down menu on the right, or a file on your hard drive by selecting File instead. To make the actual selection, click on the blue arrow pointing down.

    Working mode: Normally set to the Register/Match Images setting, in which this tool actually aligns all your images to the reference image. The rest of the settings are for advanced use only.

    In short, setting any of Structure detection, Structure Map, Detected Stars and Matched Stars will not result in any alignment operation to be done. The tool will just generate one or more images showing data useful to evaluate our image quality. For example, Matched Stars will output an image with the stars that were matched in all our images. This is quite useful to have an idea of how well will our stack work.

    The Register/Union Mosaic mode is used to to compose a mosaic from the source images provided. A certain amount of overlapping stars will be needed. The construction of mosaics is beyond the scope of this reference manual.

    Generate masks: When enabled, it generates an additional file for each processed image, in which white pixels will represent those pixels that are present both in the reference and the processed images. The other pixels will be black. These images are useful as masks to apply selective corrections, especially when doing mosaics.

    Target Images subsection

    This section is composed by a large window where the list of images to be aligned will be placed.

    Add Files / Add Views: Click on these buttons to used to add files or already opened images to the list (views).

    Select All: When clicked, it will select all target images.

    Invert Selection: Unselected files will be selected, and viceversa: files already selected will be unselected.

    Toggle Selection: Selects an unselected file, or deselects a selected file.

    Remove Selected: Removes the selected file from the list.

    Clear: Deselect all files. This is the opposite of Select All.

    Full Paths: When checked, the full path of the images in the list will be displayed.

    Output Images

    This short section helps us decide what to do with our processed images.

    Output Directory: The directory where the processed images will be saved. The little blue arrow will open a file chooser to select it. If we leave this setting blank, the registered images will be saved in the same directory they are now. Be careful with this, as it may overwrite your original images. It's highly recommended to use a temporary folder.

    Output Extensions / Prefix, Postfix / Mask: These are all used to tag the newly created aligned files. While it's a good practice to leave Output Extensions as is, because it identifies the image format, it's very encouraged the use of the other parameters in order to be able to quickly recognized already aligned frames from unaligned ones. If you leave all of these blank, the file names will not be changed. Warning: as mentioned earlier, if you leave all these fields blank and you used the same directory of the source files to save the new files, you will be overwriting the original unregistered files.

    Sample format: Select the format (bit depth) to be used in the newly generated aligned images. Normally, using the same depth as the original is recommended, other values can be used for very specific purposes.

    Overwrite existing files: This is an added security setting that, when not checked, prevents from overwriting your originals.

    On error: It specifies what the tool will do in case of problems. It can be t ought to continue, to stop or to ask what to do. Problems can be, for example, difficulties in finding stars.

    Star Detection

    Detection scales: Number of wavelet layers used for structure detection. With more wavelet layers, large stars (and perhaps also some non stellar objects) will be detected.

    Noise scales: Number of wavelet layers used for noise reduction. Noise reduction prevents detection of bright noise structures, including hot pixels and cosmic rays. This parameter can also be used to control the sizes of the smallest detected stars (increase to exclude more stars).

    Hot pixel removal: Size of the hot pixel removal filter. This is the radius in pixels of a median filter applied by the star detector before the structure detection phase. A median filter is very efficient to remove hot pixels. Hot pixels will be identified as false stars, and if present in large amounts, can prevent a valid image registration.

    Log(sensitivity): Logarithm of the star detection sensitivity. The sensitivity of the star detection algorithm is measured with respect to the local background of each detected star. Given a star with estimated brightness “s” and a local background “b”, sensitivity is the minimum value of (s – b)/b necessary to trigger star detection.

    Peak response: Star peak response. If you decrease this value, stars will need to have stronger (more prominent) peaks to be detected bu the star detection algorithm. This is useful to prevent detection of saturated stars, as well as small non stellar features. By increasing this parameter, the star detection algorithm will be more sensitive to peakedness, and hence more tolerant with relatively flat image features.

    Maximum distortion: Maximum star distortion. Star distortion is measured with respect to a perfect square, whose distortion is 1. The distortion of a perfectly circular star is about 0.75 (actually pi/4).

    Inverted image: Invert the image prior to start detection. Select this option to register negative images (dark stars over a bright background).

    Star Matching

    Matcher tolerance: Tolerance of the star matching algorithm, in terms of difference in triangle similarity.

    RANSAC iterations: Maximum RANSAC iterations. You normally should not need to change this parameter, since the number of necessary RANSAC iterations can be determined adaptively. In very difficult cases, however, allowing more RANSAC iterations may help to increase the probability of finding a valid registration model.

    Maximum stars: Maximum number of stars allowed. In the default automatic mode, StarAlignment will perform a series of tries using a predefined sequence of star counts if the initial attempt to register the image fails. This is the recommended setting. To select the automatic mode, specify zero as the value of this parameter.

    Increasing the amount of reference stars is in general not necessary, and it usually just slows down the image registration process with no improvement in registration accuracy. However, when registering images with little superposition (mosaics, or images with large scale differences), it may be necessary using a reduced or expanded set of reference stars, depending on a variety of working scenarios. In these cases, the automatic probing sequence usually works very well, so you normally should not need to change the value of this parameter.

    Triangles per star: Minimum number of triangles per star used by the star matching algorithm. More triangles will increase the probability of finding more putative star pair matches, but at the cost of more computing time. A value between 8 and 20 is appropriate in most cases.

    Use brightness relations: Use brightness relations between alignment stars. Select this option to take into account brightness relations between stars for comparisons performed by the star matching algorithm. This feature greatly improves the robustness of the star matching algorithm, so it is enabled by default. In seldom cases however, trying to match brightness relations may cause problems to register images acquired through different filters; e.g. individual channels of an RGB image.

    Use scale differences: Use scale differences between star matching triangles. Select this option to take into account differences in scale (size) between the triangles used to match pairs of stars. You must also define a scale tolerance when this option is enabled (see the scale tolerance parameter below). When scale differences are taken into account, the star matching algorithm is able to find more true star pair matches in presence of a large number of false putative matches. This feature is useful to improve registration of images with little superposition, as it often happens when building mosaics. However, take into account that enabling this option will prevent registration of images with scale differences larger than the value of the scale tolerance parameter.

    Scale tolerance: Tolerance of the star matching algorithm, in terms of the maximum allowed difference in triangle scale. This parameter is only used when the Use scale differences option is enabled. The value of this parameter is the maximum allowed difference in scale between two triangles formed with putative star pair matches. This improves robustness of the star matching algorithm, especially in presence of a large number of outliers (false putative star pair matches), but also imposes an upper limit on the difference in scale between two registered images. Using scale differences can be very helpful to build mosaics with little superposition.

    Back to the Index | Copyright Note