Euclid: Modelling observational effects in cluster counts and cluster clustering
Listen
Radio episode about this paper
Transcript
Introduction to the show: ident: Astrophysics Radio. Generated commentary on the latest astrophysics papers.
Vera: I'm Vera.
Jocelyn: And I'm Jocelyn, here with Subrahmanyan.
Vera: We're looking at the paper: "Euclid: Modelling observational effects in cluster counts and cluster clustering".
Jocelyn: Here's the gist of the paper. This study explores the impact of observational and modelling systematic effects on cluster number counts and cluster clustering and provides model prescriptions for their joint analysis, in the context of the Euclid survey Theoretical Framework The paper introduces the theoretical formalism to describe number counts and cluster clustering, along with their covariance matrix models, originally presented in F21 and EC:F24 As demonstrated in Fumagalli et al.
Vera: (2024), number counts and clustering alone do not provide sufficient constraints on scaling relations The authors describe the likelihood function adopted for cosmological inference and the summary statistics used to compare results Simulated Data Generation The analysis is validated using 1000 Euclid-like lightcones generated with the PINOCCHIO code, where observational effects such as photometric and richness estimate errors are introduced These catalogues contain haloes with Mvir ≥ 10 13.4 h−1 M⊙ The simulations are based on a flat ΛCDM cosmology consistent with Planck Collaboration XVI (2014) Probe Combination and Constraints The full-probe combination is the most powerful combination for extracting cosmological information, and the less affected by prior-volume effects The full probe combination yields the tightest constraints, with clustering and weak lensing mass providing the most precise results Systematic Effect Analysis The primary effect of redshift effects on the 2PCF arises from photo-z uncertainties Neglecting these effects in the covariance modelling can lead to a 10–20% underestimation of the posterior amplitude Secondary redshift distortions—namely, RSDs, IR resummation, and geometric distortions—have an almost negligible impact (≲ 5%) on the FoM when clustering is considered alone Key Findings The two statistics are therefore independent The cosmology-dependence of the clustering covariance brings useful information, increasing the constraining power of clustering by about 40% The full probe combination is less sensitive to the cosmological dependence of the covariances The absence of significant correlations between number counts and clustering simplifies the analysis, further optimising the information gain However, narrow parameter constraints make full-probe analyses more sensitive to systematic effects The results provide valuable insight into the influence of observational and modelling systematics on cosmological constraints from upcoming Euclid data Discussion and Conclusions
Title and authors: Vera: We're starting with the paper, Euclid: Modelling observational effects in cluster counts and cluster clustering. The authors include Fumagalli, Costanzi, Castro, Saro, Borgani, Romanello, Marulli, Tsaprazi, Monaco through to Baldi and others.
Jocelyn: It’s a big team effort covering a lot of ground in observational cosmology and modeling the noise we encounter. The title itself tells us the focus is on how those observational effects impact both counting clusters and studying their clustering patterns.
Subrahmanyan: The implication here is that we need to go beyond just raw cluster counts or just the way they are clumped together to get a really solid handle on how structure forms in this universe.
Vera: Basically, they’re taking the theoretical tools for describing these statistics and applying them specifically to what Euclid will observe across its survey area.
Jocelyn: And the authors are bringing in a lot of expertise from different areas, which is important because you need people who understand both the observational data pipeline and the underlying cosmological models.
Subrahmanyan: It suggests that combining these different types of statistical measures, like counts and clustering, might unlock constraints that neither one could provide alone.
The paper's summary: Vera: So what’s the actual substance of this paper? They lay out the likelihood function they use for cosmological inference and the summary statistics they employ to compare different results.
Jocelyn: They are focusing on how to properly model those observational effects, specifically photometric redshift uncertainties, which they treat as a Gaussian distribution with a mean equal to z tr and a scatter that depends on redshift.
Subrahmanyan: This modeling involves setting up equations for the expected number density of haloes in different richness bins, using the halo mass function and some observed richness-mass relation parameters.
Vera: They also introduce parameters like Mp, which is three times ten to fourteen h minus one solar masses, as the pivot mass for their analysis.
Jocelyn: And they describe how that intrinsic richness-mass relation itself follows a log-normal distribution with its own mean and scatter terms that depend on the halo mass.
Subrahmanyan: The variance in this richness-mass relation comes from two sources: the intrinsic scatter D lambda, plus a Poisson component which is just the counting noise.
The paper's improvements: Vera: Now, what are the actual improvements they propose to make this analysis better? They suggest several ways to enhance their system for joint likelihood analysis.
Jocelyn: One key improvement is performing a joint likelihood analysis that includes cluster counts, the two point correlation function monopole, and weak lensing mean mass for tighter constraints.
Subrahmanyan: That joint approach is supposed to improve the figure of merit by more than three hundred percent compared to what you'd get from standard combinations.
Vera: They also suggest incorporating those cosmology dependent covariance matrices directly into the likelihood analysis, which they show increases the constraining power of clustering by about forty percent.
Jocelyn: And they actually identify and quantify the impact of redshift-space distortions, or RSDs, and photometric redshift uncertainties on number count covariance.
Subrahmanyan: If you neglect those effects in your covariance modeling, you could be underestimating the posterior amplitude by ten to twenty percent.
Conclusion: Vera: So to wrap up this discussion on Euclid: Modelling observational effects in cluster counts and cluster clustering, the authors show that these two statistics are independent.
Jocelyn: The cosmology dependence of the clustering covariance brings useful information, which boosts the constraining power of clustering by about forty percent when you consider it alongside number counts.
Subrahmanyan: They also find that the full probe combination is less sensitive to the cosmological dependence of those covariances because that dependence tends to saturate once you combine number counts with clustering.
Vera: However, they do note a caveat: narrow parameter constraints mean that full-probe analyses can be more sensitive to systematic effects.
Jocelyn: The main point for us listening today is that understanding these observational and modelling systematics is vital for getting the best possible cosmological constraints from the Euclid data.
Subrahmanyan: It’s important to remember that while this paper shows how to model these effects, it also highlights where our current methods are most sensitive to those very same systematic uncertainties.
A. Fumagalli, M. Costanzi, T. Castro, A. Saro, S. Borgani, M. Romanello, F. Marulli, E. Tsaprazi, P. Monaco, B. Altieri, A. Amara, L. Amendola, S. Andreon
ESO
astro-ph.CO
Submitted: 2025-10-15
Updated: 2026-11-04
Comments: 16 pages, 14 figures
Journal ref: A&A 709, A102 (2026)
DOI: 10.1051/0004-6361/202557708
License: http://creativecommons.org/licenses/by/4.0/
Importance score: 85/100
The gist: This study explores the impact of observational and modelling systematic effects on cluster number counts and cluster clustering and provides model prescriptions for their joint analysis…
Key concepts
- Number Counts
- This refers to counting the number of galaxy clusters within specific regions of space. In this study, it's analyzed alongside clustering statistics to understand how observational errors influence these counts.
- Cluster Clustering (2PCF)
- This measures how galaxies or clusters are spatially distributed relative to each other. The two-point correlation function (2PCF) is a key tool here, and the paper examines how observational effects like photometric redshift errors impact this measurement.
- Systematic Effects
- These are errors arising from observational limitations or modeling assumptions, such as uncertainties in photometric redshifts or neglecting redshift-space distortions. The study quantifies how these systematic effects bias the final cosmological results.
- Full Probe Combination
- This involves using multiple data types—like cluster counts, 2PCF, and weak lensing mass—together. The paper finds this combination is the most powerful way to extract cosmological information because it is less sensitive to certain modeling dependencies.
Terminology
Summary
This study explores the impact of observational and modelling systematic effects on cluster number counts and cluster clustering and provides model prescriptions for their joint analysis, in the context of the Euclid survey Using 1000 Euclid-like cluster catalogues, we investigate the effect of systematic uncertainties on cluster summary statistics and their auto- and cross-covariance, and perform a likelihood analysis to evaluate their impact on cosmological constraints, with a focus on the matter density parameter omegam and on the power spectrum amplitude σ8 Combining cluster clustering with number counts significantly improves cosmological constraints, with the figure of merit increasing by over 300% compared to number counts alone We confirm that the two probes are uncorrelated, and the cosmological constraints derived from their combination are almost insensitive to the cosmology dependence of the covariance
Theoretical Framework for Probes
The theoretical formalism is introduced to describe number counts and cluster clustering, along with their covariance matrix models Number counts are described by an integral involving the observed comoving volume element per unit redshift and solid angle The expected number density of haloes in the i-th richness bin is given by an integral over halo mass, weighted by the halo mass function and the observed richness-mass relation The second term in Eq. (5), P(λ obλ tr,z tr), represents the observational scatter in the richness-mass relation, caused by photometric noise, background subtraction uncertainties, and projection/percolation effects Cluster clustering is described through the 3D 2PCF monopole The matter power spectrum in Eq. p. 2 The second term in Eq. (5), P(λ
ob|λ
tr
,z
tr), represents the observational scatter in the richness-mass relation, caused by photometric noise, background subtraction uncertainties, and projection/percolation effects.Where the paper says it
Simulated Data Generation
Accurate covariance matrix estimation necessitates extensive data sets, often exceeding 103 catalogues Instead of computationally expensive N-body simulations, the PINOCCHIO code is employed to quickly generate dark matter halo catalogues The data set consists of 1000 lightcones covering 10 cubed deg2 and redshifts z = 0 to z = 2.5 These catalogues contain haloes with Mvir ≥ 10 13. p. 4 Our data set consists of 1000 lightcones covering 10 313
deg2
and redshifts z = 0 to z = 2. These catalogues, generated from boxes of side 3870 h
−1 Mpc and 21603 particles, contain haloes with Mvir ≥ 1013. Each object is labelled
with a rescaled virial mass, a true undistorted redshift, and a redshift with RSDs, along with angular coordinates. To mimic the observational properties of cluster surveys, we
attach a true richness to each mass, by assuming a scaling relation with mean and variance from Eqs. 5 The parameter values are converted from ∆500 with respect to the
critical density to the virial overdensity. In addition, two observed redshifts are assigned assuming a
normal distribution with scatter given by Eq.Where the paper says it
Where the paper says it
Where the paper says it
Impact of Systematic Effects on Constraints
The analysis investigates the impact of observational and modelling systematic effects, such as redshift-space distortions in the linear regime (RSDs) and photometric redshift (photo-z) errors Photometric redshift uncertainties broaden cosmological posteriors by 20–30%, while secondary effects like redshift-space distortions (RSDs) have a smaller impact on the posteriors – 5% for clustering alone, 10% when combining probes Clustering data below 60 h−1 Mpc provides additional constraining power, while scales larger than acoustic oscillation scale add almost no information on omegam and σ8 parameters RSDs and photo-z uncertainties also influence the number count covariance, with a significant impact, of about 15–20%, on the parameter constraints
Probe Combination and Covariance Dependence
The full-probe combination is found to be the most powerful combination for extracting cosmological information, and it is less affected by prior-volume effects The cosmology-dependence of the clustering covariance brings useful information, increasing the constraining power of clustering by about 40% This improvement disappears when number counts are combined, thus in line with the result that number counts already encapsulate additional information from the clustering covariance The combination of the three probes yields tighter constraints, with clustering and weak lensing mass providing the tightest constraints
Validation of Systematics
The primary effect of redshift effects on the 2PCF arises from photo-z uncertainties An optimistic estimate for photo-z uncertainties of σz0 = 0.005 results in a small impact on parameter constraints, reducing the cosmological FoM by less than 10% Secondary redshift distortions – namely, RSDs, IR resummation, and geometric distortions – have an almost negligible impact (≲ 5%) on the FoM when clustering is considered alone Neglecting photo-z and RSD effects in the covariance significantly impacts cosmological constraints, as shown in Fig. p. 0 We confirm that the two probes are uncorrelated, and the cosmological constraints derived from their combination are
almost insensitive to the cosmology dependence of the covariance. We find that photometric redshift uncertainties broaden cosmological posteriors
by 20–30%, while secondary effects like redshift-space distortions (RSDs) have a smaller impact on the posteriors – 5% for clustering alone, 10%
when combining probes – but can significantly bias the constraints if neglected.Where the paper says it
Conclusion on Future Analysis
The presented analysis is rather conservative, assuming mass calibration at the 1% level out to redshift 2 and neglecting potential model systematics, such as uncertainties in the P(λ obM) relation at high redshift Current analyses neglect the cross-correlation between weak lensing mass and both counts and clustering; while this assumption is supported by reasonable arguments, it needs to be tested The results provide valuable insight into the influence of observational and modelling systematics on cosmological constraints from upcoming Euclid data The necessity of accounting for effects that were neglected in previous studies is highlighted
References
Abate, A., Aldering, G., Allen, S. p. 0 it
tive to the properties of the initial density field of the Universe,
to the nature of dark matter and dark energy, and to the laws of
gravity on large scales (e. Allen et al. So far, the primary method for extracting cosmological information from cluster catalogues has been the analysis of
their mass- and redshift-dependent number counts (e. , Borgani
Article number, page 1 of 16
arXiv:2510. So far, the primary method for extracting cosmological information from cluster catalogues has been the analysis of
their mass- and redshift-dependent number counts (e. , Borgani
Article number, page 1 of 16
arXiv:2510. it
tive to the properties of the initial density field of the Universe,
to the nature of dark matter and dark energy, and to the laws of
gravity on large scales (e. Allen et al. 2001; Henry 2004; Vikhlinin et al. 2009; Mantz et al. The Kaiser effect produces a scale-independent boost of the 2PCF, while the
effect of the photo-z uncertainties is to decrease the correlation
on small scales and increase it on larger scales, smearing the
baryon acoustic oscillation (BAO) peak. The BAO scales are also subject to broadening and a shift
of the peak due to nonlinear damping, which can be corrected
through the infrared resummation (IR, Senatore & Zaldarriaga
2015; Baldauf et al. The Kaiser effect produces a scale-independent boost of the 2PCF, while the
effect of the photo-z uncertainties is to decrease the correlation
on small scales and increase it on larger scales, smearing the
baryon acoustic oscillation (BAO) peak. The BAO scales are also subject to broadening and a shift
of the peak due to nonlinear damping, which can be corrected
through the infrared resummation (IR, Senatore & Zaldarriaga
2015; Baldauf et al. 2009; Mantz et al. 2015;
Planck Collaboration XXIV. 2021; Lesci
et al. 2022; Bocquet et al. 2022; Bocquet et al. 2024; Ghirardini et al. Allen et al. 2011; Kravtsov & Borgani 2012). Beyond traditional methods like cluster counts, cluster clustering stands out as a powerful technique for cosmology (Borgani et al. 1999; Estrada et al. The window function for a redshift
slice of a lightcone is given in Costanzi et al. (2019) and takes
the form
Wa(k) =
4π
Va
Z
∆za
dz Ωsky
dV
dz dΩ
X∞
ℓ=0
X
ℓ
m=−ℓ
i
ℓ
jℓ[k r(z)] Yℓm(kˆ) Kℓ
,
(11)
where Va is the volume of the redshift slice, jℓ[k r(z)] are the
spherical Bessel functions, Yℓm(kˆ) are the spherical harmonics, kˆ
is the angular part of the wave-vector, and Kℓ are the coefficients
of the harmonic expansion. 2021; Lesci
et al. 2022; Bocquet et al. 2016; Costanzi et al. 2021; Lesci
et al. Simulations
Accurate covariance matrix estimation necessitates extensive
data sets, often exceeding 103
catalogues (Taylor et al. 2013;
Dodelson & Schneider 2013). Simulations
Accurate covariance matrix estimation necessitates extensive
data sets, often exceeding 103
catalogues (Taylor et al. 2013;
Dodelson & Schneider 2013). 2003; Majumdar & Mohr 2004;
Mana et al. 2013; Lesci et al. Beyond traditional methods like cluster counts, cluster clustering stands out as a powerful technique for cosmology (Borgani et al. 1999; Estrada et al. 2001; Henry 2004; Vikhlinin et al. 2009; Mantz et al. org/
Fumagalli et al. (2021, hereafter F21) and Euclid Collaboration: Fumagalli et al. (2021, hereafter F21) and Euclid Collaboration: Fumagalli et al. (2024, hereafter EC:F24) carried out
the first steps for the characterisation of theoretical systematics
in the cosmological analysis of cluster number counts (see also
Payerne et al. 2015; Romanello et al. The Kaiser effect produces a scale-independent boost of the 2PCF, while the
effect of the photo-z uncertainties is to decrease the correlation
on small scales and increase it on larger scales, smearing the
baryon acoustic oscillation (BAO) peak.Where the paper says it
Where the paper says it
Where the paper says it
Where the paper says it
Where the paper says it
Where the paper says it
Where the paper says it
Where the paper says it
Where the paper says it
Where the paper says it
Where the paper says it
Where the paper says it
Where the paper says it
Where the paper says it
Where the paper says it
Where the paper says it
Where the paper says it
Where the paper says it
Where the paper says it
Where the paper says it
Where the paper says it
Where the paper says it
Where the paper says it
Appendix A: Impact of redshift photometric bias
The check here shows that even in the optimistic photo-z case (σ0 = 0.005), such a redshift bias does not impact the cosmological constraints significantly Both the clustering and weak lensing masses and the full-probe combinations are characterized by no difference in the IoI between the bias and no-bias cases, as well as by a ∆FoM consistent with zero We therefore do not add any bias to the observed redshift in out simulations (see Sect. p. 0 We find that photometric redshift uncertainties broaden cosmological posteriors
by 20–30%, while secondary effects like redshift-space distortions (RSDs) have a smaller impact on the posteriors – 5% for clustering alone, 10%
when combining probes – but can significantly bias the constraints if neglected. We show that clustering data below 60 h
−1 Mpc provides additional
constraining power, while scales larger than acoustic oscillation scale add almost no information on Ωm and σ8 parameters.Where the paper says it
Appendix B: Impact of nonlinearities
Photo-z uncertainties mix the power spectrum modes parallel to the line of sight, propagating nonlinearities to larger scale and making the linear theory inadequate for describing clustering up to scales of approximately 60 h−1 Mpc at high redshift A correction factor, defined as B2 = ξˆ obs / ξfid, is introduced in the likelihood analysis to enhance the model accuracy This factor serves primarily as a “safety net” and is not strictly essential The effect is completely washed out in the presence of photo-z uncertainties
Appendix C: Impact of radial scales in the clustering analysis
The majority of the cosmological information comes from the region around the BAO peak (approximately r = 60–130 h−1 Mpc), with small and large scales offering negligible contributions Increasing the lower limit to larger scales, such as r = 40 h−1 Mpc or r = 60 h−1 Mpc, leads to a progressive broadening of the parameter constraints Scales between 20 and 60 h−1 Mpc carry sizeable cosmological information
Appendix D: Number count validation
RSDs and photo-z uncertainties do not affect the number of objects in each redshift bin, leaving the shot-noise term unchanged In contrast, the sample variance signal reflects the distortions in the power spectrum caused by RSDs and photo-z unArticle number, page 8 of 16
Appendix E: Discussion and Conclusions
The full-probe analysis is the most powerful combination for extracting cosmological information, and it is less affected by prior-volume effects The addition of clustering not only enhances the extraction of cosmological information, but also mitigates the impact of systematics, leading to more precise and more accurate constraints The absence of significant correlations between number counts and clustering simplifies the analysis, further optimising the information gain However, our findings also highlight the need for caution when performing full-probe analyses, as narrower parameter constraints make them more sensitive to systematic effects The results provide valuable insight into the influence of observational and modelling systematics on cosmological constraints from upcoming Euclid data
INAF-Osservatorio Astronomico di Trieste
INAF-Osservatorio Astronomico di Trieste, Via G. B. Tiepolo 11, 34143 Trieste, Italy Ludwig-Maximilians-University, Schellingstrasse 4, 80799 Munich, Germany Dipartimento di Fisica - Sezione di Astronomia, Università di Trieste, Via Tiepolo 11, 34131 Trieste, Italy IFPU, Institute for Fundamental Physics of the Universe, via Beirut 2, 34151 Trieste, Italy INFN-Sezione di Trieste, Via Valerio 2, 34127 Trieste TS, Italy
INFN-Sezione di Bologna
INFN-Sezione di Bologna, Viale Berti Pichat 6/2, 40127 Bologna, Italy Dipartimento di Fisica e Astronomia Augusto Righi
- Alma Mater Studiorum Università di Bologna, via Piero Gobetti 93/2, 40129 Bologna, Italy INFN-Sezione di Bologna, Viale Berti Pichat 6/2, 40127 Bologna, Italy
INAF-Osservatorio di Astrofisica e Scienza dello Spazio di Bologna
INAF-Osservatorio di Astrofisica e Scienza dello Spazio di Bologna, Via Piero Gobetti 93/3, 40129 Bologna, Italy
Dipartimento di Fisica e Astronomia Augusto Righi
- Alma Mater Studiorum Università di Bologna
Dipartimento di Fisica e Astronomia Augusto Righi
- Alma Mater Studiorum Università di Bologna, via Piero Gobetti 93/2, 40129 Bologna, Italy
INFN-Sezione di Milano
INFN-Sezione di Milano, Via Celoria 16, 20133 Milano, Italy
Institute for Astronomy, University of Hawaii
Institute for Astronomy, University of Hawaii, 2680 Woodlawn Drive, Honolulu, HI 96822, USA
Department of Physics E. Pancini
, University Federico II
Department of Physics E. Pancini
, University Federico II, Via Cinthia 6, 80126 Napoli, Italy
INAF-Osservatorio Astronomico di Capodimonte
INAF-Osservatorio Astronomico di Capodimonte, Via Moiariello 16, 80131 Napoli, Italy
Dipartimento di Fisica, Università degli Studi di Torino
Dipartimento di Fisica, Università degli Studi di Torino, Via P. Giuria 1, 10125 Torino, Italy
INFN-Sezione di Torino
INFN-Sezione di Torino, Via P.
Green — the paper says it, and the page is printed. Red — no passage carries it, so treat that sentence as unverified. The same check runs on your own text: check a summary against its source, $5.
Improvements for AI systems
-
Improved system can perform joint likelihood analysis of cluster counts, 2PCF monopole, and weak lensing mean mass to achieve tighter constraints with an FoM improvement of more than 300% compared to standard combinations.
-
Improved system can incorporate cosmology dependent covariance matrices into the likelihood analysis, which is shown to increase the constraining power of clustering by about 40%.
-
Improved system can identify and quantify the impact of redshift-space distortions (RSDs) and photometric redshift uncertainties on number count covariance, leading to a 10 to 20 percent underestimation of posterior amplitude if neglected.
-
Improved system can employ an effective power spectrum Peff(k) calculated as the sum of power spectrum multipoles to efficiently capture the sample covariance in a computationally feasible manner.
-
Improved system can utilize a scale dependent correction factor B2 to model nonlinearities in the 2PCF, enhancing model accuracy and serving as a
safety net
against discrepancies between linear theory and observed measurements. -
Improved system can perform posterior analysis that is less sensitive to the cosmological dependence of covariances, as this dependence saturates the information extracted from sample statistics when combining number counts with clustering.
Abstract
This study explores the impact of observational and modelling systematic effects on cluster number counts and cluster clustering and provides model prescriptions for their joint analysis in the context of the Euclid survey. Using 1000 Euclid-like cluster catalogues, we investigated the effect of systematic uncertainties on cluster summary statistics and their auto- and cross-covariance, and performed a likelihood analysis to evaluate their impact on cosmological constraints, with a focus on the matter density parameter, Ω m, and on the power spectrum amplitude, σ 8. Combining cluster clustering with number counts significantly improves cosmological constraints, with the figure of merit increasing by over 300 % compared to number counts alone. We confirm that the two probes are uncorrelated, and the cosmological constraints derived from their combination are almost insensitive to the cosmology dependence of the covariance. We find that photometric redshift uncertainties broaden cosmological posteriors by 20--30 %, while secondary effects such as redshift-space distortions (RSDs) have a smaller impact on the posteriors -- 5 % for clustering alone, 10 % when combining probes -- but can significantly bias the constraints if neglected. We show that clustering data below 60,h-1, Mpc provides additional constraining power, while scales larger than the acoustic oscillation scale add almost no information on Ω m and σ 8 parameters. The RSDs and photo- z uncertainties also influence the number count covariance, with a significant impact of about 15--20 % on the parameter constraints.
Sources
- Euclid Quick Data Release (Q1). First detections from the galaxy cluster workflow
- Euclid. I. Overview of the Euclid mission
- Euclid Definition Study Report
Related papers
- 21cmEMUv3: a hybrid diffusion-LSTM emulator of 21cmFAST summary observables
- Connecting field-level and n-point function measurements of galaxy bias
- The Impact of Cosmic Variance and Satellites on JWST Clustering Measurements at Redshift around 6
- Universality of Primordial Anisotropies in Gravitational Wave Background
- KiDS-1000 cosmic shear reanalysis using MetaCalibration
- 2Flow2SN: Dusty Supernova Cosmology with Photometric Redshifts and Contamination using Neural Simulation-Based Inference