Next: Camera Control
Up: GCX User's Manual
Previous: The World Coordinate System
  Contents
Subsections
To measure stars, we need to know where the stars are located. We need some standards
to compare them with. And we need some way of estimating the accuracy of our results.
In GCX all photometry targets are specified using their world coordinates (right ascension,
declination and epoch). While it is possible to trick the program into just using stars from the
image, this is not very useful. Looking up maps and clicking on stars is a tedious and
error-prone process. It's also very difficult to check the results.
The program has a powerful world coordinate fitting algorithm. It is always prefferable to
try to use it, than attempting to work without. See the tutorial and the WCS section
for more details.
During a photometry run, the following information is used:
- The position, orientation an scale of the field -- an initial WCS in GCX
parlance. These vales only have to be known approximately; the program reads this
information from the FITS header.
- The exact catalog positions of several field stars distributed across the field;
these can be read from a recipy file or directly from the GSC.
- The positions and magnitudes of one or more standard stars. These are normally read from
a recipy file.
- The positions of the stars we want to measure (called variable stars). These also
come from the recipy file.
- Some parameters from which the noise can be estimated. They are:
the number of electrons per intensity unit, the read noise of the camera,
the noise of the dark frames used to calibrate, the noise of the flat field used to
calibrate, telescope aperture, integration time and airmass (for estimating scintillation).
These parameters are read from the FITS header.
- The airmass. The program can calculate the airmass of the observation if it knows the
location of the observing site, the date/time of the observation and of course the field
coordinates) - which again come from the FITS header. Of course, the time of the observation
should be recorded accurately in any case.
- A bad pixel map for the camera; it is used to flag situations where a bad pixel
falls on a star we want to measure.
Not all parameters are equally important. Some noise parameters may be ``guessed'' by the program.
Many parameters can be added to the fits header after the observation is made, as they are
fixed for a given observer and equipment setup.
Once all the data is gathered, reduction proceeds as follows:
- The WCS of the frame is fitted;
- For each star we want to measure, the program calculated the pixel position inside
the frame and looks around that position for a peak that looks like a star. If a peak is found
within a certain distance, the position is corrected to the centroid of that star image.
This step can be disabled.
- The total flux within a circular aperture centered on the corrected position is
calculated. The size of the aperture can be set by the user. If bad pixels are found within
the aperture, the situation is flagged. The noise associated to this value is calculated using
the supplied noise parameters.
- A histogram is constructed from the values of pixels in an annular aperture concentric with
the first. The size of the annulus can be set by the user. The sky backgound level is estimated
from this area, using one of the following methods: mean, median, mean with
-
clipping, mean-median or synthetic mode. The noise associated to the
background is also estimated.
- The background is substracted from the star flux, and the noise contributions are
added in quadrature. Scintillation noise (a multiplicative factor) is estimated and added to
the noise.
- The resulting flux and noise is converted to the magnitude scale.
- For standard stars the error from the input data is added to the noise. From here on, we
will use the term error. For standard stars without error information, a default error is added,
and the situation is flagged.
- A robust fit algorithm is used to determine the transformation between the instrumental
and standard values.
The fit algorithm also calculates the expected error of the transformation coefficients and the
mean error of unit weight, which indicates the quality of the fit.
- Finally, a report is generated. In many cases, finding an accurate solution is not possible
just from analysing one frame. The report contains enough information so that many observations
can be reduced together in a later step. However, collective reduction of many observations is
beyond the scope of this program.
The issue of noise modelling is essential in any photometric endeavour. Measurement values
are next to meaningless if they aren't acompanied by a measure of ther uncertainty.
One can assume that the noise and error modelling only applies to deriving an error figure.
This in true only in extremely simple cases. In general, the noise estimates will also affect
the actual values. For instance, suppose that we use several standards to calibrate a field.
From the noise estimate, we know that one of the standards has a large probable error. Then,
we choose to exclude (or downweight) that value from the solution--this will change the
calibration, and directly affect the result (not just it's noise estimate).
The precision of a measurement denotes the degree to
which different measurements of the same value will yield the same result; it measures the
repeatability of the measurement process. A precise measurement has a small random error.
The accuracy of a measurement denotes the degree to which a measurement result will represent
the true value. The accuracy includes the random error of the measurement, as well as
the systematic error.
Random errors are in a way the worst kind. We have to accept them and take into account, but
they cannot be calculated out. We can try to use better equipment, or more telescope time
and reduce them. On the other hand, since random errors are, well, random in nature (they
don't correlate to anything), we can in principle reduce them to an aribitrarily low level
by averaging a lerge number of measurements.
Systematic errors on the other hand can usually be eliminated (or at least reduced) by
calibration. Systematic errors are not that different from random errors. They differ
fundamentally in the fact the they depend on something. Of course, even random
errors ultimately depend on something. But that something changes incontrollably, and
in a time frame that is short compared to the measurement time scale.
A systematic error can turn into a random error if we have no control over the thing that
the error depends on, or we don't have something to calibrate against. We could treat this
error as ``random'' and try to average many measurements to reduce it, but we have to make
sure that the something that the error depends on has had a change to vary between the
measurements we average, or we won't get very far.
is the ``randomest'' source of random errors. We have no way to
calibrate out noise, but it's features are well understood and relatively easy to model.
One doesn't have a good excuse not to model noise reasonably well.
We will generally talk about ``noise'' when estimating random errors that derive from
electrical noise sorce. Once these are combine with other error sources (like for instance
expected errors of he standards), we will use the term ``error''. Of course, there are two
ways of understanding an error value. If we know what the true value should be, we can talk
about and actual error. If we just consider what error level we can expect, we talk
about an estimated, or expected error.
There are several noise sources in a CCD sensor. We will see that in the end they can
usually be modeled with just two parameters, but we list the main noise contributors
for reference.
- Photon shot noise is the noise associated with the random arrival of photons
at any detector. Shot noise exists because of the discrete nature of light and
electrical charge. The time between photon arrivals is goverened by Poisson
statistics. For a phase-insensitive detector, such as a CCD,
where
is the signal expressed in electrons. Shot noise is sometimes called
``Poisson noise''.
- Output amplifier noise originates in the output amplifier of the sensor.
It consists of two components: thermal (white) noise and flicker noise. Thermal noise
is independent of frequency and has a mild temperature dependence (is proportional to
the square root of the absolute temperature). It fundamentally originates in the thermal
movement of atoms. Flicker noise (or 1/f noise) is strongly dependent on frequency.
It originates in the existance of long-lived states in the silicon crystal (most notably
``traps'' at the silicon-oxide interface).
For a given readout configuration and speed, these noise sources contribute a constant
level, that is also independant of the signal level, usually called the readout noise.
The effect of read noise can be reduced by increasing the
time in which the sensor is read out. There is a limit to that, as
flicker noise will begin to kick in. For some cameras, one has the option of trading readout
speed for a decrease in readout noise.
- Camera noise. Thermal and flicker noise are also generated in
the camera electronics. the noise level will be independent on the signal.
While the camera designer needs to make a distiction between the
various noise sources, for a given camera, noise originating in the camera and the ccd
amplifier are indistinguishable.
- Dark current noise. Even in the absence of light, electron-hole pairs are generated
inside the sensor. The rate of generation depends exponentially on temperature (typically
doubles every 6-7 degrees). The thermally generated electrons cannot be separated from
photo-generated photons, and obey the same Poisson statistic, so
We can substract the average
dark signal, but the shot noise associated with it remains. The level of the dark current
noise depends on temperature and integration time.
- Clock noise. Fast changing clocks on the ccd can also generate spurious charge.
This charge also has a shot noise component associated. However, one cannot read the sensor
without clocking it, so clock noise cannot be discerned from readout noise. The clock noise
is fairly constant for a given camera and readout speed, and independent of the signal level.
Examining the above list, we see that some noise sources are independent of the signal level.
They are: the output amplifier noise, camera noise and clock noise. They can be combined in
a single equivalent noise source. The level of this source is called readout noise, and
is a characteristic of the camera. It can be expressed in electrons, or in the camera output
units (ADU).
The rest of the noise sources are all shot noise sources. The resulting value will be:
is the total signal from the sensor expressed in electrons. So to calculate the
shot noise component, we just need to know how many ADUs/electron the camera produces. This
is a constant value, or one of a few constant values for cameras that have different gain
settings. We will use
to denote this value.
We will now try to model the level of noise in a pixel value. The result of reading one pixel
(excluding noise) is:
where
is a fixed bias introduced by the camera electronics,
is the number of
dark electrons, and
is the number of photo-generated electrons (which is the number
of photons incident on the pixel multiplied by the sensor's quantum efficiency).
Now let's calculate the noise associated with this value.
Where
is the readout noise expressed in ADU, and
is the total signal
expressed in electrons. Note that we cannot calculate
the noise if we don't know the bias value. The bias can be determined by reading
frames with zero exposure time (bias frames). These will contribute some read noise though.
By averaging several bias frames, the noise contribution can be reduced. Another approach is
to take the average across a bias frame and use that value for the noise calculation of all
pixels. Except for very non-uniform sensors this approach works well. GCX supports both
ways.
Note that a bias frame will only contain readout noise. By calculating the standard
deviation of pixels across the difference between two bias frames is
times the
readout noise.
A common situation is when one substracts a dark frame, but doesn't use bias frames.
The noise associated with the dark frame is:
The resulting pixel noise after dark frame substraction will be:
while the signal will be
Using just the camera noise parameters, we cannot determine the noise anymore.
We have to keep track of the dark substraction and it's noise effects. We however
rewrite the dark-substracted noise equation as follows:
If we use the notation
, we get:
This is identical in form to the simple pixel noise equation, except that the true
camera readout noise is replaced by the equivalent read noise
. What's more, the
bias is no longer an issue, as it doesn't appeear in the signal equation anymore. We can
derive the pixel noise from the signal directly, as:
The same parameters,
and
are sufficient to describe the noise in the
dark-substracted frame.
To flat-field a frame, we divide the dark-substracted pixel value
by the flat field
value
. The noise of the flat field is
. The resulting signal value is
If we neglect second-order noise terms, the noise of the flat-fielded, dark substracted pixel
is:
The problem with this result is that f is not constant across the frame. So in general, the noise
of a flat-fielded frame cannot be described by a small number of parameters. In many cases though,
doesn't vary too much across the frame. We can then use it's average value,
for the noise calculation. This is the approach taken by the program.
We can identify the previous noise parameters,
and
. We have to introduce a new parameter,
.
Without reducing generality, we can arrange for
. This means that the
average values on the frames don't change with the flatfielding operation, and is a common
choice.
In this case,
and
aren't affected by the flatfielding operation, while the
third noise parameter becomes
, which is the reciprocal of the SNR of
the flat field.
GCX models the noise of each pixel in the frame by four parameters:
,
,
and
. The noise function
of each pixel
is:
comes from the RDNOISE field in the frame header.
is the
reciprocal of the value of the ELADU field.
comes from
FLNOISE, while
comes from DCBIAS.
Every time frames are processed
(dark and bias substracted, flatfielded, scaled etc), the noise parameters are updated.
Once we know the noise of each pixel, deriving the expected error of an instrumental magnitude
is straightforward. Let
be the number of pixels in the sky annulus, and
the level
of each pixel. The noise of the sky estimate is:
1
Now let
be the number of pixels in the central aperture. The noise from these pixels is:
The total noise after sky substraction will be:
.
The program keeps track and reports separately the photon shot noise, the sky noise,
the read noise contribution and the scintillation noise.
Scintillation is an atmospheric effect, which results in a random variation of the
received flux from a star. We use the following formula for scintillation noise:
Where
is the total flux received from the star,
is the airmass of the observation,
is the telescope aperture in cm, and
is the integration time. Scintillation varies
widely over time, so the above is just an estimate.
Finally, we can calculate the expected error of the instrumental magintude as
Having obtained instrumental magnitudes and error estimates for the standard stars,
the program proceeds to finding a transformation between the instrumental and standard
system. If color information is not present, or there aren't enough standards of different
color, only a zeropoint for the transform is calculated. If the program decides there is
enough information, it will determine both a zeropoint and a color coefficient.
2
A robust fitting algorithm is implemented, which proceeds as follows:
- First, the natural weights for each standard star are calculated as
where
is the estimated error of the instrumental magnitude, and
is the error of the standard magnitude (obtained from the recipy file).
- The values are fitted using these weights. For the no-colors case, the fit is simply
a weighted mean; When color coefficients are fitted, linear regression is used.
- The residuals
for each star are calculated.
- The weights are adjusted based on how much the residuals differ from their expected
values. The following function is used:
Th weighting function reduces the weight of values that have residuals
times larger
than expected to one half. Of course values with even larger residuals are downweighted even
more. The parameter
tunes the ``sharpness'' of the weighting function.
- steps 2-5 above are repeated until the solution converges (or the iteration
limit is reached).
- Finally, the error for the estimated parameters is calculated. In the no-colors
situation, the error for the zeropoint is calculated as follows:
fwhile the mean error of unit weight is:
where
is the number of standard stars. The mean error of unit weight
is 1 in the ideal case (when all the errors are estimated correctly). A significantly
larger value should raise doubts about the error estimates.
An example report is shown below.
( observation
( object "rs-lyr" ra "19:13:01.88" dec "33:24:46.13"
equinox 2000 jdate 2452760.45870622
telescope "30cm SCT FLEN=2000.0" aperture 30.0
exptime 20.00 sns_temp 238.0 filter "v"
)
noise (read 7.3 eladu 2.0 flat 0.0 scint 0.003)
ap_par (r1 3 r2 9 r3 13 sky_method "median" sigmas 3.0)
stars (
( name "GSC2657-0144" type std
smags "v(aavso)=12.300 p(gsc)=11.750" imags "v=-9.958/0.010"
residual 0.066 weight 384.712
flags ( centered undef_err )
noise (sky 0.001 read 0.004 photon 0.008 scint 0.003) )
( name "GSC2657-0268" type std
smags "v(aavso)=13.000 p(gsc)=12.710" imags "v=-9.149/0.016"
residual -0.043 weight 362.665
flags ( centered undef_err )
noise (sky 0.003 read 0.008 photon 0.012 scint 0.003) )
( name "GSC2657-0835" type std
smags "v(aavso)=9.200 p(gsc)=9.010" imags "v=-12.967/0.004"
residual -0.025 weight 397.903
flags ( centered undef_err )
noise (sky 0.000 read 0.000 photon 0.002 scint 0.003) )
( name "RS-LYR" type var
comments "VMAG=(9.2 15.8) SPECTYPE=M5e VARTYPE=M VARID=1909+33"
smags "v(aavso)=13.684/0.054" imags "v=-8.508/0.025"
flags ( centered )
noise (sky 0.005 read 0.015 photon 0.016 scint 0.003) )
)
transform (zerop 22.192 zp_err 0.048 me1 1.14)
)
The report is in the form of an association list,
i.e. a list of name-value pairs. Some
values can also be lists. Top-level list elements are:
- observation
- a list of parameters that globally describe the observation. They are
taken straight from the FITS header of the frame being reduced.
- noise
- the noise parameters from the frame header.
- ap_par
- photometry process parameters used. These parameters are read from the
configuration file, and can be modified in the Options dialog.
- stars
- a list of the stars that have been measured. The instrumental magnitudes,
derived standard magnitudes are listed here. The error estimate for the star
is broken down in components (from the sky baground estimation, from read noise,
from photon shot noise and from scintillation). The total error appears in the error
field of the instrumental magnitude. For standard stars, the residual and the weight used in the
fit are listed. A list of flags in included, which signal occurences in the reduction process
that can have an influence on results.
- transform
- the parameters of the trasformation from instrumental to standard, as determined
by the program.
Next: Camera Control
Up: GCX User's Manual
Previous: The World Coordinate System
  Contents
Radu Corlan
2004-01-12