cadence#

Module Contents#

Classes#

LSSTCadence

Attributes#

cadence_obj

class cadence.LSSTCadence(out_dir)[source]#
min_mjd = 59580.139555[source]#
nside_in = 32[source]#
nested = False[source]#
fov_radius = 1.75[source]#
bp_to_int[source]#
int_to_bp[source]#
bp[source]#
get_pointings_single_hp(hp: int, n_pointings_init: int)[source]#

Get pointing positions from a single healpix, upgrading it if necessary

hpint

a single healpix id in DC2 (NSIDE=32, nested)

n_pointings_initint

how many pointings to get from this healpix

tuple

ra, dec of pointings

get_pointings(n_pointings_init: int)[source]#

Get pointing positions all over the DC2 field

n_pointings_initint

how many pointings to get

tuple

ra, dec of pointings

get_obs_info(ra: numpy.ndarray, dec: numpy.ndarray, skip_existing=True, min_visits=0, skip_ddf=True)[source]#

Loop through pointings and query visits that fall inside FOV (run at generation time)

After DDF rejection, we might end up with a final n_pointings different from n_pointings_init

bin_by_day(bandpasses=list('ugrizy'), skip_existing=True)[source]#

Bin the observations by day, trimming days that weren’t observed in any filter and in any pointing (run at generation time)

bandpasseslist

Bandpasses to base binning on

skip_existingbool, optional

whether to skip operations for pointings already saved to disk

get_observed_mask()[source]#

Get trimmed MJD that is observed in at least one band at all times

get_trimmed_mjd()[source]#

Get trimmed MJD that is observed in at least one band at all times

get_trimmed_mask(i: int, as_tensor=False)[source]#

Get trimmed mask that has times corresponding to trimmed_mjd

get_mjd_single_pointing(i: int, rounded: bool)[source]#
get_mjd_i_band_pointing(i: int, rounded: bool)[source]#
get_mask_single_pointing(i: int)[source]#
load_opsim_db()[source]#

Load the OpSim database with relevant columns as an iterator

cadence.cadence_obj[source]#