MUSE Pipeline Reference Manual  1.0.2
muse_postproc.h
1 /* -*- Mode: C; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /* vim:set sw=2 sts=2 et cin: */
3 /*
4  * This file is part of the MUSE Instrument Pipeline
5  * Copyright (C) 2005-2014 European Southern Observatory
6  *
7  * This program is free software; you can redistribute it and/or modify
8  * it under the terms of the GNU General Public License as published by
9  * the Free Software Foundation; either version 2 of the License, or
10  * (at your option) any later version.
11  *
12  * This program is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15  * GNU General Public License for more details.
16  *
17  * You should have received a copy of the GNU General Public License
18  * along with this program; if not, write to the Free Software
19  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
20  */
21 
22 #ifndef MUSE_POSTPROC_H
23 #define MUSE_POSTPROC_H
24 
25 /*----------------------------------------------------------------------------*
26  * Includes *
27  *----------------------------------------------------------------------------*/
28 #include <cpl.h>
29 
30 #include "muse_flux.h"
31 #include "muse_lsf.h"
32 #include "muse_pixtable.h"
33 #include "muse_processing.h"
34 #include "muse_resampling.h"
35 #include "muse_rvcorrect.h"
36 #include "muse_sky.h"
37 #include "muse_wcs.h"
38 #include "muse_xcombine.h"
39 
40 /*----------------------------------------------------------------------------*
41  * Defines *
42  *----------------------------------------------------------------------------*/
43 
44 /*----------------------------------------------------------------------------*
45  * Data structures *
46  *----------------------------------------------------------------------------*/
47 
51 /*----------------------------------------------------------------------------*/
55 /*----------------------------------------------------------------------------*/
56 typedef enum {
57  MUSE_POSTPROC_SCIPOST = 0,
58  MUSE_POSTPROC_STANDARD,
59  MUSE_POSTPROC_ASTROMETRY
61 
62 /*----------------------------------------------------------------------------*/
66 /*----------------------------------------------------------------------------*/
67 typedef enum {
68  MUSE_POSTPROC_SKYMETHOD_NONE = 0,
69  MUSE_POSTPROC_SKYMETHOD_MODEL,
70  MUSE_POSTPROC_SKYMETHOD_ROWBYROW
72 
73 /*----------------------------------------------------------------------------*/
77 /*----------------------------------------------------------------------------*/
78 typedef enum {
79  MUSE_POSTPROC_DARCHECK_NONE = 0,
80  MUSE_POSTPROC_DARCHECK_CHECK,
81  MUSE_POSTPROC_DARCHECK_CORRECT
83 
84 /*----------------------------------------------------------------------------*/
88 /*----------------------------------------------------------------------------*/
89 typedef struct {
91  cpl_table *exposures;
92  double lambdamin;
93  double lambdamax;
94  double lambdaref;
96  muse_rvcorrect_type rvtype;
97  cpl_table *response;
98  cpl_table *extinction;
99  cpl_table *telluric;
100  cpl_propertylist *wcs;
105  cpl_frame *refframe;
107  cpl_table *tellregions;
111  double detsigma;
112  double radius;
114  double faccuracy;
116  double rejsigma;
117  int niter;
120  double crpix1, crpix2;
122 
123 /*----------------------------------------------------------------------------*/
127 /*----------------------------------------------------------------------------*/
128 typedef struct {
130  cpl_table *spectrum;
131  cpl_table *lines;
132  cpl_table *continuum;
134 
137 /*----------------------------------------------------------------------------*
138  * Function prototypes *
139  *----------------------------------------------------------------------------*/
142 
143 cpl_boolean muse_postproc_check_save_param(const char *, const char *);
148 
150 
154 
155 #endif /* MUSE_POSTPROC_H */
Structure definition of a MUSE datacube.
Definition: muse_datacube.h:47
muse_rvcorrect_type rvtype
Definition: muse_postproc.h:96
cpl_propertylist * muse_postproc_cube_load_output_wcs(muse_processing *)
Find a file with a usable output WCS in the input frameset.
muse_postproc_properties * muse_postproc_properties_new(muse_postproc_type)
Create a post-processing properties object.
Definition: muse_postproc.c:67
muse_flux_selection_type select
muse_postproc_skymethod
Method of sky subtraction to apply.
Definition: muse_postproc.h:67
muse_flux_smooth_type
Type of response curve smoothing to use.
Definition: muse_flux.h:131
muse_wcs_centroid_type centroid
muse_xcombine_types muse_postproc_get_weight_type(const char *)
Select correct weighting type for weight string.
Structure to hold the MASTER SKY result.
Definition: muse_sky.h:57
muse_flux_profile_type
Type of optimal profile to use.
Definition: muse_flux.h:109
muse_resampling_crstats_type muse_postproc_get_cr_type(const char *)
Select correct cosmic ray rejection type for crtype string.
cpl_error_code muse_postproc_qc_fwhm(muse_processing *, muse_datacube *)
Compute QC1 parameters for datacubes and save them in the FITS header.
void * muse_postproc_process_exposure(muse_postproc_properties *, unsigned int, muse_postproc_sky_outputs *)
Merge and process pixel tables from one exposure.
cpl_error_code muse_postproc_cube_resample_and_collapse(muse_processing *, muse_pixtable *, muse_cube_type, muse_resampling_params *, const char *)
High level function to resample to a datacube and collapse that to an image of the field of view and ...
muse_flux_profile_type profile
muse_postproc_skymethod skymethod
muse_wcs_centroid_type
Type of centroiding algorithm to use.
Definition: muse_wcs.h:78
Structure definition of MUSE pixel table.
muse_cube_type muse_postproc_get_cube_format(const char *)
Select correct cube format for format string.
cpl_boolean muse_postproc_check_save_param(const char *, const char *)
Check the –save parameter contents against allowed options.
muse_resampling_crstats_type
Cosmic ray rejection statistics type.
muse_flux_smooth_type smooth
muse_cube_type
cpl_propertylist * wcs
Structure definition of the post-processing properties.
Definition: muse_postproc.h:89
Structure to define the major settable sky parameters.
Definition: muse_sky.h:73
void muse_postproc_properties_delete(muse_postproc_properties *)
Free memory taken by a post-processing properties object and all its components.
Definition: muse_postproc.c:94
muse_postproc_darcheck
Method of DAR checking/correction to do.
Definition: muse_postproc.h:78
muse_postproc_type
Type of per-exposure processing to run.
Definition: muse_postproc.h:56
muse_resampling_type muse_postproc_get_resampling_type(const char *)
Select correct resampling type for resample string.
Handling of "mask" files.
Definition: muse_mask.h:42
muse_sky_master * sky
muse_postproc_type type
Definition: muse_postproc.h:90
muse_resampling_type
Resampling types.
Resampling parameters.
Structure definition of the post-processing output sky data.
muse_sky_params skymodel_params
muse_postproc_darcheck darcheck
Definition: muse_postproc.h:95
muse_xcombine_types
Xposure combination types.
Definition: muse_xcombine.h:44
muse_flux_selection_type
Type of star selection to use.
Definition: muse_flux.h:121