xlens.analysis.cluster

Cluster lensing shear profile measurement and multiplicative bias estimation.

Provides HaloMcBiasMultibandPipe, a pipeline task that matches detected sources to truth catalogs around NFW halos, measures tangential shear profiles, and estimates multiplicative bias from the ratio of measured-to-true reduced shear.

Classes

HaloMcBiasMultibandPipeConnections

Butler connections for HaloMcBiasMultibandPipe.

HaloMcBiasMultibandPipeConfig

Configuration for HaloMcBiasMultibandPipe.

HaloMcBiasMultibandPipe

Measure tangential shear profiles around NFW halos and estimate

Module Contents

class HaloMcBiasMultibandPipeConnections(*, config=None)[source]

Bases: lsst.pipe.base.PipelineTaskConnections

Butler connections for HaloMcBiasMultibandPipe.

skymap[source]
src00List[source]
src01List[source]
truth00List[source]
truth01List[source]
outputSummary[source]
summaryPlot[source]
class HaloMcBiasMultibandPipeConfig[source]

Bases: lsst.pipe.base.PipelineTaskConfig

Configuration for HaloMcBiasMultibandPipe.

ename[source]
xname[source]
yname[source]
wname[source]
mass[source]
conc[source]
z_lens[source]
z_source[source]
validate()[source]
class HaloMcBiasMultibandPipe(*, config: HaloMcBiasMultibandPipeConfig | None = None, log: lsst.utils.logging.LsstLogAdapter | None = None, initInputs: dict[str, Any] | None = None, **kwargs: Any)[source]

Bases: lsst.pipe.base.PipelineTask

Measure tangential shear profiles around NFW halos and estimate multiplicative shear bias.

Matches detected source catalogs to truth catalogs, computes tangential and cross shear in radial bins, and compares measured shear to the true input shear to derive the multiplicative bias.

_DefaultName = 'HaloMcTask'[source]
ConfigClass[source]
ename[source]
egname[source]
xname[source]
yname[source]
wname[source]
wgname[source]
runQuantum(butlerQC, inputRefs, outputRefs)[source]
static _rotate_spin_2_vec(e1, e2, angle)[source]

Rotate a spin-2 field by an array of angles (one per e1, e2 pair)

static _rotate_spin_2_matrix(R11, R22, angle)[source]
static _get_response_from_w_and_der(e1, e2, w, e1_g1, e2_g2, w_g1, w_g2)[source]
static _get_eT_eX_rT_rX_sum(eT, eX, w, rT, rX, gT_true_matched, gX_true_matched, gT_true, gX_true, kappa_true, dist, lensed_shift, radial_lensed_shift, radial_bin_edges, match_dist, m00, m20, all_true_gT, all_true_gX, all_true_dist)[source]

calculate the sum of eT, eX, and rT in each radial bin for a single halo

Parameters:
  • eT (array) – tangential shape

  • eX (array) – cross shape

  • w (weight) – ancal weight

  • rT (array) – tangential response,

  • rX (array) – cross response,

  • gT_true_matched (array) – true tangential shear of matched objects

  • gX_true_matched (array) – true cross shear of matched objects

  • gT_true (array) – true tangential shear calculated with distance

  • gX_true (array) – true cross shear calculated with distance

  • kappa_true (array) – true convergence

  • dist (array) – angular distance from the halo center

  • lensed_shift (array) – distance between the lensed and prelensed position

  • radial_lensed_shift (array) – distance between the lensed and prelensed position in radial direction

  • radial_bin_edges (array) – radial bin edges in pixel

  • match_dist (array) – the distance between detection and matched input

  • m00 (array) – fpfs shapelet mode m00

  • m20 (array) – fpfs shapelet mode m20

  • all_true_gT (array) – true tangential shear of all input objects

  • all_true_gX (array) – true cross shear of matched objects

  • all_true_dist (array) – angular distance from the halo center for all input objects

Returns:

sum of eT in each radial bin eX(array): sum of eX in each radial bin rT(array): sum of tangential resposne in each radial bin rX(array): sum of radial response in each radial bin gT_true_matched(array):

sum of true tangential shear of matches in each radial bin

gX_true_matched(array):

sum of true cross shear of matches in each radial bin

gT_true (array):

sum of true tan shear in each radial bin

gX_true (array):

sum of true cross shear in each radial bin

all_true_gT(array):

mean of true tan shear of all input objects in each radial bin

all_true_gX(array):

mean of true cross shear of all input objects in each radial bin

kappa_true(array): sum of true convergence in each radial bin lensed_shift(array): mean of lensed shift in each radial bin radial_lensed_shift(array):

mean of lensed shift in each radial bin, projected on the radial direction

r_weighted_gT_matched(array):

sum of tangential shear weighted by rT in each radial bin

r_weighted_gX_matched(array):

sum of cross shear weighted by rX in each radial bin

r_weighted_gT(array):

sum of tangential shear weighted by rT in each radial bin

r_weighted_gX(array):

sum of cross shear weighted by rX in each radial bin

ngal_in_bin(array): number of galaxies in each radial bin eT_std_list(array):

per galaxy standard deviation of eT in each radial bin

eX_std_list(array):

per galaxy standard deviation of eX in each radial bin

mean_dist(array): mean distance of galaxies of the halo center median_match_dist_list(array):

median of the match distance in each radial bin, expected to be around 0.5

match_failure_rate_list(array):

fraction of match distance larger than 2 in each radial bin

m00_list(array): mean of shapelet mode m00 in each radial bin m20_list(array): mean of shapelet mode m20 in each radial bin

Return type:

eT(array)

static _match_input_to_det(true_x, true_y, det_x, det_y)[source]
static get_summary_struct(n_halos, n_bins)[source]
static get_per_galaxy_struct(n_gal)[source]
static angsep(ra, dec, ra2=200.0, dec2=0.0)[source]
static position_angle_ccw_from_east(ra1, dec1, ra2, dec2)[source]

Compute the PA of (ra2,dec2) relative to (ra1,dec1), measured from +RA (east=0°), increasing CCW towards +Dec (north). Returns an Angle in [0,360)°.

static generate_summary_plot(summary_table)[source]
run(*, skymap, src00List, src01List, truth00List, truth01List, tractList, **kwargs)[source]