• Nem Talált Eredményt

2.6 Registering images

2.6.3 Conserving flux

Even if the spatial image transformation does not significantly shrink or enlarge the image, pixels of the target image usually are not mapped exactly to the pixels of the original image (and vice versa). Therefore, some sort of interpolation is needed between the adjacent pixel values in order to obtain an appropriate transformed image. Since the spatial transformation is followed by the steps of convolution and photometry, exact flux conservation is a crucial issue. If the interpolation is performed naively by multiplying the interpolated pixel values with the Jacobian determinant of the spatial mapping, the exact flux conservation property is not guaranteed at all. It is even more relevant in the cases where the transformation includes definite dilation or shrinking, i.e. the Jacobian determinant significantly differ from unity.

In order to overcome the problem of the flux conserving transformations, we have imple-mented a method based on analytical integration of surfaces of which are determined by the pixel values. These surfaces are then integrated on the quadrilaterals whose coordinates are derived by mapping the pixel coordinates on the target frame to the system of the original frame. An example is shown in Fig. 2.16, where the transformation includes a shrink factor of nearly two (thus the Jacobian determinant is∼1/4). In practice, two kind of surfaces are used in the original image. The simplest kind of surface is the two dimensional step function, defined explicitly by the discrete pixel values. Obviously, if the area of the intersections of the quadrilaterals and the pixel squares is derived, the integration is straightforward: it is equivalent with a multiplication of this intersection area by the actual pixel value.

A more sophisticated interpolation surface can be defined as follows. On each pixel, at the position (i, j), we define a biquadratical function of the fractional pixel coordinates (δx, δy), namely

fij(x, y) =

2

X

k=0 2

X

ℓ=0

Ckℓijδxkδy. (2.55)

For each pixel, we define nine coefficients, Ckℓij. We derive these coefficients by both con-straining the integral of the surface at the pixel to be equal to the pixel value itself, i.e.

1

Z

0 1

Z

0

fij(δx, δy) dδxdδy =Pij, (2.56) and requiring the joint function F(x, y) describing the surface

F(x, y) =f[x][y]({x},{y}) (2.57) to be continuous (here [x] denotes the integer part of xand {x}denotes the fractional part, i.e. x= [x] +{x}). This continuity is equivalent to

f[i+1]j(0, y) = fij(1, y), (2.58)

2.6. REGISTERING IMAGES

f[i1]j(1, y) = fij(0, y), (2.59)

fi[j+1](x,0) = fij(x,1), (2.60)

fi[j1](x,1) = fij(x,0), (2.61) for all 0≤ x, y ≤ 1. Since f is a biquadratical function of the fractional pixel coordinates (x, y), it can be shown that the above four equations imply 8 additional constraints for each pixel. At the boundaries of the image, we can define any feasible boundary condition. For instance, by fixing the partial derivatives∂F/∂xand∂F/∂y of the surfaceF(x, y) to be zero at the left/right and the lower/upper edge of the image, respectively. It can be shown that the integral property of equation (2.56), the continuity constrained by equations (2.58)-(2.61) and the boundary conditions define an unique solution for theCkℓij coefficients. This solution exists for arbitrary values of the Pij pixel intensities (note that the complete problem of obtaining the Ckℓij is a system of linear equations). Since the integrals of theF(x, y) surface on the quadrilaterals are linear combinations of polynomial integrals, the pixel intensities on interpolated images can be obtained easily, although it is a bit more computationally expensive.

We should note here that if the transformation is a simple shift (i.e. there are not any dilation, rotation and higher order distortions at all), the two, previously discussed interpolation schemes yield the same results as the classic bilinear and bicubic (Press et al., 1992) interpolation.

In practice, during the above interpolation procedure pixels that have been marked to be inappropriate17 are ignored from the determination of the Ckℓij coefficients, and any inter-polated pixels on the target image inherit the underlying masks of the pixels that intersects their respective quadrilaterals. Pixels on the target frame that are mapped off the original image have a special mask which marks them “outer” ones (see also Sec. 2.3.2). It yields a transparent processing of the images: for instance in the case of photometry, if the aperture falls completely inside the image but intersects one or more pixels having this “outer” mask yields the same photometry quality flag as if the aperture is (partially or completely) off the image. See also Sec. 2.7 or Sec.2.12.13 for additional details.

2.6.4 Implementation

The core algorithms of the interpolations discussed here are implemented in the program fitrans (Sec. 2.12.11). This program performs the spatial image transformation, involv-ing both the naive and the integration-based methods and both the bilinear and bicu-bic/biquadratical interpolations. The transformation itself is the output of the grmatch orgrtrans programs (see also Sec. 2.12.10 and Sec. 2.12.9).

