The purpose of this notebook is to illustrate how contaminants are included in QSO (tracer+Lyman-alpha) spectral simulations generated using desitarget/bin/select_mock_targets
.
The results below were generated with the tagged versions of the code in the 18.12
software release.
Additional information about simulating QSO targets (including contaminants) can be found on the SimulateQuasarTargets wiki page.
John Moustakas
Siena College
2018 December 19
In [1]:
import os
In [2]:
from desiutil.log import get_logger
log = get_logger()
In [3]:
import seaborn as sns
rc = {'font.family': 'serif'}#, 'text.usetex': True}
sns.set(style='ticks', font_scale=1.5, palette='Set2', rc=rc)
In [4]:
%matplotlib inline
Recall that we expect with the current target selection algorithms (which will be tested extensively during Survey Validation) to obtain spectra of, on average, 120 tracer QSOs/deg2
(i.e., QSOs at z<2.1), 50 Lya QSOs/deg2
(i.e., QSOs at z>2.1), and 90 contaminants/deg2
. Very roughly, approximately two-thirds of these contaminants will be stars and the remainder will be intermediate-redshift galaxies.
However, a more detailed analyis of the Galactic and extragalactic objects expected to contaminate QSO target selection is clearly needed.
DarkSky/v1.0.1
london/v4.2.0
z=1.8
(including RSD) to avoid double-counting.desisim.templates.SIMQSO
to generate (continuum) spectra at the input redshift.targets.fits
and truth.fits
files (and spectra) with all the relevant catalog and ancillary data.
In [5]:
from desitarget.mock.mockmaker import QSOMaker, LYAMaker
In [6]:
QSO = QSOMaker()
data_tracer = QSO.read(only_coords=True, zmax_qso=1.8)
In [7]:
qso_density = QSO.mock_density(QSO.default_mockfile)
In [8]:
log.info(QSO.default_mockfile)
log.info('Average density = {:.3f} QSO/deg2'.format(qso_density))
In [9]:
QSO.qamock_sky(data_tracer)
In [10]:
LYA = LYAMaker()
mockfile = os.path.join(os.getenv('DESI_ROOT'), 'mocks', 'lya_forest', 'london', 'v4.2.0', 'master.fits')
data_lya = LYA.read(mockfile=mockfile, only_coords=True, zmax_qso=1.8)
In [11]:
lya_density = LYA.mock_density(mockfile)
In [12]:
log.info(mockfile)
log.info('Average density = {:.3f} LYa QSO/deg2'.format(lya_density))
In [13]:
LYA.qamock_sky(data_lya)
Fulfilling this wish-list will require non-negligible dedicated effort, with input from the Lya and Target Selection Working Groups. Alternatively, Survey Validation should provide all the necessary observations.
Briefly, in the current version of select_mock_targets
we use the following inputs.
Buzzard/v1.6
mock (flux-limited to roughly r=24) for spatial coordinates and redshifts.desisim/BGS
templates (see, e.g., this notebook), as representative of the full range of spectral shapes spanned by galaxies. (But note: these templates were trained on spectra of galaxies only down to I<20.5
.)MWS/v0.0.6
and MWS-Superfaint/v0.0.6
mocks (flux-limited to r=23.5) to get spatial coordinates and radial velocities.desisim/STAR
templates (see this notebook).Some preliminary results can be viewed by navigating to targets-qa/QSO.html, which is based on spectral simulations (of all target classes, including contaminants) of 240k targets spanning 10 DESI tiles (roughly 40 deg2) generated as part of the 18.12 software release.
In [14]:
from IPython.display import Image, HTML, display
In [15]:
Image('histo-QSO.png')
Out[15]:
desimodel/data/targets/nz_QSO.dat
includes contaminants or not.nz_QSO.dat
?
In [16]:
display(HTML("<table><tr><td><img src='mock-nz-QSO.png'></td><td><img src='mock-zvmag-QSO.png'></td></tr></table>"))
select_mock_targets
for the QSO, ELG, LRG, and BGS target classes, and extragalactic contaminants are included for QSO and ELG targets.redrock
. In particular, have these contaminants had any effect on the derived catastrophic outlier rate?quickquasars
? Or should quickquasars
use the code infrastructure in select_mock_targets
?