GIRAFFE Pipeline Reference Manual

giwlcalibration.h
1 /*
2  * This file is part of the GIRAFFE Pipeline
3  * Copyright (C) 2002-2019 European Southern Observatory
4  *
5  * This program is free software; you can redistribute it and/or modify
6  * it under the terms of the GNU General Public License as published by
7  * the Free Software Foundation; either version 2 of the License, or
8  * (at your option) any later version.
9  *
10  * This program is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13  * GNU General Public License for more details.
14  *
15  * You should have received a copy of the GNU General Public License
16  * along with this program; if not, write to the Free Software
17  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
18  */
19 
20 #ifndef GIWLCALIBRATION_H
21 #define GIWLCALIBRATION_H
22 
23 #include <cxtypes.h>
24 
25 #include <cpl_macros.h>
26 #include <cpl_parameterlist.h>
27 
28 #include <gitable.h>
29 #include <girange.h>
30 #include <gilinedata.h>
31 #include <gilocalization.h>
32 #include <giextraction.h>
33 #include <giwlsolution.h>
34 
35 
36 #ifdef __cplusplus
37 extern "C" {
38 #endif
39 
40 
49 struct GiWCalConfig {
50 
55  cxint line_nwidths;
56 
61  cxint *line_widths;
62 
69  cxdouble line_separation;
70 
76  cxdouble line_fluxratio;
77 
83  cxdouble line_brightness;
84 
90  cxint line_count;
91 
96  GiRange *line_wlrange;
97 
98 
106  cxchar *line_model;
107 
114  cxchar *line_residuals;
115 
121  cxdouble line_threshold;
122 
127  cxdouble line_offset;
128 
134  cxint line_niter;
135 
141  cxint line_ntest;
142 
148  cxdouble line_dchisq;
149 
156 
163 
168  cxdouble line_saturation;
169 
174  cxint16 slit_position;
175 
180  cxdouble slit_dx;
181 
186  cxdouble slit_dy;
187 
192  cxdouble slit_phi;
193 
201  cxchar *opt_model;
202 
208 
214  cxbool opt_solution;
215 
221  cxbool opt_subslits;
222 
227  cxint16 opt_flags;
228 
234  cxint opt_niter;
235 
241  cxint opt_ntest;
242 
248  cxdouble opt_dchisq;
249 
255  cxdouble pxw_cliplevel;
256 
263 
269  cxdouble pxw_clipmfrac;
270 
275  cxint pxw_xorder;
276 
281  cxint pxw_yorder;
282 
288  cxdouble xws_cliplevel;
289 
296 
302  cxdouble xws_clipmfrac;
303 
308  cxint xws_xorder;
309 
314  cxint xws_yorder;
315 
316 };
317 
318 typedef struct GiWCalConfig GiWCalConfig;
319 
320 
321 struct GiWCalData {
322  GiTable *coeffs;
323  GiTable *lines;
324  GiLineData *linedata;
325 };
326 
327 typedef struct GiWCalData GiWCalData;
328 
329 
330 GiWCalData *giraffe_wcaldata_new(void);
331 void giraffe_wcaldata_delete(GiWCalData *self);
332 
333 
334 cxint giraffe_calibrate_wavelength(GiWCalData *result,
335  GiExtraction *extraction,
336  GiLocalization *localization,
337  GiTable *fibers, GiTable *slitgeometry,
338  GiTable *grating, GiTable *lines,
339  GiTable *initial, GiWCalConfig *config);
340 
343 void giraffe_wlcalibration_config_add(cpl_parameterlist *);
344 
345 
346 #ifdef __cplusplus
347 }
348 #endif
349 
350 #endif /* GIWLCALIBRATION_H */
void giraffe_wlcalibration_config_add(cpl_parameterlist *)
Adds parameters for the wavelength calibration.
cxint giraffe_calibrate_wavelength(GiWCalData *result, GiExtraction *extraction, GiLocalization *localization, GiTable *fibers, GiTable *slitgeometry, GiTable *grating, GiTable *lines, GiTable *initial, GiWCalConfig *config)
Compute the wavelength solution for the given extracted arc-lamp spectra.
GiWCalConfig * giraffe_wlcalibration_config_create(cpl_parameterlist *)
Creates a setup structure for the wavelength calibration.
void giraffe_wlcalibration_config_destroy(GiWCalConfig *)
Destroys a wavelength calibration setup structure.
Wavelength calibration configuration data structure.
cxchar * line_model
GiRange * line_wlrange
cxdouble line_widthexponent
cxdouble slit_dy
cxdouble line_brightness
cxdouble pxw_clipmfrac
cxdouble slit_dx
cxdouble pxw_cliplevel
cxdouble line_rwidthratio
cxdouble line_offset
cxdouble line_fluxratio
cxdouble slit_phi
cxdouble line_dchisq
cxdouble line_saturation
cxdouble xws_cliplevel
cxint * line_widths
cxdouble line_threshold
cxdouble opt_dchisq
cxdouble xws_clipmfrac
cxchar * line_residuals
cxint16 slit_position
cxchar * opt_model
cxdouble line_separation

This file is part of the GIRAFFE Pipeline Reference Manual 2.16.10.
Documentation copyright © 2002-2006 European Southern Observatory.
Generated on Thu Dec 15 2022 21:18:52 by doxygen 1.9.1 written by Dimitri van Heesch, © 1997-2004