grizli.pipeline.photoz.apply_catalog_corrections(root, total_flux='flux_auto', auto_corr=True, get_external_photometry=False, aperture_indices='all', suffix='_apcorr', verbose=True, apply_background=True, ee_correction=False)[source]

Aperture and background corrections to photometric catalog

First correct fluxes in individual filters scaled by the ratio of total_flux / aper_flux in the detection band, where total_flux is flux_auto by default.

>>> apcorr = {total_flux} / flux_aper_{ap}
>>> {filt}_corr_{ap} = {filt}_flux_aper_{ap} * apcorr

If ee_correction = True, then apply an encircled energy correction for the relative fraction for the relative flux between the target filter and detection image for a point source flux within a photometric aperture. The correction function is get_filter_ee_ratio.

>>> ee_{filt} = prep.get_filter_ee_ratio({filt}, 
>>> {filt}_corr_{ap} = {filt}_corr_{ap} / ee_{filt}

If auto_corr, compute total fluxes with a correction for flux outside the Kron aperture derived for point sources using get_kron_tot_corr.

>>> {filt}_tot_{ap} = {filt}_corr_{ap} * {filt}_tot_corr

Note that any background has already been subtracted from {filt}_flux_aper_{ap}.in the SEP catalog.