17For instance, pixels that are saturated or have any other undesired mask.

2.7 Photometry

The main step in a reduction pipeline intended to measure fluxes of objects on the sky is the photometry. All of the steps discussed before are crucial to prepare the image to be ready for photometry. Thus at this stage we should have a properly calibrated and reg-istered18 image as well as we have to know the positions of the sources of interest. For each source, the CCD photometry process for a single image yields only raw instrumental fluxes. In order to estimate the intrinsic flux of a target object, ground-based observations use nearby comparison objects with known fluxes. The difference in the raw instrumental fluxes between the target source and the source with known flux is then converted involving smooth transformations to obtain the ratios between the intrinsic flux values. Such smooth transformation might be the identical transformation (this is the simplest of all photometry methods, known as single star comparison photometry) or some higher order transforma-tions for correcting various gradients (mostly in the transparency: due to the large field of view, the airmass and therefore the extinction at the different corners of the image might significantly differ). Even more sophisticated transformations can also be performed in order to correct additional filter- and instrumentation effects yielded by the intrinsic color (and color differences) between the various sources. Corrections can also made in order to trans-form the brightnesses into standard photometric systems. The latter is known as standard transformation and almost in all cases it requires measurements for standard areas as well (Landolt, 1992). Since for all objects, transparency variations cause flux increase or decrease proportional to the intrinsic flux itself, the transformations mentioned above are done on a logarithmic scale (in practice, magnitude scale). For instance, in the case of single-star comparison photometry, the difference between the intrinsic magnitudes and the raw instru-mental magnitudes is constant19. In this section some aspects of the raw and instrumental photometric methods are detailed with the exception of topics related to the photometry on convolved and/or subtracted images. As it was mentioned above, the first step of the photometry is the derivation of the raw instrumental magnitudes of the objects or sources of our interest.

2.7.1 Raw instrumental magnitudes

In principle, raw magnitudes are derived from two quantities. First, the total flux of the CCD pixels are determined around the object centroid. The total flux can be determined in three manners:

18Only if we intend to perform image subtraction based photometry.

19To be precise, only if the spectra of the two stars are exactly the same and the two objects are close enough to neglect the difference in the atmospheric transparency.

2.7. PHOTOMETRY

• If a region is assigned to the object of interest, one has to count the total flux of the pixels inside this region. The region is generally defined to be within a fixed distance from the centroid (so-called aperture), but in the case of diffuse or non-point sources, more sophisticated methods have to be used to define the boundary of the region. The algorithms implemented in the program SExtractor (Bertin & Arnouts, 1996) focus on photometry of such sources. In the following we are interested only in stars and/or point-like sources.

• If the source profile can be modelled with some kind of analytic function (see Sec 2.4.2) or an empirical model function (e.g. the PSF of the image), one can fit such a model surface to the pixels that are supposed to belong to the object (e.g. to the pixels being inside of a previously defined aperture or one of the isophotes). From the fitted parameters, the integral of the surface is derived, and this integral is then treated as the flux of the object. This method for photometry is known as PSF photometry.

• The previous two methods can be combined as follows. After fitting the model function, the best fit surface is subtracted from the pixel values and aperture photometry is performed on this residual. The flux derived from the residual photometry is then added to the flux derived from the best fit surface parameters yielding the total flux for the given object. It is not necessary that the pixels used for surface fitting are the same as the pixels being inside the aperture.

It should be mentioned here that whatever primary method from these above is used to perform the photometry, estimating the uncertainties should be done carefully.

After the total flux of the object has been estimated, one has to remove the flux contri-bution of the background. It is essential in the case of aperture photometry, however, if a profile function is fitted to the pixel values, the contribution of the background is added to the model function as an additional free parameter. If the photometric aperture is a circular region, the background is usually defined as a concentric annulus, whose inner radius is larger than the radius of the aperture. If the field is not crowded, the background level is simply the mean or median of the pixel values found in the annulus. On the other hand, if the field is extremely crowded, the determination of the background level might even be impossible. A solution for this issue can be either profile (PSF) fitting or photometry based on differential images (see Sec. 2.9). Note that on highly crowded fields, apertures significantly overlap.

One advantage of the profile/PSF model fitting method is the ability to fit adjacent profiles simultaneously.

In practice, additional data are obtained and reported for a single raw instrumental photometry measurement, such as:

• Noise estimations, based on the Poisson statistics of the flux values, the uncertainty

0 1