00001
00002 /*---------------------------------------------------------------------------
00003
00004 File name : bad_cfg.h
00005 Author : Juergen Schreiber
00006 Created on : October 2001
00007 Description : bad_ini definitions + handling prototypes
00008
00009 ---------------------------------------------------------------------------*/
00010
00011
00012 #ifndef _BAD_CFG_H_
00013 #define _BAD_CFG_H_
00014
00015 /*---------------------------------------------------------------------------
00016 Includes
00017 ---------------------------------------------------------------------------*/
00018
00019 /* #include <stdio.h> */
00020 #include <stdlib.h>
00021 #include "static_sz.h"
00022
00023
00024 /*---------------------------------------------------------------------------
00025 Defines
00026 ---------------------------------------------------------------------------*/
00027
00028
00029 /*---------------------------------------------------------------------------
00030 New types
00031 ---------------------------------------------------------------------------*/
00032
00033
00034 /*
00035 bad pixels search blackboard container
00036
00037 This structure holds all information related to the bad pixels search
00038 routine. It is used as a container for the flux of ancillary data,
00039 computed values, and algorithm status. Pixel flux is separated from
00040 the blackboard.
00041 */
00042
00043 /*<python>*/
00044 typedef struct bad_config {
00045 /*-------General---------*/
00046 char inFile[FILENAMESZ] ; /* file name of the file containing the list of all input frames */
00047 char outName[FILENAMESZ] ; /* output name of resulting bad pixel mask (fits file)*/
00048 char ** framelist ; /* list of frames */
00049 int nframes ; /* number of frames in frame list */
00050
00051 /*------ BadPix ------*/
00052 /* factor of noise within which the pixels are used to fit a straight line to the column intensity */
00053 float sigmaFactor ;
00054 /* factor of calculated standard deviation beyond which the deviation of a pixel value from the
00055 median of the 8 nearest neighbors declares a pixel as bad */
00056 float factor ;
00057 /* number of iterations of median filter */
00058 int iterations ;
00059 /* percentage of extreme pixel value to reject when calculating the mean and stdev */
00060 float loReject ;
00061 float hiReject ;
00062 /* pixel coordinate of lower left edge of a rectangle zone from which image statistics are computed */
00063 int llx ;
00064 int lly ;
00065 /* pixel coordinate of upper right edge of a rectangle zone from which image statistics are computed */
00066 int urx ;
00067 int ury ;
00068 /*------ Thresh ------*/
00069 /* indicates if the values beyond threshold values should be marked as bad before proceeding
00070 to median filtering */
00071 int threshInd ;
00072 /* factor to the clean standard deviation to define the threshold deviation from the clean mean */
00073 float meanfactor ;
00074 /* minimum vlaue of good data */
00075 float mincut ;
00076 /* maximum vlaue of good data */
00077 float maxcut ;
00078 /* indicates which method will be used */
00079 int methodInd ;
00080 } bad_config ;
00081 /*</python>*/
00082
00083
00084 /*---------------------------------------------------------------------------
00085 Function prototypes
00086 ---------------------------------------------------------------------------*/
00087
00088
00089 /*---------------------------------------------------------------------------
00090 Function : bad_cfg_create()
00091 In : void
00092 Out : pointer to allocated base bad_cfg structure
00093 Job : allocate memory for a bad_cfg struct
00094 Notice : only the main (base) structure is allocated
00095 ---------------------------------------------------------------------------*/
00096
00097 bad_config * bad_cfg_create(void);
00098
00099
00100 /*---------------------------------------------------------------------------
00101 Function : bad_cfg_destroy()
00102 In : bad_config to deallocate
00103 Out : void
00104 Job : deallocate all memory associated with a bad_config data structure
00105 Notice :
00106 ---------------------------------------------------------------------------*/
00107 /*<python>*/
00108 void bad_cfg_destroy(bad_config * sc);
00109 /*</python>*/
00110
00111 #endif
1.2.13.1 written by Dimitri van Heesch,
© 1997-2001