The easiest way to create your own bad-pixel mask for use with the
calibration system, is to run the MAKE_BPM
recipe on a long-exposure dark (at least 20 seconds integration). It
is possible to change the symmetric
-clipping bounds in the
recipe (see primitive _MAKE_BPM_BY_SIGMA_THRESHOLDING_).
You can tailor this primitive if you want more control, say to have
asymmetric rejection or more sophisticated definitions.
[_MAKE_BPM_BY_SIGMA_THRESHOLDING_]
For better results, use the average of long dark frames taken across
two or three nights. First, produce QUICK_LOOK versions of the
long-exposure dark to flatten the NDF structure or convert the FITS
file. Flag all pixels that are 5 standard deviations (
) above
and below the 3-
clipped mean of the dark as ``bad'', then
multiply the resulting frame by zero so that the resulting bad-pixel
mask has data values of 0 and bad only. You can choose your
own thresholds. Here is an example, using data from two nights of
UFTI data and Starlink software.
% oracdr_ufti 20010101
% setenv ORAC_DATA_OUT `pwd`
% oracdr -list 4:4 QUICK_LOOK -nodisplay
% oracdr_ufti 20010102
% setenv ORAC_DATA_OUT `pwd`
% oracdr -list 4:4 QUICK_LOOK -nodisplay
% kappa
% add f20010101_00004_raw f20010102_00004_raw add_darks
% cmult add_darks 0.5 av_darks
% stats av_dark clip=3
% thresh av_darks av_darks_thresh -49 58 bad bad
% cmult av_darks_thresh 0 avbpm title=\"UFTI bpm, January 2001\"
In the above example the 3-
clipped mean was 4.27 and the standard deviation
was 10.727, resulting in
49 and 58 as the lower and upper thresholds.
Then you specify the bad-pixel mask on the command line.
% oracdr -calib mask=avbpm ...
UIST has its own slightly different formula; see DARK_AND_BPM for details.
[UIST/_FIND_BAD_PIXELS_, UIST/_FILE_BAD_PIXELS_, _FILE_MASK_]
ORAC-DR -- imaging data reduction