Spectroscopic FLAT frames are derived from sets of lamp on and lamp off pairs for each grism. These are obtained using the incandescent lamp in the Comparison Lamp Module. The FLAT frames are formed in the same way as the FLAT frames for imaging datasets by differencing and then combining the linearized lamp on and lamp off pairs using the cspflat task. The inputs required are a list of lamp on frames, a list of lamp off frames, and an output filename. For example,
cspflat ir007,ir009,ir011 ir008,ir010,ir012 flat_jh comb_opt=average
averages the lamp on frames ir007-11 and the lamp off frames ir008-10, takes their difference, then normalizes the median pixel value of the difference in the image section specified by the statsec parameter to unity, and writes the resulting FLAT frame to the file flat_jh. The statsec parameter should be set to the image section corresponding to the central strip of one of the orders. No attempt is made to correct for the spectral distribution of the lamp or any non-uniformity in the slit illumination by the lamp.
The cspflat task has the parameters listed below.
I R A F
Image Reduction and Analysis Facility
PACKAGE = caspir
TASK = cspflat
ons = ir007,ir009,ir011 List of lamp ON frames
offs = ir008,ir010,ir012 List of lamp OFF frames
flat = flat_jh Output flatfield frame
(comb_op= average) Type of combine operation
(statsec= [150:170,50:200]) Image section for computing statistics
(verbose= yes) Verbose output?
(imglist= )
(mode = ql)
The comb_opt parameter should be average if the number of on or off exposures is less than about 5 and median if greater than about 5.
The object, sky, and comparison images for the specified base spectrum name are flattened by unsetting the combine flag in redxspec, setting the flatten flag, and setting the flatfile parameter to the appropriate FLAT frame filename.