mangadap.survey.manga_dap module¶
Provides the main wrapper function for the MaNGA DAP.
Copyright © 2019, SDSS-IV/MaNGA Pipeline Group
-
mangadap.survey.manga_dap.
get_manga_dap_meta
(cube)[source]¶ Get the metadata required to run the DAP.
The metadata is pulled from the provided DataCube and checked. The only required metadata keyword is
z
, which sets the initial guess for the bulk redshift of the galaxy. If this key is not available or its value doesn’t meet the criterion below, this function will raise an exception, meaning the DAP will fault before it starts processing the DataCube.The metadata provided by the DataCube must meet the following critical criteria or the method will fault:
Velocity (\(cz\)) has to be greater than -500.
For the remainder of the metadata, if the keyword does not exist, if the value is None, or if the value is outside the accepted range, a default is chosen. The metadata keywords, acceptable ranges, and defaults are provided below.
Keyword
Range
Default
vdisp
\(\sigma > 0\)
100
ell
\(0 \leq \varepsilon < 1\)
None
pa
\(0 \leq \phi_0 < 360\)
None
reff
\(R_{\rm eff} > 0\)
None
- Returns
Returns a dictionary with the following keywords:
z
: The bulk redshift of the galaxy, used to calculate \(cz\).vel
: The initial guess velocity (\(cz\)) in km/s.vdisp
: The initial guess velocity dispersion in km/s.ell
: The isophotal ellipticity (\(1-b/a\)) to use when calculating semi-major axis coordinates.pa
: The isophotal position angle in deg from N through E, used when calculating semi-major axis coordinates.reff
: The effective radius in arcsec (DataCube WCS coordinates are expected to be in deg), used as a normalization of the semi-major axis radius in various output data.
- Return type
dict
- Raises
ValueError – See critical criteria above.
-
mangadap.survey.manga_dap.
manga_dap
(cube, plan, dbg=False, log=None, verbose=0, drpver=None, redux_path=None, directory_path=None, dapver=None, analysis_path=None)[source]¶ Main wrapper function for the MaNGA DAP.
This function is designed to be called once per datacube. The
mangadap.par.analysisplan.AnalysisPlanSet
instance sets the types of analyses to perform on this observation. Each analysis plan results in a MAPS and model LOGCUBE file.The procedure is as follows. For each plan in
plan
:Determine basic assessments of the data, including the S/N and spaxel coordinates. See
mangadap.proc.reductionassessments.ReductionAssessment
.Bin the spectra. See
mangadap.proc.spatiallybinnedspectra.SpatiallyBinnedSpectra
.Fit the stellar continuum for stellar kinematics. See
mangadap.proc.stellarcontinuummodel.StellarContinuumModel
.Measure the emission-line moments. See
mangadap.proc.emissionlinemoments.EmissionLineMoments
.Fit parameterized line profiles to the emission lines. See
mangadap.proc.emissionlinemodel.EmissionLineModel
.Subtract the fitted emission-line models and measure the spectral indices. See
mangadap.proc.spectralindices.SpectralIndices
.Construct the primary output files based on the plan results. See
mangadap.dapfits.construct_maps_file()
andmangadap.dapfits.construct_cube_file()
.
- Verbose levels (still under development):
Nothing but errors.
Basic status updates. E.g., start and end of each block, minor progress within blocks.
Block-level and sub-function updates.
Same as above, with figures.
- Parameters
cube (
mangadap.datacube.datacube.DataCube
) – Datacube to analyze.plan (
mangadap.par.analysisplan.AnalysisPlanSet
) – Object with the analysis plans to implement.dbg (
bool
, optional) – Flag to run the DAP in debug mode, see above; default is False. Limited use; still under development.log (
str
, optional) – File name for log output, see above; no log file is produced by default.verbose (
int
, optional) – Verbosity level, see above; default is 0.drpver (
str
, optional) – DRP version. Default determined bymangadap.config.defaults.drp_version()
.redux_path (
str
, optional) – Top-level directory with the DRP products; default is defined bymangadap.config.defaults.drp_redux_path()
.directory_path (
str
, optional) – Direct path to directory containing the DRP output file; default is defined bymangadap.config.defaults.drp_directory_path()
dapver (
str
, optional) – DAP version. Default determined bymangadap.config.defaults.dap_version()
.analysis_path (
str
, optional) – Top-level directory for the DAP output data; default is defined bymangadap.config.defaults.dap_analysis_path()
.
- Returns
Status flag (under development; currently always 0).
- Return type
int