Data resampling is normally performed by the application:
This resamples an image from pixel coordinates into its Current coordinate system. So if a set of images shares a common Current coordinate system (as added by any of the methods described earlier in this section) then running TRANNDF on them all will enable them to be compared or combined pixel for pixel. The transformation between pixel co-ordinates and the Current co-ordinate system can be of any kind, so the program has the capability of `rubber-sheeting'. A restriction is that both the forward and the inverse transformations must be available. This will only cause problems when using general transformations; a tractable inverse doesn't often exist. If you need to resample and you do not have an inverse transformation, the DRIZZLE program may be used instead, though note this is not designed for general purpose resampling, and is slower than TRANNDF.TRANNDF resamples using one of two different techniques, linear interpolation or nearest neighbour. Linear interpolation uses two pixels to estimate the new pixel value, nearest neighbour just uses the nearest pixel. Flux conservation is available but is only supported for linear transformations. Variances are resampled in the same way as ordinary data.
The size of the output images can be estimated from the transformation of selected boundary positions, which is very useful when transforming whole lists of images as the output images are made only as big as necessary.
To use TRANNDF type something like:
This resamples all the images in the current directory naming the output images the same as the inputs except that the string `-trn' is appended to each output name. By default TRANNDF will guess a size for the output image, interpolate using nearest neighbour and conserve flux.% tranndf in='*' out='*-trn'
Note that TRANNDF resamples into the Current coordinate system, so that each pixel in the output image is a 1.0 x 1.0 square in those coordinates. Thus the coordinate system in question must be a suitable one for that purpose. If it has units of the wrong size, then a suitable transformation can be made by adding a new coordinate system with the WCSEDIT or WCSREG programs. In particular it's no good running TRANNDF on a set of images which have SKY coordinates as Current, since they have units of radians, which are far too big. See the example in the section about WCSREG for how to deal with this.
For a quick look at what the resampled data will look like, the DRAWNDF command with IMAGE=TRUE can be used.
CCDPACK