16.3.11 QSOC
Author(s): Ludovic Delchambre
16.3.11.1 Goal
The Quasar Classifier (QSOC) module aims to determine the redshift, , and absolute Gaia -band magnitude of the sources
-
•
identified as quasar candidates in the qso_candidates table
-
•
found around one of the CU4-EO input quasar, to search for gravitational lenses in the grav_lens_redshift table (see Section 13.2).
QSOC predictions are filtered according to the selection rules described in Section 16.3.11.6.
16.3.11.2 Training data and models
To predict the source redshifts, QSOC relies on a rest-frame quasar template built on 750 414 observed quasar spectra from the sixteenth release of the Sloan Digital Sky Survey (SDSS) Quasar Catalogue of Lyke et al. (2020). For each redshift probed by QSOC, this rest-frame quasar template is first converted into internally-calibrated BP/RP spectra, using procedures described in Montegriffo et al. (2023), and then compared to the observed internally-calibrated BP and RP spectra to infer the redshift of the source (see Section 16.3.11.4 for more details).
For each input SDSS spectrum, we reject fluxes outside the – nm range and those found within nm of one of the , , , , , , nm night sky emission lines. The spectra are then corrected for galactic extinction using the Fitzpatrick (1999) extinction curve and the Schlegel et al. (1998) extinction map, taking into account the correction of the reddening suggested by Schlafly et al. (2010). The final quasar template is computed over the rest-frame wavelength range from nm to nm with a logarithmic sampling of using the method described in (Gaia Collaboration et al. 2023b, Appendix C). To allow the widest possible range of redshifts to be predicted, the borders of the composite quasar spectrum are extrapolated using a linear fit of the Lyman break for wavelength shorter than nm and using a constant fit to the region – nm for wavelength longer than nm. Finally, a continuum slope is fitted over the rest-frame wavelength range – nm using the method described in Gaia Collaboration et al. (2023b) and is used to compute the described in Section 16.3.11.4. Figure 16.19 presents the resulting composite quasar spectrum along with the extrapolation used by QSOC and the associated continuum slope.
16.3.11.3 Inputs
The determination of the redshift by QSOC is based on
-
•
partially-calibrated epoch spectra that are pre-processed, background mitigated, and geometrically calibrated but have no differential flux and line spread function (LSF) calibration.
-
•
band magnitude, phot_g_mean_mag
-
•
TGE median , a0_median
Note that all partially-calibrated epoch spectra of a same source differ from one another because of the source variability, but also because of the different response function and LSF associated to their observing conditions. These observing conditions are summarized in the so-called calibration units and are composed of: the field of view; the on-board mission time (OBMT); the CCD row; the across-scan (AC) coordinate; the gates activation; the windows class (1D or 2D); the AC rate and on the along-scan and AC centring errors. Before being used, partially-calibrated epoch spectra must hence be normalized to a default calibration unit and combined to produce internally-calibrated spectra. Internally-calibrated BP/RP spectra are computed based on the partially-calibrated BP/RP spectra associated with each source using the following procedure: for a given set of partially-calibrated epoch spectra (BP or RP), , for which the inverse uncertainties are given by the diagonal weight matrix , we compute the coefficients of the internally-calibrated spectra, , through the minimization of
| (16.61) |
where and are the calibration matrix and relative flux associated with the -th epoch spectrum, respectively, and is the matrix of basis functions sampled at pseudo-wavelengths imposed by . The calibration matrix, , is associated to the calibration unit of the -th partially-calibrated epoch spectrum. It is a discrete convolution matrix that models the flux and LSF calibration to apply to the set of the basis functions, , in order to reproduce the observed -th partially-calibrated spectrum (Montegriffo et al. 2023). If is sampled at pseudo-wavelength , the calibration matrix converts an oversampled version of the basis functions, , to its partially-calibrated representation, sampled at . The linear constraint , both ensures that the mean of the relative fluxes is equal to one and that the solution is bounded (any solution of the form is otherwise also a solution to Equation 16.61 for arbitrary values of ). The set of basis functions are cardinal B-spline functions of degree three with uniformly spaced knots at such that the matrices are composed of basis functions. The minimization algorithm simultaneously produces the covariance matrix on , , and the uncertainties associated with each relative flux, .
16.3.11.4 Method
In order to find the most probable redshifts of a source, redshift_qsoc, from its observed magnitude and BP/RP internally-calibrated spectral coefficients, and (see Equation 16.61), QSOC evaluates the log-posterior probability
| (16.62) |
where and are the integrated BP and RP flux derived from the internally-calibrated spectral coefficients, and ; and are ad-hoc weights associated to the BP/RP colour and -band magnitude log-likelihoods, and , respectively; and is a normalization constant such that .
The first term in Equation 16.62 is the log-likelihood associated to the probability of observing the coefficients and if we assume that the observed source is at redshift . It is given as a linear combination of two independent chi-squares, each associated with the BP and RP coefficients as
| (16.63) |
where is a normalization constant such that and
| (16.64) |
are minimal with respect to . In this last equation, is a two-column matrix containing the SDSS quasar template as observed at redshift (see Section 16.3.11.2) and a constant that are both converted into internally-calibrated spectral coefficients.
The colour log-likelihood from Equation 16.62 is given by
| (16.65) |
where is a normalization constant such that and
| (16.66) |
is minimal with respect to and where and respectively taken as the theoretical BP and RP fluxes of a quasar at redshift , computed from the SDSS quasar template (Section 16.3.11.2) considering a reddening of a0_median and the extinction curve given by Fitzpatrick (1999). Empirical tests done using a random subset of 2871 sources with a uniform redshift coverage also show that is an optimal value of the colour weight in Equation 16.62.
Finally, the magnitude log-likelihood from Equation 16.62 is computed from the pure luminosity-function evolution and luminosity evolution and density evolution (PLE+LEDE) quasar luminosity function of Palanque-Delabrouille et al. (2016) as
| (16.67) |
where is a normalization constant such that ; is the PLE+LEDE quasar luminosity function from Palanque-Delabrouille et al. (2016); is the quasar absolute magnitude in the SDSS -band, normalized to , and is the co-moving volume element at redshift . The absolute SDSS -band magnitude can be inferred from the Gaia -band magnitude, using
| (16.68) |
where is the distance modulus at redshift , normalized at , and calculated from a flat -CDM cosmology with km s Mpc and (Planck Collaboration et al. 2016b). The -correction term, , encompasses the galactic extinction (TGE a0_median extinction); the conversion from the observed Gaia magnitude to SDSS magnitude, including the synthetic zero point difference, and the effect of the redshift on the observed spectral range, which is normalized to in the SDSS -band. Empirical tests done using a random subset of 2871 sources with a uniform redshift coverage also shows that is an optimal value of the magnitude weight in Equation 16.62. We concurrently produce an absolute Gaia -band magnitude, gmag_qsoc, by replacing the SDSS -band -correction from Equation 16.68 with an appropriate -correction taking into account the galactic extinction and normalization of the observed spectral range to in the Gaia -band while using a flat -CDM cosmology with km s Mpc and (Planck Collaboration et al. 2020).
The determination of the redshift of quasars by QSOC is based on the fact that the redshift,
| (16.69) |
turns into a simple offset once considered on a logarithmic wavelength scale
| (16.70) |
where we assume that a given spectral feature standing at rest-frame wavelength is observed at wavelength . QSOC then searches for the logarithmic redshift, , having the highest log-posterior probability and compute its associated uncertainty from the asymptotic normality property of the maximum likelihood estimator as
| (16.71) |
The redshift that is reported by QSOC, , is thus distributed as a log-normal distribution of mean and variance such that its lower and upper confidence intervals, redshift_qsoc_lower and redshift_qsoc_upper respectively, taken as its 0.15866 and 0.84134 quantiles, are given by
| (16.72) |
Assuming that our formulation of the log-posterior probability correctly describes the probability of having a quasar at redshift given the observed , and quantities, we concurrently compute the probability that the selected redshift effectively stands within its confidence interval through
| (16.73) |
We should however stress here that our formulation of the log-posterior probability from Equation 16.62 is known to be overly simplistic as, for example, we assume that the observed spectra can be represented using a single composite spectrum plus a constant and that the quasar BP/RP colours and absolute magnitudes only depend on redshift. Nevertheless, remains an efficient indicator of the quality of the redshift that can easily be interpreted. It is further shown to be proportional to the true probability that the redshift stands within its confidence interval (see Section 16.4.12.2).
Amongst other quality indicators, QSOC provides the , zscore_qsoc, that is an indicator of the presence of quasar emission lines. A close to one indicates that all the emission lines that we expect at redshift are found in the spectra while the miss of a single emission line often leads to a very low . The is computed from the internally-calibrated spectral coefficients of the quasar emission lines,
| (16.74) |
where is similar to (Equation 16.64) except that the SDSS quasar template is replaced by the power law continuum slope from Section 16.3.11.2, leaving pure emission line coefficients in . The flux associated to an emission line at rest-frame wavelength , and associated uncertainty, , can then be derived from Equation 16.74 in order to provide
| (16.75) |
Equation 16.75 can be viewed as a geometric mean of a set of normal cumulative distribution functions of mean zero and standard deviations evaluated at . Practically, the is computed over the observed wavelength range – nm in BP and – nm in RP using the Ly 121.567 nm, Si iv 139.676 nm, C iv 154.906 nm, C iii] 190.873 nm, Mg ii 279.875 nm, H 434.168 nm, H 486.268 nm and H 656.461 nm rest-frame emission lines.
A complementary quality estimator is the ccfratio_qsoc which is taken as the value of the coefficients log-likelihood (Equation 16.63) normalized to stand in the range . Low values of this parameter indicate that the redshift selection was mostly driven by the colour and absolute magnitude likelihoods (Equation 16.65 and Equation 16.67) instead of the likelihood based on the comparison of the observed BP/RP spectra against the QSO template. It is defined as
| (16.76) |
QSOC also reports the redshift with the second highest posterior probability, which is stored in redshiftalt_qsoc field, along with its associated lower and upper confidence intervals, and , and probability to stands within its confidence intervals, . It is however required that the absolute difference between the most probable and second most probable redshifts is in order to avoid reporting small oscillations that are commonly found around the global maximum of the log-posterior probability. Finally, the and ccf_ratio quality indicators, when combined with information from the internal-calibration procedure ( Section 16.3.11.3), allow us to define useful binary flags for filtering potentially erroneous redshifts that are reported in the flags_qsoc field.
16.3.11.5 Outputs
The QSOC contribution to the qso_candidates and grav_lens_redshift tables are
-
•
redshift_qsoc, the most probable redshift from Equation 16.62 along with its lower and upper confidence intervals, respectively taken as its 0.15866 and 0.84134 quantiles, redshift_qsoc_lower and redshift_qsoc_upper; probability to stand within its confidence interval, redshift_qsoc_prob, and associated value of the log-posterior probability, redshift_qsoc_logprob.
-
•
gmag_qsoc, the absolute magnitude of the quasar in the Gaia -band, assuming that the quasar is at redshift redshift_qsoc, along with its lower and upper confidence intervals, gmag_qsoc_lower and gmag_qsoc_upper, respectively
-
•
redshiftalt_qsoc, the second most probable redshift from Equation 16.62 along with its lower and upper confidence intervals, respectively taken as its 0.15866 and 0.84134 quantiles, redshiftalt_qsoc_lower and redshiftalt_qsoc_upper; probability to stand within its confidence interval, redshiftalt_qsoc_prob, and associated value of the log-posterior probability, redshiftalt_qsoc_logprob.
-
•
ccfratio_qsoc, the normalized value of the coefficients log-likelihood from Equation 16.76, assuming that the quasar is at redshift redshift_qsoc
-
•
zscore_qsoc, the value of the from Equation 16.76, assuming that the quasar is at redshift redshift_qsoc
-
•
flags_qsoc, the QSOC processing flags which is based on the ccfratio_qsoc, zscore_qsoc and on information from the internal-calibration procedure ( Section 16.3.11.3).
16.3.11.6 Scope
QSOC internally produces astrophysical parameters for all sources
-
1.
classified as quasars by the DSC module, namely those having classprob_dsc_combmod_quasar (see Section 16.3.2 for more details).
-
2.
found within of one of the CU4-EO input quasar to search for gravitational lenses (Section 13.2 and grav_lens_input_list table).
-
3.
contained in its validation dataset and used to assess the software performance during the development phase. The latter is composed of sources found within of one of the Milliquas 7.8c quasar (Flesch 2021) and sources contained in a preliminary version of the GraL catalogue of gravitationally lensed quasars of Ducourant et al. (2026b).
All sources from points 1–3 that are also contained in the qso_candidates table have their QSOC astrophysical parameters published in Gaia DR4. Additionally, sources having zscore_qsoc and redshift_qsoc_logprob are elected as quasar candidates and concurrently have their astrophysical parameters published in the qso_candidates table. All sources from point 2 have their astrophysical parameters published in the grav_lens_redshift, without filtering.
16.3.11.7 Uses and limitations
Based on a cross-match of the QSOC predictions from the qso_candidates and grav_lens_redshift tables against the Milliquas 8 quasar catalogue of Flesch (2023) (558 400 sources), we have that
-
•
of the sources have an absolute error on the redshift that is .
-
•
of the sources with mag have , which represents of the total number of sources. At mag, of the sources have ( of the total number of sources).
-
•
of the sources with flags_qsoc have ( of the total number of sources).
-
•
of the sources with redshift_qsoc_logprob have ( of the total number of sources).
-
•
of the sources that are elected as eligible by QSOC in the qso_candidates table (with bit 7 set in the source_selection_flags) have ( of the total number of sources).
The main sources of contaminant predictions are: emission line mismatches; constant QSOC predictions occurring at and , where only one emission line is covered by BP and RP spectral range and a background of false predictions at that are associated to faint sources (at mag).
Additional details on the QSOC uses and limitations can be found in Section 16.4.12.2.
16.3.11.8 Changes with respect to DR3
The core of the QSOC module was entirely rewritten since Gaia DR3 such that the zscore_qsoc, flags_qsoc and ccfratio_qsoc fields that were already present in the previous release change their signification. The meaning of the redshift_qsoc, redshift_qsoc_lower and redshift_qsoc_upper fields however remains unchanged.
Gaia DR4 also saw the introduction of ten new fields that are the log-posterior probability, redshift_qsoc_logprob, from Equation 16.62; the probability that the effective redshift stands within the predicted confidence interval, redshift_qsoc_prob, from Equation 16.73; the absolute quasar Gaia -band magnitude, gmag_qsoc, from Equation 16.68, along with its lower and upper confidence intervals, gmag_qsoc_lower and gmag_qsoc_upper; the second most-probable redshift, redshiftalt_qsoc, along with its associated confidence intervals, redshiftalt_qsoc_lower and redshiftalt_qsoc_upper; probability to stand within its confidence interval, redshiftalt_qsoc_prob, and value of the log-posterior probability, redshiftalt_qsoc_logprob.