Pre-image recipe / makeIRAFCompatible needs to:
-
call applyDQPlabe() to fill in the DQ masked pixels. May need multiple calls to this, to
-
- a) fill in isolated pixels like CRs or saturated stars with value from surrounding pixels, and
-
- b) fill in all the unilluminated area at the edge of the image with a global median sky value. The latter is what IRAF does and without it, GMMPS autoscale is not helpful.
-
remove the VAR and DQ extensions from the output _preimage, because they confuse sextractor in the configuration used in mask making.