30 #include "muse_scipost_make_cube_z.h" 51 cpl_frame *frame = cpl_frameset_get_position(inframes, 0);
52 char *fn = cpl_strdup(cpl_frame_get_filename(frame));
57 cpl_frameset_delete(inframes);
59 cpl_msg_error(__func__,
"NULL pixel table for %s", fn);
65 cpl_propertylist_erase_regexp(pixtable->
header,
"ESO QC ", 0);
85 cpl_propertylist_delete(outwcs);
93 cpl_msg_debug(__func__,
"additional output as column-stacked image");
101 return rc == CPL_ERROR_NONE ? 0 : -1;
muse_pixtable_wcs
State of the astrometric calibration of a MUSE pixel table.
muse_image * muse_resampling_image(muse_pixtable *aPixtable, muse_resampling_type aMethod, double aDX, double aDLambda)
Resample a pixel table onto a two-dimensional regular grid.
cpl_propertylist * muse_postproc_cube_load_output_wcs(muse_processing *aProcessing)
Find a file with a usable output WCS in the input frameset.
void muse_image_delete(muse_image *aImage)
Deallocate memory associated to a muse_image object.
double muse_pfits_get_ra(const cpl_propertylist *aHeaders)
find out the right ascension
cpl_error_code muse_resampling_params_set_wcs(muse_resampling_params *aParams, const cpl_propertylist *aWCS)
Set an output WCS (and wavelength scale) in the resampling parameters.
const char * filter
The filter name(s) to be used for the output field-of-view image. Each name has to correspond to an E...
const char * resample_s
The resampling technique to use for the final output cube. (as string)
muse_resampling_crstats_type muse_postproc_get_cr_type(const char *aCRTypeString)
Select correct cosmic ray rejection type for crtype string.
Structure definition of MUSE three extension FITS file.
double crsigma
Sigma rejection factor to use for cosmic ray rejection during final resampling. A zero or negative va...
cpl_error_code muse_postproc_cube_resample_and_collapse(muse_processing *aProcessing, muse_pixtable *aPixtable, muse_cube_type aFormat, muse_resampling_params *aParams, const char *aFilter)
High level function to resample to a datacube and collapse that to an image of the field of view and ...
int ld
Number of adjacent pixels to take into account during resampling in all three directions (loop distan...
muse_resampling_crstats_type crtype
Structure definition of MUSE pixel table.
muse_cube_type muse_postproc_get_cube_format(const char *aFormatString)
Select correct cube format for format string.
muse_pixtable_wcs muse_pixtable_wcs_check(muse_pixtable *aPixtable)
Check the state of the world coordinate system of a pixel table.
double lambdamax
Cut off the data above this wavelength after loading the pixel table(s).
int stacked
If true, write an additional output file in form of a 2D stacked image (x direction is pseudo-spatial...
muse_resampling_params * muse_resampling_params_new(muse_resampling_type aMethod)
Create the resampling parameters structure.
double muse_pfits_get_dec(const cpl_propertylist *aHeaders)
find out the declination
void muse_processing_append_used(muse_processing *aProcessing, cpl_frame *aFrame, cpl_frame_group aGroup, int aDuplicate)
Add a frame to the set of used frames.
double dx
Horizontal step size for resampling (in arcsec or pixel). The following defaults are taken when this ...
double rc
Critical radius for the "renka" resampling method.
muse_pixtable * muse_pixtable_load_restricted_wavelength(const char *aFilename, double aLambdaMin, double aLambdaMax)
Load a pixel table from file and cut down the wavelength range.
cpl_error_code muse_resampling_params_set_pixfrac(muse_resampling_params *aParams, const char *aString)
Set resampling pixfrac given a string that can contain up to three floating-point values...
int muse_processing_save_image(muse_processing *aProcessing, int aIFU, muse_image *aImage, const char *aTag)
Save a computed MUSE image to disk.
muse_resampling_type muse_postproc_get_resampling_type(const char *aResampleString)
Select correct resampling type for resample string.
Structure to hold the parameters of the muse_scipost_make_cube recipe.
const char * crtype_s
Type of statistics used for detection of cosmic rays during final resampling. "iraf" uses the varianc...
double lambdamin
Cut off the data below this wavelength after loading the pixel table(s).
double dy
Vertical step size for resampling (in arcsec or pixel). The following defaults are taken when this va...
muse_resampling_type
Resampling types.
const char * pixfrac
Pixel down-scaling factor for the "drizzle" resampling method. Up to three, comma-separated, floating-point values can be given. If only one value is given, it applies to all dimensions, two values are interpreted as spatial and spectral direction, respectively, while three are taken as horizontal, vertical, and spectral.
void muse_resampling_params_delete(muse_resampling_params *aParams)
Delete a resampling parameters structure.
cpl_error_code muse_wcs_position_celestial(muse_pixtable *aPixtable, double aRA, double aDEC)
Convert native to celestial spherical coordinates in a pixel table.
double dlambda
Wavelength step size (in Angstrom). Natural instrument sampling is used, if this is 0...
void muse_pixtable_delete(muse_pixtable *aPixtable)
Deallocate memory associated to a pixel table object.
cpl_propertylist * header
The FITS header.
cpl_frameset * muse_frameset_find_tags(const cpl_frameset *aFrames, const cpl_array *aTags, unsigned char aIFU, cpl_boolean aInvert)
return frameset containing data from an IFU/channel with the given tag(s)
const char * format_s
Type of output file format, "Cube" is a standard FITS cube with NAXIS=3 and multiple extensions (for ...