Skip to content

Commit

Permalink
remvoed recompute_covmat_for_ndeproj
Browse files Browse the repository at this point in the history
  • Loading branch information
Fiona McCarthy committed Feb 9, 2024
1 parent 817ffc7 commit 1db356b
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 24 deletions.
12 changes: 0 additions & 12 deletions pyilc/input.py
Original file line number Diff line number Diff line change
Expand Up @@ -508,18 +508,6 @@ def __init__(self, input_file=None):
self.weight_filename_hdf5 = self.output_dir+self.output_prefix+'_weightmaps_component_'+self.ILC_preserved_comp+'_deproject_'+'_'.join(self.ILC_deproj_comps[0])+'_crossILC'*self.cross_ILC+self.output_suffix_weights+'.fits'


# recompute_covmat_for_ndeproj is a flagthat, when it is on, includes the number of deprojected components
# in the filenames for the covmat. If it is off, it does not. This is important because the size of the real
# space filters is set by calculating an area that includes enough modes to respect a userspecified ILC bias
# tolerance, and this calculation changes depending on N_deproj. However, it is computationally intensive
# to recompute the covmat, and this is likely a small effect, so it is often likely OK to just use the same
# covmat and not recompute all the time. So, if you don't want to recompute for different values of N_deproj,
# turn this off and it will just use the covmat calculated on the area appropriate for what N_deproj was the
# first time you ran the code.
if 'recompute_covmat_for_ndeproj' in p.keys():
self.recompute_covmat_for_ndeproj = p['recompute_covmat_for_ndeproj']
else:
self.recompute_covmat_for_ndeproj = False

####################
### TODO: this block of code with SED parameters, etc is currently not used anywhere
Expand Down
12 changes: 0 additions & 12 deletions pyilc/wavelets.py
Original file line number Diff line number Diff line change
Expand Up @@ -1375,12 +1375,6 @@ def _cov_filename(info,freq1,freq2,scale):
j = scale

cov_filename = info.output_dir+info.output_prefix+'_needletcoeff_covmap_freq'+str(a)+'_freq'+str(b)+'_scale'+str(j)+'_crossILC'*info.cross_ILC+'.fits'
if info.recompute_covmat_for_ndeproj:
if type(info.N_deproj) is int:
N_deproj = info.N_deproj
else:
N_deproj = info.N_deproj[j]
cov_filename = info.output_dir+info.output_prefix+'_needletcoeff_covmap_freq'+str(a)+'_freq'+str(b)+'_scale'+str(j)+'_crossILC'*info.cross_ILC+'_Ndeproj'+str(N_deproj)+'.fits'

return cov_filename

Expand All @@ -1391,12 +1385,6 @@ def _inv_cov_filename(info,freq1,freq2,scale):
j = scale

inv_cov_filename = info.output_dir+info.output_prefix+'_needletcoeff_invcovmap_freq'+str(a)+'_freq'+str(b)+'_scale'+str(j)+'_crossILC'*info.cross_ILC+'.fits'
if info.recompute_covmat_for_ndeproj:
if type(info.N_deproj) is int:
N_deproj = info.N_deproj
else:
N_deproj = info.N_deproj[j]
inv_cov_filename = info.output_dir+info.output_prefix+'_needletcoeff_invcovmap_freq'+str(a)+'_freq'+str(b)+'_scale'+str(j)+'_crossILC'*info.cross_ILC+'_Ndeproj'+str(N_deproj)+'.fits'

return inv_cov_filename

Expand Down

0 comments on commit 1db356b

Please sign in to comment.