MUSE Pipeline Reference Manual  2.1.1
muse_create_sky_z.c
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-2015 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 /* This file was automatically generated */
23 
24 #ifdef HAVE_CONFIG_H
25 #include <config.h>
26 #endif
27 
28 /*----------------------------------------------------------------------------*
29  * Includes *
30  *----------------------------------------------------------------------------*/
31 #include <string.h> /* strcmp(), strstr() */
32 #include <strings.h> /* strcasecmp() */
33 #include <cpl.h>
34 
35 #include "muse_create_sky_z.h" /* in turn includes muse.h */
36 
37 /*----------------------------------------------------------------------------*/
47 /*----------------------------------------------------------------------------*/
50 /*----------------------------------------------------------------------------*
51  * Static variables *
52  *----------------------------------------------------------------------------*/
53 static const char *muse_create_sky_help =
54  "This recipe creates the continuum and the atmospheric transition line spectra of the night sky from the data in a pixel table(s) belonging to one exposure of (mostly) empty sky.";
55 
56 static const char *muse_create_sky_help_esorex =
57  "\n\nInput frames for raw frame tag \"PIXTABLE_SKY\":\n"
58  "\n Frame tag Type Req #Fr Description"
59  "\n -------------------- ---- --- --- ------------"
60  "\n PIXTABLE_SKY raw Y Input pixel table. If the pixel table is not already flux calibrated, the corresponding flux calibration frames should be given as well."
61  "\n EXTINCT_TABLE calib Y 1 Atmospheric extinction table"
62  "\n STD_RESPONSE calib Y 1 Response curve as derived from standard star(s)"
63  "\n STD_TELLURIC calib . 1 Telluric absorption as derived from standard star(s)"
64  "\n SKY_LINES calib Y 1 List of OH transitions and other sky lines"
65  "\n SKY_CONTINUUM calib . 1 Sky continuum to use"
66  "\n LSF_PROFILE calib Y 1 Slice specific LSF parameters cubes"
67  "\n SKY_MASK calib . 1 Sky mask to use"
68  "\n\nProduct frames for raw frame tag \"PIXTABLE_SKY\":\n"
69  "\n Frame tag Level Description"
70  "\n -------------------- -------- ------------"
71  "\n SKY_MASK intermed Created sky mask"
72  "\n IMAGE_FOV intermed Whitelight image used to create the sky mask"
73  "\n SKY_SPECTRUM intermed Sky spectrum within the sky mask"
74  "\n SKY_LINES final Estimated sky line flux table"
75  "\n SKY_CONTINUUM final Estimated continuum flux spectrum";
76 
77 /*----------------------------------------------------------------------------*/
85 /*----------------------------------------------------------------------------*/
86 static cpl_recipeconfig *
87 muse_create_sky_new_recipeconfig(void)
88 {
89  cpl_recipeconfig *recipeconfig = cpl_recipeconfig_new();
90 
91  cpl_recipeconfig_set_tag(recipeconfig, "PIXTABLE_SKY", 1, -1);
92  cpl_recipeconfig_set_input(recipeconfig, "PIXTABLE_SKY", "EXTINCT_TABLE", 1, 1);
93  cpl_recipeconfig_set_input(recipeconfig, "PIXTABLE_SKY", "STD_RESPONSE", 1, 1);
94  cpl_recipeconfig_set_input(recipeconfig, "PIXTABLE_SKY", "STD_TELLURIC", -1, 1);
95  cpl_recipeconfig_set_input(recipeconfig, "PIXTABLE_SKY", "SKY_LINES", 1, 1);
96  cpl_recipeconfig_set_input(recipeconfig, "PIXTABLE_SKY", "SKY_CONTINUUM", 0, 1);
97  cpl_recipeconfig_set_input(recipeconfig, "PIXTABLE_SKY", "LSF_PROFILE", 1, 1);
98  cpl_recipeconfig_set_input(recipeconfig, "PIXTABLE_SKY", "SKY_MASK", 0, 1);
99  cpl_recipeconfig_set_output(recipeconfig, "PIXTABLE_SKY", "SKY_MASK");
100  cpl_recipeconfig_set_output(recipeconfig, "PIXTABLE_SKY", "IMAGE_FOV");
101  cpl_recipeconfig_set_output(recipeconfig, "PIXTABLE_SKY", "SKY_SPECTRUM");
102  cpl_recipeconfig_set_output(recipeconfig, "PIXTABLE_SKY", "SKY_LINES");
103  cpl_recipeconfig_set_output(recipeconfig, "PIXTABLE_SKY", "SKY_CONTINUUM");
104 
105  return recipeconfig;
106 } /* muse_create_sky_new_recipeconfig() */
107 
108 /*----------------------------------------------------------------------------*/
118 /*----------------------------------------------------------------------------*/
119 static cpl_error_code
120 muse_create_sky_prepare_header(const char *aFrametag, cpl_propertylist *aHeader)
121 {
122  cpl_ensure_code(aFrametag, CPL_ERROR_NULL_INPUT);
123  cpl_ensure_code(aHeader, CPL_ERROR_NULL_INPUT);
124  if (!strcmp(aFrametag, "SKY_MASK")) {
125  muse_processing_prepare_property(aHeader, "ESO QC SKY THRESHOLD",
126  CPL_TYPE_DOUBLE,
127  "Threshold in the white light considered as sky, used to create this mask");
128  } else if (!strcmp(aFrametag, "IMAGE_FOV")) {
129  } else if (!strcmp(aFrametag, "SKY_SPECTRUM")) {
130  } else if (!strcmp(aFrametag, "SKY_LINES")) {
131  muse_processing_prepare_property(aHeader, "ESO QC SKY LINE[0-9]+ NAME",
132  CPL_TYPE_STRING,
133  "Name of the strongest line in group k");
134  muse_processing_prepare_property(aHeader, "ESO QC SKY LINE[0-9]+ AWAV",
135  CPL_TYPE_DOUBLE,
136  "[Angstrom] Wavelength (air) of the strongest line of group l");
137  muse_processing_prepare_property(aHeader, "ESO QC SKY LINE[0-9]+ FLUX",
138  CPL_TYPE_DOUBLE,
139  "[erg/(s cm2 arcsec2)] Flux of the strongest line of group l");
140  } else if (!strcmp(aFrametag, "SKY_CONTINUUM")) {
141  muse_processing_prepare_property(aHeader, "ESO QC SKY CONT FLUX",
142  CPL_TYPE_DOUBLE,
143  "[erg/(s cm2 arcsec2)] Total flux of the continuum");
144  muse_processing_prepare_property(aHeader, "ESO QC SKY CONT MAXDEV",
145  CPL_TYPE_DOUBLE,
146  "[erg/(s cm2 arcsec2 Angstrom)] Maximum (absolute value) of the derivative of the continuum spectrum");
147  } else {
148  cpl_msg_warning(__func__, "Frame tag %s is not defined", aFrametag);
149  return CPL_ERROR_ILLEGAL_INPUT;
150  }
151  return CPL_ERROR_NONE;
152 } /* muse_create_sky_prepare_header() */
153 
154 /*----------------------------------------------------------------------------*/
163 /*----------------------------------------------------------------------------*/
164 static cpl_frame_level
165 muse_create_sky_get_frame_level(const char *aFrametag)
166 {
167  if (!aFrametag) {
168  return CPL_FRAME_LEVEL_NONE;
169  }
170  if (!strcmp(aFrametag, "SKY_MASK")) {
171  return CPL_FRAME_LEVEL_INTERMEDIATE;
172  }
173  if (!strcmp(aFrametag, "IMAGE_FOV")) {
174  return CPL_FRAME_LEVEL_INTERMEDIATE;
175  }
176  if (!strcmp(aFrametag, "SKY_SPECTRUM")) {
177  return CPL_FRAME_LEVEL_INTERMEDIATE;
178  }
179  if (!strcmp(aFrametag, "SKY_LINES")) {
180  return CPL_FRAME_LEVEL_FINAL;
181  }
182  if (!strcmp(aFrametag, "SKY_CONTINUUM")) {
183  return CPL_FRAME_LEVEL_FINAL;
184  }
185  return CPL_FRAME_LEVEL_NONE;
186 } /* muse_create_sky_get_frame_level() */
187 
188 /*----------------------------------------------------------------------------*/
197 /*----------------------------------------------------------------------------*/
198 static muse_frame_mode
199 muse_create_sky_get_frame_mode(const char *aFrametag)
200 {
201  if (!aFrametag) {
202  return MUSE_FRAME_MODE_ALL;
203  }
204  if (!strcmp(aFrametag, "SKY_MASK")) {
205  return MUSE_FRAME_MODE_MASTER;
206  }
207  if (!strcmp(aFrametag, "IMAGE_FOV")) {
208  return MUSE_FRAME_MODE_MASTER;
209  }
210  if (!strcmp(aFrametag, "SKY_SPECTRUM")) {
211  return MUSE_FRAME_MODE_MASTER;
212  }
213  if (!strcmp(aFrametag, "SKY_LINES")) {
214  return MUSE_FRAME_MODE_MASTER;
215  }
216  if (!strcmp(aFrametag, "SKY_CONTINUUM")) {
217  return MUSE_FRAME_MODE_MASTER;
218  }
219  return MUSE_FRAME_MODE_ALL;
220 } /* muse_create_sky_get_frame_mode() */
221 
222 /*----------------------------------------------------------------------------*/
232 /*----------------------------------------------------------------------------*/
233 static int
234 muse_create_sky_create(cpl_plugin *aPlugin)
235 {
236  /* Check that the plugin is part of a valid recipe */
237  cpl_recipe *recipe;
238  if (cpl_plugin_get_type(aPlugin) == CPL_PLUGIN_TYPE_RECIPE) {
239  recipe = (cpl_recipe *)aPlugin;
240  } else {
241  return -1;
242  }
243 
244  /* register the extended processing information (new FITS header creation, *
245  * getting of the frame level for a certain tag) */
247  muse_create_sky_new_recipeconfig(),
248  muse_create_sky_prepare_header,
249  muse_create_sky_get_frame_level,
250  muse_create_sky_get_frame_mode);
251 
252  /* XXX initialize timing in messages *
253  * since at least esorex is too stupid to turn it on, we have to do it */
255  cpl_msg_set_time_on();
256  }
257 
258  /* Create the parameter list in the cpl_recipe object */
259  recipe->parameters = cpl_parameterlist_new();
260  /* Fill the parameters list */
261  cpl_parameter *p;
262 
263  /* --fraction: Fraction of the image (without the ignored part) to be considered as sky. If an input sky mask is provided, the fraction is applied to the regions within the mask. If the whole sky mask should be used, set this parameter to 1. */
264  p = cpl_parameter_new_value("muse.muse_create_sky.fraction",
265  CPL_TYPE_DOUBLE,
266  "Fraction of the image (without the ignored part) to be considered as sky. If an input sky mask is provided, the fraction is applied to the regions within the mask. If the whole sky mask should be used, set this parameter to 1.",
267  "muse.muse_create_sky",
268  (double)0.75);
269  cpl_parameter_set_alias(p, CPL_PARAMETER_MODE_CFG, "fraction");
270  cpl_parameter_set_alias(p, CPL_PARAMETER_MODE_CLI, "fraction");
271 
272  cpl_parameterlist_append(recipe->parameters, p);
273 
274  /* --ignore: Fraction of the image to be ignored. If an input sky mask is provided, the fraction is applied to the regions within the mask. If the whole sky mask should be used, set this parameter to 0. */
275  p = cpl_parameter_new_value("muse.muse_create_sky.ignore",
276  CPL_TYPE_DOUBLE,
277  "Fraction of the image to be ignored. If an input sky mask is provided, the fraction is applied to the regions within the mask. If the whole sky mask should be used, set this parameter to 0.",
278  "muse.muse_create_sky",
279  (double)0.05);
280  cpl_parameter_set_alias(p, CPL_PARAMETER_MODE_CFG, "ignore");
281  cpl_parameter_set_alias(p, CPL_PARAMETER_MODE_CLI, "ignore");
282 
283  cpl_parameterlist_append(recipe->parameters, p);
284 
285  /* --sampling: Spectral sampling of the sky spectrum [Angstrom]. */
286  p = cpl_parameter_new_value("muse.muse_create_sky.sampling",
287  CPL_TYPE_DOUBLE,
288  "Spectral sampling of the sky spectrum [Angstrom].",
289  "muse.muse_create_sky",
290  (double)0.3125);
291  cpl_parameter_set_alias(p, CPL_PARAMETER_MODE_CFG, "sampling");
292  cpl_parameter_set_alias(p, CPL_PARAMETER_MODE_CLI, "sampling");
293  if (!getenv("MUSE_EXPERT_USER")) {
294  cpl_parameter_disable(p, CPL_PARAMETER_MODE_CLI);
295  }
296 
297  cpl_parameterlist_append(recipe->parameters, p);
298 
299  /* --csampling: Spectral sampling of the continuum spectrum [Angstrom]. */
300  p = cpl_parameter_new_value("muse.muse_create_sky.csampling",
301  CPL_TYPE_DOUBLE,
302  "Spectral sampling of the continuum spectrum [Angstrom].",
303  "muse.muse_create_sky",
304  (double)0.3125);
305  cpl_parameter_set_alias(p, CPL_PARAMETER_MODE_CFG, "csampling");
306  cpl_parameter_set_alias(p, CPL_PARAMETER_MODE_CLI, "csampling");
307  if (!getenv("MUSE_EXPERT_USER")) {
308  cpl_parameter_disable(p, CPL_PARAMETER_MODE_CLI);
309  }
310 
311  cpl_parameterlist_append(recipe->parameters, p);
312 
313  /* --crsigma: Sigma level clipping for cube-based and spectrum-based CR rejection. This has to be a string of two comma-separated floating-point numbers. The first value gives the sigma-level rejection for cube-based CR rejection (using "median", see muse_scipost), the second value the sigma-level for spectrum-based CR cleaning. Both can be switched off, by passing zero or a negative value; by default, the spectrum-based rejection is switched off. */
314  p = cpl_parameter_new_value("muse.muse_create_sky.crsigma",
315  CPL_TYPE_STRING,
316  "Sigma level clipping for cube-based and spectrum-based CR rejection. This has to be a string of two comma-separated floating-point numbers. The first value gives the sigma-level rejection for cube-based CR rejection (using \"median\", see muse_scipost), the second value the sigma-level for spectrum-based CR cleaning. Both can be switched off, by passing zero or a negative value; by default, the spectrum-based rejection is switched off.",
317  "muse.muse_create_sky",
318  (const char *)"15.,15.");
319  cpl_parameter_set_alias(p, CPL_PARAMETER_MODE_CFG, "crsigma");
320  cpl_parameter_set_alias(p, CPL_PARAMETER_MODE_CLI, "crsigma");
321  if (!getenv("MUSE_EXPERT_USER")) {
322  cpl_parameter_disable(p, CPL_PARAMETER_MODE_CLI);
323  }
324 
325  cpl_parameterlist_append(recipe->parameters, p);
326 
327  /* --lambdamin: Cut off the data below this wavelength after loading the pixel table(s). */
328  p = cpl_parameter_new_value("muse.muse_create_sky.lambdamin",
329  CPL_TYPE_DOUBLE,
330  "Cut off the data below this wavelength after loading the pixel table(s).",
331  "muse.muse_create_sky",
332  (double)4000.);
333  cpl_parameter_set_alias(p, CPL_PARAMETER_MODE_CFG, "lambdamin");
334  cpl_parameter_set_alias(p, CPL_PARAMETER_MODE_CLI, "lambdamin");
335 
336  cpl_parameterlist_append(recipe->parameters, p);
337 
338  /* --lambdamax: Cut off the data above this wavelength after loading the pixel table(s). */
339  p = cpl_parameter_new_value("muse.muse_create_sky.lambdamax",
340  CPL_TYPE_DOUBLE,
341  "Cut off the data above this wavelength after loading the pixel table(s).",
342  "muse.muse_create_sky",
343  (double)10000.);
344  cpl_parameter_set_alias(p, CPL_PARAMETER_MODE_CFG, "lambdamax");
345  cpl_parameter_set_alias(p, CPL_PARAMETER_MODE_CLI, "lambdamax");
346 
347  cpl_parameterlist_append(recipe->parameters, p);
348 
349  /* --lambdaref: Reference wavelength used for correction of differential atmospheric refraction. The R-band (peak wavelength ~7000 Angstrom) that is usually used for guiding, is close to the central wavelength of MUSE, so a value of 7000.0 Angstrom should be used if nothing else is known. A value less than zero switches DAR correction off. */
350  p = cpl_parameter_new_value("muse.muse_create_sky.lambdaref",
351  CPL_TYPE_DOUBLE,
352  "Reference wavelength used for correction of differential atmospheric refraction. The R-band (peak wavelength ~7000 Angstrom) that is usually used for guiding, is close to the central wavelength of MUSE, so a value of 7000.0 Angstrom should be used if nothing else is known. A value less than zero switches DAR correction off.",
353  "muse.muse_create_sky",
354  (double)7000.);
355  cpl_parameter_set_alias(p, CPL_PARAMETER_MODE_CFG, "lambdaref");
356  cpl_parameter_set_alias(p, CPL_PARAMETER_MODE_CLI, "lambdaref");
357 
358  cpl_parameterlist_append(recipe->parameters, p);
359 
360  return 0;
361 } /* muse_create_sky_create() */
362 
363 /*----------------------------------------------------------------------------*/
374 /*----------------------------------------------------------------------------*/
375 static int
376 muse_create_sky_params_fill(muse_create_sky_params_t *aParams, cpl_parameterlist *aParameters)
377 {
378  cpl_ensure_code(aParams, CPL_ERROR_NULL_INPUT);
379  cpl_ensure_code(aParameters, CPL_ERROR_NULL_INPUT);
380  cpl_parameter *p;
381 
382  p = cpl_parameterlist_find(aParameters, "muse.muse_create_sky.fraction");
383  cpl_ensure_code(p, CPL_ERROR_DATA_NOT_FOUND);
384  aParams->fraction = cpl_parameter_get_double(p);
385 
386  p = cpl_parameterlist_find(aParameters, "muse.muse_create_sky.ignore");
387  cpl_ensure_code(p, CPL_ERROR_DATA_NOT_FOUND);
388  aParams->ignore = cpl_parameter_get_double(p);
389 
390  p = cpl_parameterlist_find(aParameters, "muse.muse_create_sky.sampling");
391  cpl_ensure_code(p, CPL_ERROR_DATA_NOT_FOUND);
392  aParams->sampling = cpl_parameter_get_double(p);
393 
394  p = cpl_parameterlist_find(aParameters, "muse.muse_create_sky.csampling");
395  cpl_ensure_code(p, CPL_ERROR_DATA_NOT_FOUND);
396  aParams->csampling = cpl_parameter_get_double(p);
397 
398  p = cpl_parameterlist_find(aParameters, "muse.muse_create_sky.crsigma");
399  cpl_ensure_code(p, CPL_ERROR_DATA_NOT_FOUND);
400  aParams->crsigma = cpl_parameter_get_string(p);
401 
402  p = cpl_parameterlist_find(aParameters, "muse.muse_create_sky.lambdamin");
403  cpl_ensure_code(p, CPL_ERROR_DATA_NOT_FOUND);
404  aParams->lambdamin = cpl_parameter_get_double(p);
405 
406  p = cpl_parameterlist_find(aParameters, "muse.muse_create_sky.lambdamax");
407  cpl_ensure_code(p, CPL_ERROR_DATA_NOT_FOUND);
408  aParams->lambdamax = cpl_parameter_get_double(p);
409 
410  p = cpl_parameterlist_find(aParameters, "muse.muse_create_sky.lambdaref");
411  cpl_ensure_code(p, CPL_ERROR_DATA_NOT_FOUND);
412  aParams->lambdaref = cpl_parameter_get_double(p);
413 
414  return 0;
415 } /* muse_create_sky_params_fill() */
416 
417 /*----------------------------------------------------------------------------*/
424 /*----------------------------------------------------------------------------*/
425 static int
426 muse_create_sky_exec(cpl_plugin *aPlugin)
427 {
428  if (cpl_plugin_get_type(aPlugin) != CPL_PLUGIN_TYPE_RECIPE) {
429  return -1;
430  }
432  cpl_recipe *recipe = (cpl_recipe *)aPlugin;
433  cpl_msg_set_threadid_on();
434 
435  cpl_frameset *usedframes = cpl_frameset_new(),
436  *outframes = cpl_frameset_new();
438  muse_create_sky_params_fill(&params, recipe->parameters);
439 
440  cpl_errorstate prestate = cpl_errorstate_get();
441 
442  muse_processing *proc = muse_processing_new("muse_create_sky",
443  recipe);
444  int rc = muse_create_sky_compute(proc, &params);
445  cpl_frameset_join(usedframes, proc->usedframes);
446  cpl_frameset_join(outframes, proc->outframes);
448 
449  if (!cpl_errorstate_is_equal(prestate)) {
450  /* dump all errors from this recipe in chronological order */
451  cpl_errorstate_dump(prestate, CPL_FALSE, muse_cplerrorstate_dump_some);
452  /* reset message level to not get the same errors displayed again by esorex */
453  cpl_msg_set_level(CPL_MSG_INFO);
454  }
455  /* clean up duplicates in framesets of used and output frames */
458 
459  /* to get esorex to see our classification (frame groups etc.), *
460  * replace the original frameset with the list of used frames *
461  * before appending product output frames */
462  /* keep the same pointer, so just erase all frames, not delete the frameset */
463  muse_cplframeset_erase_all(recipe->frames);
464  cpl_frameset_join(recipe->frames, usedframes);
465  cpl_frameset_join(recipe->frames, outframes);
466  cpl_frameset_delete(usedframes);
467  cpl_frameset_delete(outframes);
468  return rc;
469 } /* muse_create_sky_exec() */
470 
471 /*----------------------------------------------------------------------------*/
478 /*----------------------------------------------------------------------------*/
479 static int
480 muse_create_sky_destroy(cpl_plugin *aPlugin)
481 {
482  /* Get the recipe from the plugin */
483  cpl_recipe *recipe;
484  if (cpl_plugin_get_type(aPlugin) == CPL_PLUGIN_TYPE_RECIPE) {
485  recipe = (cpl_recipe *)aPlugin;
486  } else {
487  return -1;
488  }
489 
490  /* Clean up */
491  cpl_parameterlist_delete(recipe->parameters);
493  return 0;
494 } /* muse_create_sky_destroy() */
495 
496 /*----------------------------------------------------------------------------*/
506 /*----------------------------------------------------------------------------*/
507 int
508 cpl_plugin_get_info(cpl_pluginlist *aList)
509 {
510  cpl_recipe *recipe = cpl_calloc(1, sizeof *recipe);
511  cpl_plugin *plugin = &recipe->interface;
512 
513  char *helptext;
515  helptext = cpl_sprintf("%s%s", muse_create_sky_help,
516  muse_create_sky_help_esorex);
517  } else {
518  helptext = cpl_sprintf("%s", muse_create_sky_help);
519  }
520 
521  /* Initialize the CPL plugin stuff for this module */
522  cpl_plugin_init(plugin, CPL_PLUGIN_API, MUSE_BINARY_VERSION,
523  CPL_PLUGIN_TYPE_RECIPE,
524  "muse_create_sky",
525  "Create night sky model from selected pixels of an exposure of empty sky.",
526  helptext,
527  "Ole Streicher",
528  "usd-help@eso.org",
530  muse_create_sky_create,
531  muse_create_sky_exec,
532  muse_create_sky_destroy);
533  cpl_pluginlist_append(aList, plugin);
534  cpl_free(helptext);
535 
536  return 0;
537 } /* cpl_plugin_get_info() */
538 
void muse_processing_delete(muse_processing *aProcessing)
Free the muse_processing structure.
muse_cplframework_type muse_cplframework(void)
Return the CPL framework the recipe is run under.
double csampling
Spectral sampling of the continuum spectrum [Angstrom].
const char * crsigma
Sigma level clipping for cube-based and spectrum-based CR rejection. This has to be a string of two c...
cpl_frameset * usedframes
muse_processing * muse_processing_new(const char *aName, cpl_recipe *aRecipe)
Create a new processing structure.
const char * muse_get_license(void)
Get the pipeline copyright and license.
Definition: muse_utils.c:83
double ignore
Fraction of the image to be ignored. If an input sky mask is provided, the fraction is applied to the...
muse_frame_mode
cpl_frameset * outframes
void muse_cplerrorstate_dump_some(unsigned aCurrent, unsigned aFirst, unsigned aLast)
Dump some CPL errors.
void muse_processinginfo_delete(cpl_recipe *)
Clear all information from the processing info and from the recipe config.
cpl_error_code muse_cplframeset_erase_duplicate(cpl_frameset *aFrames)
Erase all duplicate frames from a frameset.
cpl_error_code muse_cplframeset_erase_all(cpl_frameset *aFrames)
Erase all frames in a frameset.
double lambdamin
Cut off the data below this wavelength after loading the pixel table(s).
double sampling
Spectral sampling of the sky spectrum [Angstrom].
void muse_processinginfo_register(cpl_recipe *, cpl_recipeconfig *, muse_processing_prepare_header_func *, muse_processing_get_frame_level_func *, muse_processing_get_frame_mode_func *)
Register extended functionalities for MUSE recipes.
double fraction
Fraction of the image (without the ignored part) to be considered as sky. If an input sky mask is pro...
double lambdamax
Cut off the data above this wavelength after loading the pixel table(s).
double lambdaref
Reference wavelength used for correction of differential atmospheric refraction. The R-band (peak wav...
void muse_processing_recipeinfo(cpl_plugin *)
Output main pipeline configuration, inputs, and parameters.
Structure to hold the parameters of the muse_create_sky recipe.
cpl_error_code muse_processing_prepare_property(cpl_propertylist *, const char *, cpl_type, const char *)
Prepare and check the specified property.