GIRAFFE Pipeline Reference Manual

Rebinning


Rebinning Results Container

GiRebinninggiraffe_rebinning_new (void)
 Create an empty rebinning results container.
GiRebinninggiraffe_rebinning_create (GiImage *spectra, GiImage *errors)
 Fills a rebinning results container.
void giraffe_rebinning_delete (GiRebinning *rebinning)
 Destroys a rebinning results container.
void giraffe_rebinning_destroy (GiRebinning *rebinning)
 Destroys a rebinning results container and its contents.

Rebinning Configuration Data

GiRebinConfiggiraffe_rebin_config_create (cpl_parameterlist *list)
 Creates a setup structure for the rebinning.
void giraffe_rebin_config_destroy (GiRebinConfig *config)
 Destroys a spectrum extraction setup structure.
void giraffe_rebin_config_add (cpl_parameterlist *list)
 Adds parameters for the rebinning.

Defines

#define GIFITS_KEYWORD_MISSING_MSG   "FITS KEYWORD [%s] not found!! Aborting..."
#define GIWAVECAL_GRATING_WAVELENGTH_EPSILON   0.0001

Typedefs

typedef enum GiLocDataType GiLocDataType
typedef GiGrat GiGrat
typedef GiFiberPosition GiFiberPosition
typedef GiLocPosition GiLocPosition
typedef GiBinnParams GiBinnParams
typedef GiSlitGeo GiSlitGeo
typedef GiWcalSolution GiWcalSolution
typedef GiRebinInfo GiRebinInfo

Enumerations

enum  GiLocDataType

Functions

GiRange * giraffe_rebin_get_wavelength_range (GiImage *spectra, GiTable *wlsolution, GiTable *grating, GiTable *slitgeometry, cxbool common)
 Compute the wavelenght range of spectra.
cxint giraffe_rebin_spectra (GiRebinning *rebinning, const GiExtraction *extraction, const GiTable *fibers, const GiLocalization *localization, const GiTable *grating, const GiTable *slitgeo, const GiTable *solution, const GiRebinConfig *config)
 Rebin an Extracted Spectra Frame and associated Errors Frame.

Variables

cx_string * GiGrat::filter_name
cx_string * GiGrat::setup_name
cx_string * GiGrat::slit_name
cxint GiGrat::order
cxdouble GiGrat::wlen0
cxdouble GiGrat::wlenmin
cxdouble GiGrat::wlenmax
cxdouble GiGrat::band
cxdouble GiGrat::resol
cxdouble GiGrat::space
cxdouble GiGrat::theta
cxdouble GiGrat::fcoll
cxdouble GiGrat::gcam
cxdouble GiGrat::slitdx
cxdouble GiGrat::slitdy
cxdouble GiGrat::slitphi
cpl_matrix * GiFiberPosition::y_fiber
cxint GiLocPosition::wdeg
GiLocDataType GiLocPosition::type
cpl_image * GiLocPosition::centroids
cpl_image * GiLocPosition::widths
cxint GiBinnParams::ydeg
cpl_matrix ** GiSlitGeo::subslits
lmrq_model_id GiWcalSolution::opt_mod
cpl_matrix * GiWcalSolution::opt_mod_params
GiSlitGeoGiWcalSolution::wav_coeffs
GiSlitGeoGiWcalSolution::wav_limits
const cxchar * GiRebinInfo::scale
const cxchar * GiRebinInfo::range
const cxchar * GiRebinInfo::units
cxdouble GiRebinInfo::wmin
cxdouble GiRebinInfo::wcenter
cxdouble GiRebinInfo::wmax
cxdouble GiRebinInfo::wstep
cxint GiRebinInfo::offset

Detailed Description

TBD

Function Documentation

void giraffe_rebin_config_add cpl_parameterlist *  list  ) 
 

Adds parameters for the rebinning.

Parameters:
list Parameter list to which parameters are added.
Returns:
Nothing.
Description :
TBD

Definition at line 4957 of file girebinning.c.

GiRebinConfig* giraffe_rebin_config_create cpl_parameterlist *  list  ) 
 

Creates a setup structure for the rebinning.

Parameters:
list Parameter list from which the setup informations is read.
Returns:
A newly allocated and initialized setup structure if no errors occurred, or NULL otherwise.
Description :
Creates a setup structure for the rebinning

Definition at line 4833 of file girebinning.c.

void giraffe_rebin_config_destroy GiRebinConfig config  ) 
 

Destroys a spectrum extraction setup structure.

Parameters:
config The setup structure to destroy.
Returns:
Nothing.
Description :
The function deallocates the memory used by the setup structure config and all components contained in it.

Definition at line 4933 of file girebinning.c.

GiRange* giraffe_rebin_get_wavelength_range GiImage *  spectra,
GiTable *  wlsolution,
GiTable *  grating,
GiTable *  slitgeometry,
cxbool  common
 

Compute the wavelenght range of spectra.

TBD

Definition at line 3908 of file girebinning.c.

References giraffe_range_create().

Referenced by giraffe_reconstruction_build().

cxint giraffe_rebin_spectra GiRebinning rebinning,
const GiExtraction extraction,
const GiTable *  fibers,
const GiLocalization localization,
const GiTable *  grating,
const GiTable *  slitgeo,
const GiTable *  solution,
const GiRebinConfig config
 

Rebin an Extracted Spectra Frame and associated Errors Frame.

Parameters:
rebinning Rebinned Extracted Spectrum and associated errors
extraction Extraction containing Extracted Spectrum and associated errors.
fibers Table of available fibers
localization Fiber spectra centroid positions and half-width.
grating Grating data table.
slitgeo Slit geometry table.
solution Wavelength calibration solution.
config Rebinning configuration data
Returns:
The function returns 0 on succes, and a value larger than 0 if an error occured.
TBD

