Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
54 commits
Select commit Hold shift + click to select a range
2560b2f
add function to restrict detectors
17-sugiyama Sep 17, 2025
0e86db5
update c1f filter to handle parameter arrays
17-sugiyama Sep 23, 2025
c8a43aa
minor change in get_pca
17-sugiyama Sep 23, 2025
2fa6179
Merge remote-tracking branch 'origin/master' into c1f_and_common_mode
Sep 28, 2025
4a2f6d4
fft_ops has new function ``get_common_noise_params``
Sep 28, 2025
dfbe688
counter_1_over_f accepts parameters in str
Sep 28, 2025
6e6ec40
add PSDFit
Sep 28, 2025
c12f519
update PSDFit
Sep 28, 2025
2f9a172
modified c1f method
Sep 28, 2025
d3d212b
modified c1f script
Sep 28, 2025
d89574e
add functions for pca common noise subtraction
Sep 28, 2025
676275b
add lpf options to build_hpf_params_dict
Sep 28, 2025
37f3e1e
debug
Sep 29, 2025
6375a32
Merge remote-tracking branch 'origin/master' into detector_restrictio…
Sep 29, 2025
62e3401
change LabelAxis to label_axis
17-sugiyama Oct 2, 2025
f633a74
Update counter_1_over_f conditional branch
17-sugiyama Oct 2, 2025
71a9ea4
Update docstring of get_common_noise_params
17-sugiyama Oct 2, 2025
b24c802
Update docstring of GetCommonMode
17-sugiyama Oct 2, 2025
9f366fb
Merge remote-tracking branch 'origin/c1f_and_common_mode' into junna_…
msilvafe Oct 7, 2025
b63f9a6
Merge remote-tracking branch 'origin/detector_restriction_by_t2p_fit'…
msilvafe Oct 7, 2025
64a4bfc
Add t2p selection.
msilvafe Oct 8, 2025
8625498
Modify counter_1_over_f filter to get metadata from proc_aman. Add ea…
satoru99 Oct 9, 2025
7b40402
Merge remote-tracking branch 'origin/master' into junna_preproc
Nov 18, 2025
09c8095
add functions to estimate scan frequency
Nov 18, 2025
77f1695
add t2p leakage estimation in frequency domain
Nov 18, 2025
fe82ece
add preprocesses
Nov 18, 2025
45827ff
Update get_t2p_cuts
17-sugiyama Nov 18, 2025
b083c73
registered ScanFreqCut
17-sugiyama Nov 20, 2025
4d9d4a7
debug t2pleakage.py
17-sugiyama Nov 20, 2025
1994d0f
debug preprocess.py
Nov 20, 2025
5bc134e
Fix t2p leakage splits.
msilvafe Nov 21, 2025
33370e3
Fix errors and add in t2p select.
msilvafe Nov 21, 2025
d1449a2
Generalize build_hpf to build general filter
msilvafe Nov 21, 2025
4040404
Fix select typo.
msilvafe Nov 21, 2025
67dc007
Fix passing in azss stats aman through preprocess.
msilvafe Nov 23, 2025
36e530f
Fix to subtracting azss model when fit is used and params are stored.
msilvafe Nov 23, 2025
6f50ad9
Add missing relcal cut.
msilvafe Nov 25, 2025
88229b1
Add skipping select
msilvafe Nov 25, 2025
fec08ac
Fix calibrate cuts call.
msilvafe Nov 25, 2025
734e5f8
Don't make a copy.
msilvafe Nov 25, 2025
8494d64
Add azss det selection.
msilvafe Dec 1, 2025
809f76e
handled over flagged azss data.
msilvafe Dec 4, 2025
5f71606
add bounds for noise fitting.
msilvafe Dec 5, 2025
c3e7e9f
Add distribution cut.
msilvafe Dec 8, 2025
3b4378a
Fix typos.
msilvafe Dec 8, 2025
e0024a4
Merge branch 'master' into junna_preproc
msilvafe Dec 9, 2025
bfaf206
Make sim function consistent with data function cuts.
msilvafe Dec 10, 2025
ddd5dff
Add overwriting junna's noise fits for filtering.
msilvafe Dec 11, 2025
f48b32b
Add optional change in fit method.
msilvafe Dec 15, 2025
8d846bb
Fix passing fit type args.
msilvafe Dec 16, 2025
d14316c
Add mean method for calc_wn.
msilvafe Dec 17, 2025
c1c4aa6
Fix t2p subtraction select method to work without valid_data cuts.
msilvafe Dec 17, 2025
b31cf17
Add nan stats in get_good_distribution_flags.
msilvafe Dec 17, 2025
97b5153
Remove load file for fourier filter and add si range to det_bias_flags.
msilvafe Dec 18, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 12 additions & 4 deletions sotodlib/obs_ops/splits.py
Original file line number Diff line number Diff line change
Expand Up @@ -150,11 +150,19 @@ def get_split_flags(aman, proc_aman=None, split_cfg=None):

