Skip to content

Commit 6301830

Browse files
committed
Updated to new MassSummary.
1 parent 6b6e455 commit 6301830

File tree

1 file changed

+6
-7
lines changed

1 file changed

+6
-7
lines changed

tutorials/python/cluster_wl_simul.qmd

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -89,14 +89,13 @@ cluster_z = 0.2
8989
9090
cluster_ra, cluster_dec = 12.34, -55.123
9191
92-
density_profile = Nc.HaloDensityProfileNFW.new(
93-
Nc.HaloDensityProfileMassDef.CRITICAL, mass_delta
94-
)
92+
mass_summary = Nc.HaloMCParam.new(Nc.HaloMassSummaryMassDef.CRITICAL, mass_delta)
93+
density_profile = Nc.HaloDensityProfileNFW.new(mass_summary)
9594
surface_mass_density = Nc.WLSurfaceMassDensity.new(dist)
9695
halo_position = Nc.HaloPosition.new(dist)
9796
98-
density_profile["cDelta"] = cluster_c
99-
density_profile["log10MDelta"] = np.log10(cluster_M)
97+
mass_summary["cDelta"] = cluster_c
98+
mass_summary["log10MDelta"] = np.log10(cluster_M)
10099
101100
halo_position["ra"] = cluster_ra
102101
halo_position["dec"] = cluster_dec
@@ -147,7 +146,7 @@ galaxy_shape_e_sigma = 1.0e-8
147146
p_dist = Nc.GalaxySDPositionFlat.new(
148147
galaxies_ra0, galaxies_ra1, galaxies_dec0, galaxies_dec1
149148
)
150-
z_true = Nc.GalaxySDTrueRedshiftLSSTSRD.new(galaxy_true_z_min, galaxy_true_z_max)
149+
z_true = Nc.GalaxySDTrueRedshiftLSSTSRD.new()
151150
z_dist = Nc.GalaxySDObsRedshiftGauss.new(z_true)
152151
s_dist = Nc.GalaxySDShapeGauss.new()
153152
@@ -336,7 +335,7 @@ def gen_galaxies(halo_ra: float, halo_dec: float, halo_mass: float) -> pd.DataFr
336335
rng = Ncm.RNG.seeded_new("mt19937", 1235)
337336
halo_position["ra"] = halo_ra
338337
halo_position["dec"] = halo_dec
339-
density_profile["log10MDelta"] = np.log10(halo_mass)
338+
mass_summary["log10MDelta"] = np.log10(halo_mass)
340339
341340
surface_mass_density.prepare(cosmo)
342341
halo_position.prepare(cosmo)

0 commit comments

Comments
 (0)