Skip to content

Commit b2a7800

Browse files
adding more debugging prints
1 parent 1a285c1 commit b2a7800

File tree

2 files changed

+12
-1
lines changed

2 files changed

+12
-1
lines changed

xga/sourcetools/_common.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -258,7 +258,9 @@ def _setup_inv_abel_dens_onion_temp(sources: Union[GalaxyCluster, ClusterSample]
258258
sources, outer_rads, has_glob_temp = _setup_global(sources, outer_radius, global_radius, abund_table, group_spec,
259259
spec_min_counts, spec_min_sn, over_sample, num_cores, psf_bins,
260260
stacked_spectra, src_telescopes)
261-
261+
print("has_global_temp")
262+
print(has_glob_temp)
263+
262264
rads_dict = {str(sources[r_ind]): r for r_ind, r in enumerate(outer_rads)}
263265

264266
# This checks and sets up a predictable structure for the models needed for this measurement.

xga/sourcetools/temperature.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -814,6 +814,8 @@ def onion_deproj_temp_prof(sources: Union[GalaxyCluster, ClusterSample], outer_r
814814
psf_corr, psf_model, psf_bins, psf_algo, psf_iter, group_spec, min_counts,
815815
min_sn, over_sample, one_rmf, freeze_met, abund_table, temp_lo_en, temp_hi_en,
816816
num_cores, stacked_spectra=stacked_spectra, telescope=telescope)
817+
print("ann_rads")
818+
print(ann_rads)
817819
elif annulus_method == "growth":
818820
raise NotImplementedError("This method isn't implemented yet")
819821

@@ -837,9 +839,12 @@ def onion_deproj_temp_prof(sources: Union[GalaxyCluster, ClusterSample], outer_r
837839
# The normalisation profile(s) from the fit that produced the projected temperature profile.
838840
apec_norm_prof = src.get_apec_norm_profiles(cur_rads, group_spec, min_counts,
839841
min_sn, over_sample, telescope=tel)
842+
print("profiles here")
843+
840844
except NoProductAvailableError:
841845
# warn("{s} doesn't have a matching projected temperature profile, skipping.")
842846
all_3d_temp_profs[tel][src_ind] = None
847+
print("no profiles!")
843848
continue
844849

845850
# We need to check if a matching 3D temperature profile has already been generated, as then we
@@ -855,10 +860,14 @@ def onion_deproj_temp_prof(sources: Union[GalaxyCluster, ClusterSample], outer_r
855860

856861
obs_id = 'combined'
857862
inst = 'combined'
863+
print(tel)
864+
print("len(proj_temp)")
865+
print(len(proj_temp))
858866
# There are reasons that a projected temperature profile can be considered unusable, so we must check. Also
859867
# make sure to only use those profiles that have a minimum of 4 annuli. The len operator retrieves the number
860868
# of radial data points a profile has
861869
if proj_temp.usable and len(proj_temp) > 3:
870+
print("In here")
862871
# Also make an Emission Measure profile, used for weighting the contributions from different
863872
# shells to annuli
864873
em_prof = apec_norm_prof.emission_measure_profile(src.redshift, src.cosmo, abund_table,

0 commit comments

Comments
 (0)