if 't2p' in proc_aman:
# T2P Leakage split
if not 'high_leakage' in split_cfg:
if 'high_leakage' not in split_cfg:
split_cfg['high_leakage'] = 1e-3
fm.wrap_dets('high_leakage', np.sqrt(proc_aman.t2p.lamQ**2 + proc_aman.t2p.lamU**2) > split_cfg['high_leakage'])
fm.wrap_dets('low_leakage', np.sqrt(proc_aman.t2p.lamQ**2 + proc_aman.t2p.lamU**2) <= split_cfg['high_leakage'])
split_aman.wrap('leakage_avg', np.nanmean(np.sqrt(proc_aman.t2p.lamQ**2 + proc_aman.t2p.lamU**2)),
if 'AQ' in proc_aman.t2p:
leak_fldQ = 'lamQ'
leak_fldU = 'lamU'
elif 'coeffsQ' in proc_aman.t2p:
leak_fldQ = 'coeffsQ'
leak_fldU = 'coeffsU'
else:
raise ValueError('no leakage coefficients found in axis manager')
fm.wrap_dets('high_leakage', np.sqrt(proc_aman.t2p[leak_fldQ]**2 + proc_aman.t2p[leak_fldU]**2) > split_cfg['high_leakage'])
fm.wrap_dets('low_leakage', np.sqrt(proc_aman.t2p[leak_fldQ]**2 + proc_aman.t2p[leak_fldU]**2) <= split_cfg['high_leakage'])
split_aman.wrap('leakage_avg', np.nanmean(np.sqrt(proc_aman.t2p[leak_fldQ]**2 + proc_aman.t2p[leak_fldU]**2)),
[(0, 'dets')])
if 'hwpss_stats' in proc_aman:
# High 2f amplitude split
Expand Down
18 changes: 13 additions & 5 deletions sotodlib/preprocess/preprocess_util.py
Original file line number Diff line number Diff line change
Expand Up @@ -562,11 +562,19 @@ def multilayer_load_and_preprocess_sim(obs_id, configs_init, configs_proc,
pipe_proc = Pipeline(configs_proc["process_pipe"], logger=logger)

logger.info("Restricting detectors on all proc pipeline processes")
keep_all = np.ones(meta_proc.dets.count, dtype=bool)
for process in pipe_proc[:]:
keep = process.select(meta_proc, in_place=False)
if isinstance(keep, np.ndarray):
keep_all &= keep

if (
'valid_data' in meta_proc.preprocess and
isinstance(meta_proc.preprocess.valid_data, core.AxisManager)
):
keep_all = has_any_cuts(meta_proc.preprocess.valid_data.valid_data)
else:
keep_all = np.ones(meta_proc.dets.count, dtype=bool)
for process in pipe_proc[:]:
keep = process.select(meta_proc, in_place=False)
if isinstance(keep, np.ndarray):
keep_all &= keep

meta_proc.restrict("dets", meta_proc.dets.vals[keep_all])
meta_init.restrict('dets', meta_proc.dets.vals)
aman = context_init.get_obs(meta_proc, no_signal=True)
Expand Down
Loading