Status Description :
1 - Input parameter empty (NULL value) 2 - Missing FITS keyword in input frame 3 - Unable to retrieve Grating Data 4 - No wavelength calibration solution present in input 5 - Invalid optical model in wavelength calibration solution 6 - Error in optical model in wavelength calibration solution 7 - Unable to retrieve Slit Geometry 8 - Error during rebinning 9 - Error converting wavelength calibration corrections.

Definition at line 4046 of file girebinning.c.

References GiExtraction::error, giraffe_image_get_properties(), giraffe_table_get(), giraffe_table_get_properties(), GiLocalization::locw, GiLocalization::locy, and GiExtraction::spectra.

Referenced by giraffe_calibrate_slit(), and giraffe_transmission_compute().

GiRebinning* giraffe_rebinning_create GiImage *  spectra,
GiImage *  errors
 

Fills a rebinning results container.

Parameters:
spectra - Extracted spectra.
errors - Errors of the extracted spectra.
Returns:
A newly allocated rebinning results container or NULL if an error occured
Description :
The function allocales memory for a rebinning results container, and initializes it's values using the parameters given. Only a reference is stored!

Definition at line 4723 of file girebinning.c.

References GiRebinning::errors, giraffe_rebinning_new(), and GiRebinning::spectra.

void giraffe_rebinning_delete GiRebinning rebinning  ) 
 

Destroys a rebinning results container.

Parameters:
rebinning - The rebinning results container to destroy.
Returns:
Nothing.
Description :
The function deallocates the memory used for the rebinning results container rebinning. Only the container itself is destroyed by calling this function. Since the container stores only references to the rebinning components its contents is left untouched and it is the responsibility of the caller to ensure that other references for the stored rebinning components exist.

Definition at line 4760 of file girebinning.c.

Referenced by giraffe_transmission_compute().

void giraffe_rebinning_destroy GiRebinning rebinning  ) 
 

Destroys a rebinning results container and its contents.

Parameters:
rebinning The rebinning results container to destroy.
Returns:
Nothing.
Description :
The function deallocates the memory used for the rebinning results container rebinning and each rebinning component it may contain.

Definition at line 4788 of file girebinning.c.

References GiRebinning::errors, giraffe_image_delete(), and GiRebinning::spectra.

Referenced by giraffe_calibrate_slit().

GiRebinning* giraffe_rebinning_new void   ) 
 

Create an empty rebinning results container.

Returns:
A newly allocated rebinning results container or NULL if an error occured
Description :
The function allocales memory for a rebinning results container, and initializes it's values to denote an empty container.

Definition at line 4694 of file girebinning.c.

References GiRebinning::errors, and GiRebinning::spectra.

Referenced by giraffe_calibrate_slit(), giraffe_rebinning_create(), and giraffe_transmission_compute().


Variable Documentation

cxdouble band [inherited]
 

grating band

Definition at line 86 of file girebinning.c.

cxdouble fcoll [inherited]
 

collimator focal length {mm}

Definition at line 90 of file girebinning.c.

cx_string* filter_name [inherited]
 

grating filter name e.g. HR13

Definition at line 79 of file girebinning.c.

cxdouble gcam [inherited]
 

camera magnification factor

Definition at line 91 of file girebinning.c.

lmrq_model_id opt_mod [inherited]
 

LMRQ Model used during wavecalibration

Definition at line 136 of file girebinning.c.

cxint order [inherited]
 

grating diffraction order

Definition at line 82 of file girebinning.c.

cxdouble resol [inherited]
 

grating resolution

Definition at line 87 of file girebinning.c.

cx_string* setup_name [inherited]
 

grating setup name

Definition at line 80 of file girebinning.c.

cx_string* slit_name [inherited]
 

grating slit name e.g. Medusa1

Definition at line 81 of file girebinning.c.

cxdouble slitdx [inherited]
 

slit position X offset {mm}

Definition at line 92 of file girebinning.c.

cxdouble slitdy [inherited]
 

slit position Y offset {mm}

Definition at line 93 of file girebinning.c.

cxdouble slitphi [inherited]
 

slit position angle {rad}

Definition at line 94 of file girebinning.c.

cxdouble space [inherited]
 

grating groove spacing {mm}

Definition at line 88 of file girebinning.c.

cxdouble theta [inherited]
 

grating angle {rad}

Definition at line 89 of file girebinning.c.

GiLocDataType type [inherited]
 

data format

Definition at line 111 of file girebinning.c.

cxint wdeg [inherited]
 

width 2D polynomial fit order

Definition at line 110 of file girebinning.c.

cxdouble wlen0 [inherited]
 

grating central wavelength {mm}

Definition at line 83 of file girebinning.c.

cxdouble wlenmax [inherited]
 

grating maximum wavelength {mm}

Definition at line 85 of file girebinning.c.

cxdouble wlenmin [inherited]
 

grating minimum wavelength {mm}

Definition at line 84 of file girebinning.c.

cpl_matrix* y_fiber [inherited]
 

Y Position of Fibers {mm}

Definition at line 102 of file girebinning.c.

cxint ydeg [inherited]
 

Binning step in Y direction {pixel}

Definition at line 121 of file girebinning.c.


This file is part of the GIRAFFE Pipeline Reference Manual 2.5.2.
Documentation copyright © 2002-2006 European Southern Observatory.
Generated on Fri Jun 13 14:36:26 2008 by doxygen 1.4.6 written by Dimitri van Heesch, © 1997-2004