Debian Codegraph @

stdred/ccdred/proc/ccdinit.prg

raw
1 ! @(#)ccdinit.prg 19.1 (ES0-DMD) 02/25/03 14:16:00
2 !+++++++++++++++++++++++++++++++++++++++++++++++++++++++
3 !.COPYRIGHT (C) 1992 European Southern Observatory
4 !.IDENT ccdinit.prg
5 !.AUTHOR Rein H. Warmels, ESO-Garching
6 !.KEYWORDS Direct imaging, CCD package
7 !.PURPOSE Create and set keywords of the context ccd
8 !.VERSION 920916 RHW Creation
9 !-------------------------------------------------------
10 !
11 IF P1(1:1) .NE. "?" GOTO INIT
12 !
13 !Begin Session List
14 !GEneral
15 ! *** Create keywords for telescope and detector
16 WRITE/KEYW IDENT/C/1/20 "?" ! object identification
17 WRITE/KEYW OBSER/C/1/20 "?" ! observer
18
19 WRITE/KEYW TELES/C/1/20 "?" ! Telescope ID descriptor
20 WRITE/KEYW INSTR/C/1/20 "?" ! Instrument ID descriptor
21 WRITE/KEYW DETEC/C/1/20 "?" ! Detector ID descriptor
22 WRITE/KEYW NPIXX/I/1/2 -99999 ! number of pixels in x
23 WRITE/KEYW NPIXY/I/1/1 -99999 ! number of pixels in y
24 WRITE/KEYW SPIXX/I/1/1 -99999 ! pixel size in x in micron
25 WRITE/KEYW SPIXY/I/1/1 -99999 ! pixel size in y in micron
26 WRITE/KEYW DIRECT/C/1/3 "?" ! readout direction (x or y)
27 WRITE/KEYW BINNING/I/1/2 -99999,-99999 ! binning factors (x and y)
28 WRITE/KEYW READMOD/C/1/4 "?" ! readout mode (slow or fast)
29 WRITE/KEYW READON/R/1/1 -99999 ! readout noise per ADU
30 WRITE/KEYW AD_VAL/R/1/2 -99999 ! analog to digital (e-/ADU)
31 !
32 ! *** keywords for information about the data
33 WRITE/KEYW CCD_IN/C/1/60 "?" ! input frame or table
34 WRITE/KEYW OV_SEC/C/1/40 "[<,<:>,>]" ! overscan section
35 WRITE/KEYW IM_SEC/C/1/40 "[<,<:>,>]" ! useful data frame
36 !
37 !BiaS
38 ! *** combining parameters for bias frames
39 WRITE/KEYW BS_TYP/C/1/60 "*" ! bias exposure type allowed
40 WRITE/KEYW BS_SIG/C/1/3 "no" ! generate output sigma frame
41 WRITE/KEYW BS_MET/C/1/20 "maxrej" ! method of combining
42 WRITE/KEYW BS_DEL/C/1/3 "no " ! delete input cat + frames
43 WRITE/KEYW BS_EXP/C/1/3 "no " ! scale by exposure time
44 WRITE/KEYW BS_STA/C/1/6 "mode" ! correction by Mode/Median/Mean
45 WRITE/KEYW BS_SCA/C/1/3 "no " ! scale by the MMM
46 WRITE/KEYW BS_OFF/C/1/3 "no " ! add offset from MMM
47 WRITE/KEYW BS_WEI/C/1/3 "yes" ! use the weighted average
48 WRITE/KEYW BS_SEC/C/1/40 "[<,<:>,>]" ! frame section for finding MMM
49 WRITE/KEYW BS_RAN/R/1/2 -99999,99999 ! pixel range used for combining
50 WRITE/KEYW BS_CLP/R/1/2 3.0,3.0 ! low/high sigma clipping factor
51 WRITE/KEYW BS_NUL/C/1/20 {NULL(2)} ! blank value for rejections
52 !
53 !Dark
54 ! *** combining parameters for dark frames
55 WRITE/KEYW DK_TYP/C/1/60 "*" ! dark exposure type allowed
56 WRITE/KEYW DK_SIG/C/1/3 "no" ! generate an output sigma frame
57 WRITE/KEYW DK_MET/C/1/20 "median" ! method of combining
58 WRITE/KEYW DK_DEL/C/1/3 "no " ! delete input cat + frames
59 WRITE/KEYW DK_EXP/C/1/3 "yes" ! scale by exposure time
60 WRITE/KEYW DK_STA/C/1/6 "mode" ! correction by Mode/Median/Mean
61 WRITE/KEYW DK_SCA/C/1/3 "no " ! scale by the MMM
62 WRITE/KEYW DK_OFF/C/1/3 "no " ! add offset from MMM
63 WRITE/KEYW DK_SEC/C/1/40 "[<,<:>,>]" ! frame section for finding MMM
64 WRITE/KEYW DK_WEI/C/1/3 "yes" ! use the weighted average
65 WRITE/KEYW DK_RAN/R/1/2 -99999,99999 ! pixel range used for combining
66 WRITE/KEYW DK_CLP/R/1/2 3.0,3.0 ! low/high sigma clipping factor
67 WRITE/KEYW DK_NUL/C/1/20 {NULL(2)} ! blank value for rejections
68 !
69 !Flat Field
70 ! *** combining parameters for dome flats
71 WRITE/KEYW FF_TYP/C/1/60 "*" ! flat exposure type allowed
72 WRITE/KEYW FF_SIG/C/1/3 "no" ! generate an output sigma frame
73 WRITE/KEYW FF_MET/C/1/20 "median" ! method of combining
74 WRITE/KEYW FF_DEL/C/1/3 "no " ! delete input cat + frames
75 WRITE/KEYW FF_EXP/C/1/3 "yes" ! scale by exposure time
76 WRITE/KEYW FF_STA/C/1/6 "mode" ! correction by Mode/Median/Mean
77 WRITE/KEYW FF_SCA/C/1/3 "yes" ! scale by the MMM
78 WRITE/KEYW FF_OFF/C/1/3 "no " ! add offset from MMM
79 WRITE/KEYW FF_SEC/C/1/40 "[<,<:>,>]" ! frame section for finding MMM
80 WRITE/KEYW FF_WEI/C/1/3 "no" ! use the weighted average
81 WRITE/KEYW FF_RAN/R/1/2 -99999,99999 ! pixel range used for combining
82 WRITE/KEYW FF_CLP/R/1/2 3.0,3.0 ! low/high sigma clipping factor
83 WRITE/KEYW FF_NUL/C/1/20 {NULL(2)} ! blank value for rejections
84 !
85 !SKy
86 ! *** combining parameters for sky flats
87 WRITE/KEYW SK_TYP/C/1/60 "*" ! sky exposure type allowed
88 WRITE/KEYW SK_SIG/C/1/3 "no" ! generate an output sigma frame
89 WRITE/KEYW SK_MET/C/1/20 "avsigclip" ! method of combining
90 WRITE/KEYW SK_DEL/C/1/3 "no " ! delete input cat + frames
91 WRITE/KEYW SK_EXP/C/1/3 "yes" ! scale by exposure time
92 WRITE/KEYW SK_STA/C/1/6 "mode" ! correction by Mode/Median/Mean
93 WRITE/KEYW SK_SCA/C/1/3 "yes" ! scale by the MMM
94 WRITE/KEYW SK_OFF/C/1/3 "no " ! add offset from MMM
95 WRITE/KEYW SK_SEC/C/1/40 "[<,<:>,>]" ! frame section for finding MMM
96 WRITE/KEYW SK_WEI/C/1/3 "no" ! use the weighted average
97 WRITE/KEYW SK_RAN/R/1/2 -99999,99999 ! pixel range used for combining
98 WRITE/KEYW SK_CLP/R/1/2 3.0,3.0 ! low/high sigma clipping factor
99 WRITE/KEYW SK_NUL/C/1/20 {NULL(2)} ! blank value for rejections
100 !
101 !OTher
102 ! *** combining parameters for other frames
103 WRITE/KEYW OT_TYP/C/1/60 "*" ! other exposure type allowed
104 WRITE/KEYW OT_SIG/C/1/3 "no" ! generate an output sigma frame
105 WRITE/KEYW OT_MET/C/1/20 "average" ! method of combining
106 WRITE/KEYW OT_DEL/C/1/3 "no " ! delete input cat + frames
107 WRITE/KEYW OT_EXP/C/1/3 "yes" ! scale by exposure time
108 WRITE/KEYW OT_STA/C/1/6 "mode" ! correction by Mode/Median/Mean
109 WRITE/KEYW OT_SCA/C/1/3 "yes" ! scale by the MMM
110 WRITE/KEYW OT_OFF/C/1/3 "no " ! add offset from MMM
111 WRITE/KEYW OT_SEC/C/1/40 "[<,<:>,>]" ! frame section for finding MMM
112 WRITE/KEYW OT_WEI/C/1/3 "yes" ! use the weighted average
113 WRITE/KEYW OT_RAN/R/1/2 -99999,99999 ! pixel range used for combining
114 WRITE/KEYW OT_CLP/R/1/2 3.0,3.0 ! low/high sigma clipping factor
115 WRITE/KEYW OT_NUL/C/1/20 {NULL(2)} ! blank value for rejections
116 !
117 !MOsaic
118 ! *** combining parameters for mosaicing
119 WRITE/KEYW MO_SEC/C/1/40 "[<,<:>,>]" ! frame section for finding mean
120 WRITE/KEYW MO_SUBT/C/1/10 "no" ! subtraction option
121 WRITE/KEYW MO_CORN/C/1/2 "ll" ! starting position in output
122 WRITE/KEYW MO_DIREC/C/1/3 "row" ! add subraster row/column wise
123 WRITE/KEYW MO_RAST/C/1/3 "no " ! add in raster pattern
124 WRITE/KEYW MO_OVER/I/1/2 -1,-1 ! # col/row between adj. frames
125 WRITE/KEYW MO_INTER/C/1/20 "LINEAR" ! interpolation method
126 WRITE/KEYW MO_TRIM/I/1/4 1,1,1,1 ! trim columns and rows
127 WRITE/KEYW MO_MNPX/I/1/1 100 ! minimal number of pixels
128 WRITE/KEYW MO_NUL/C/1/20 {NULL(2)} ! blank value for rejections
129 !
130 !OVerscan
131 ! *** parameters for the overscan dtermination
132 WRITE/KEYW OV_IMODE/C/1/10 "yes" ! fit overscan interactively
133 WRITE/KEYW OV_FUNCT/C/1/20 "linear" ! fitting function
134 WRITE/KEYW OV_ORDER/I/1/1 3 ! number of polynomial terms
135 WRITE/KEYW OV_AVER/I/1/1 1 ! number of points to combine
136 WRITE/KEYW OV_ITER/I/1/1 1 ! number of iterations
137 WRITE/KEYW OV_REJEC/R/1/1 3. ! sigma rejection factor
138 !
139 !FiX bad pixels
140 ! *** parameters for the bad pixel correction!
141 WRITE/KEYW FX_TABLE/C/1/60 "none" ! table with bad pixels area
142 WRITE/KEYW FX_METH/C/1/3 "PIX" ! correction option to use
143 WRITE/KEYW FX_FACT/I/1/2 3,3 ! expansion factor
144 WRITE/KEYW FX_FPAR/I/1/3 2,2,5 ! fitting parameters
145 WRITE/KEYW FX_NOISE/C/1/3 "yes" ! gaussian noise option
146 !
147 !ILlumination
148 ! *** parameters for illumination frame
149 WRITE/KEYW IL_TYP/C/1/60 "?" ! exposure type for illum. frame
150 WRITE/KEYW IL_XBOX/R/1/2 5.,0.25 ! max box at edges, elsewhere
151 WRITE/KEYW IL_YBOX/R/1/2 5.,0.25 ! max box at edges, elsewhere
152 WRITE/KEYW IL_CLIP/C/1/3 "yes" ! clipping the input pixels
153 WRITE/KEYW IL_SIGMA/R/1/2 2.5,2.5 ! low and high clipping sigma
154 !
155 !FRinge
156 ! *** parameters for fringe frame
157 WRITE/KEYW FR_TYP/C/1/60 "?" ! exposure type for fringe frame
158 !
159 !SCience
160 ! *** parameters for the science correction
161 WRITE/KEYW SC_TYP/C/1/60 "*" ! science exposure type allowed
162 WRITE/KEYW SC_PROC/C/1/3 "no" ! list processing steps only
163 WRITE/KEYW SC_SCAN/C/1/3 "no" ! do the overcan correction
164 WRITE/KEYW SC_TRIM/C/1/3 "no" ! trim the frame(s)
165 WRITE/KEYW SC_FXPIX/C/1/3 "no" ! fix bad pixel or columns
166 WRITE/KEYW SC_BSCOR/C/1/3 "yes" ! do the bias correction
167 WRITE/KEYW SC_BSFRM/C/1/60 " " ! bias calibration frame
168 WRITE/KEYW SC_DKCOR/C/1/3 "yes" ! do the dark correction
169 WRITE/KEYW SC_DKFRM/C/1/60 " " ! dark calibration frame
170 WRITE/KEYW SC_FFCOR/C/1/3 "yes" ! do the flat fielding
171 WRITE/KEYW SC_FFFRM/C/1/60 " " ! flat calibration frame
172 WRITE/KEYW SC_ILCOR/C/1/3 "no" ! do illumination correction
173 WRITE/KEYW SC_ILFRM/C/1/60 " " ! illumination frame
174 WRITE/KEYW SC_SKFRM/C/1/60 " " ! empty sky frame
175 WRITE/KEYW SC_FRCOR/C/1/3 "no" ! do fringing correction
176 WRITE/KEYW SC_FRFRM/C/1/60 " " ! fringing calibration frame
177 !
178 ! *** file names and error keywords
179 WRITE/KEYW VERBOSE/C/1/3 "no" ! print standard output
180 WRITE/KEYW REDUCT/C/1/8 "offline" ! off/on line data reduction
181 WRITE/KEYW CCDCORS/C/1/20 "XXXXXXXXXXXXXXXXXXXX" ! reduction options
182 WRITE/KEYW CCDCOR/C/1/3 "NO " ! reduction flag
183 WRITE/KEYW CCDCMD/C/1/40 "?" ! last command executed
184
185 WRITE/KEYW CCDSCAN/C/1/60 " " ! overscan image
186 WRITE/KEYW SCANSEL/C/1/80 "ALL" ! valid pixel range for overscan
187 WRITE/KEYW CCDMEAN/R/1/1 -99999 ! mean value
188 WRITE/KEYW CCDDARK/R/1/1 -99999 ! dark scaling factor
189 WRITE/KEYW CCDFLAT/R/1/1 -99999 ! flat scaling factor
190 WRITE/KEYW CCDILLUM/R/1/1 -99999 ! illumination scaling factor
191 WRITE/KEYW CCDFRING/R/1/1 -99999 ! fringe scaling factor
192 !
193 ! *** here for the standard column names
194 WRITE/KEYW SC_COL/C/1/60 "?" ! standard science column name
195 WRITE/KEYW BS_COL/C/1/60 "?" ! standard bias column name
196 WRITE/KEYW DK_COL/C/1/60 "?" ! standard dark column name
197 WRITE/KEYW FF_COL/C/1/60 "?" ! standard flat column name
198 WRITE/KEYW SK_COL/C/1/60 "?" ! standard sky column name
199 WRITE/KEYW IL_COL/C/1/60 "?" ! standard illum. column name
200 WRITE/KEYW FR_COL/C/1/60 "?" ! standard fringe column name
201 ! *** end Session List
202 !
203 ! *** Initialize CCD context
204 REGISTER/SESSION CCD STD_PROC ccdinit.prg ccdtab.tbl
205 !
206 @s ccdcopy ! copy the procedure and table
207 @s eso_descr ! copy ESO standard descriptors
208 RETURN ! all done
209 !
210 ! *** here for restoring the keyword from a session control table
211 INIT:
212 SAVINI/CCD {P1}_CCDSAVE.tbl READ
213 WRITE/OUT "*** INFO: CCD context setting restored for session <{P1}>"
214
215
216
217
218