00001 /* 00002 * This file is part of the ESO SINFONI Pipeline 00003 * Copyright (C) 2004,2005 European Southern Observatory 00004 * 00005 * This program is free software; you can redistribute it and/or modify 00006 * it under the terms of the GNU General Public License as published by 00007 * the Free Software Foundation; either version 2 of the License, or 00008 * (at your option) any later version. 00009 * 00010 * This program is distributed in the hope that it will be useful, 00011 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00012 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00013 * GNU General Public License for more details. 00014 * 00015 * You should have received a copy of the GNU General Public License 00016 * along with this program; if not, write to the Free Software 00017 * Foundation, 51 Franklin St, Fifth Floor, Boston, MA 02111-1307 USA 00018 */ 00019 00020 /*--------------------------------------------------------------------------- 00021 00022 File name : sinfo_standstar_cfg.h 00023 Author : Juergen Schreiber 00024 Created on : March 2002 00025 Description : standstar_ini definitions + handling prototypes 00026 00027 ---------------------------------------------------------------------------*/ 00028 00029 00030 #ifndef SINFO_STANDSTAR_CFG_H 00031 #define SINFO_STANDSTAR_CFG_H 00032 00033 /*--------------------------------------------------------------------------- 00034 Includes 00035 ---------------------------------------------------------------------------*/ 00036 00037 #include <stdlib.h> 00038 #include "sinfo_globals.h" 00039 #include <cpl.h> 00040 00041 00042 /*--------------------------------------------------------------------------- 00043 Defines 00044 ---------------------------------------------------------------------------*/ 00045 00046 00047 /*--------------------------------------------------------------------------- 00048 New types 00049 ---------------------------------------------------------------------------*/ 00050 00051 00052 /* 00053 standard star data reduction blackboard container 00054 00055 This structure holds all information related to the standard 00056 star data reduction 00057 routine. It is used as a container for the flux of ancillary data, 00058 computed values, and algorithm status. Pixel flux is separated from 00059 the blackboard. 00060 */ 00061 00062 typedef struct standstar_config { 00063 /*-------General---------*/ 00064 char inFile[FILE_NAME_SZ] ;/* input file of reduced jittered 00065 data cubes of a standard star */ 00066 char ** inFrameList ; /* input list of cubes */ 00067 int nframes ; /* number of input frames */ 00068 char outName[FILE_NAME_SZ] ; /* output name of resulting 00069 extracted spectrum stored 00070 as fits image */ 00071 00072 /*------ spectral extraction and determination of conversion factor ------*/ 00073 /* the fraction [0...1] of rejected low intensity pixels when 00074 taking the average of jittered spectra */ 00075 float lo_reject ; 00076 /* the fraction [0...1] of rejected high intensity pixels when 00077 taking the average of jittered spectra */ 00078 float hi_reject ; 00079 /* lower left sinfo_edge coordinates of fitting box for 00080 2d Gaussian fit */ 00081 int llx ; 00082 int lly ; 00083 /* size of a box inside which the 2D-Gaussian fit is carried through */ 00084 int halfbox_x ; 00085 int halfbox_y ; 00086 00087 /* factor applied to the found fwhms of a 2D-Gaussian 00088 fit, defines the radius of the aperture from which the 00089 spectral extraction is carried out (default: 0.7). */ 00090 float fwhm_factor ; 00091 /* (readnoise^2 + sinfo_dark current) needed to determine the 00092 noise variance of the background. Must be given in counts/sec. */ 00093 float backvariance ; 00094 /* estimated sky counts/sec */ 00095 float sky ; 00096 /* gain: counts per electron */ 00097 float gain ; 00098 /* indicator if an intensity conversion factor should be 00099 determined or not */ 00100 int convInd ; 00101 /* name of the ASCII file that stores the intensity conversion factor */ 00102 char convName[FILE_NAME_SZ] ; 00103 /* magnitude of the standard star */ 00104 float mag ; 00105 } standstar_config ; 00106 00107 00108 00109 /*--------------------------------------------------------------------------- 00110 Function prototypes 00111 ---------------------------------------------------------------------------*/ 00112 00113 00114 /*--------------------------------------------------------------------------- 00115 Function : sinfo_standstar_cfg_create() 00116 In : void 00117 Out : pointer to allocated base standstar_config structure 00118 Job : allocate memory for a standstar_config struct 00119 Notice : only the main (base) structure is allocated 00120 ---------------------------------------------------------------------------*/ 00121 00122 standstar_config * sinfo_standstar_cfg_create(void); 00123 00124 00125 /*--------------------------------------------------------------------------- 00126 Function : sinfo_standstar_cfg_destroy() 00127 In : standstar_config to deallocate 00128 Out : void 00129 Job : deallocate all memory associated with a 00130 standstar_config data structure 00131 Notice : 00132 ---------------------------------------------------------------------------*/ 00133 void sinfo_standstar_cfg_destroy(standstar_config * cc); 00134 00135 #endif