From 50dc9bd7e41a25401b53339bd49c52f6d246e3a4 Mon Sep 17 00:00:00 2001 From: tlatorre Date: Mon, 16 Nov 2020 11:43:40 -0600 Subject: add --run-list argument to chi2 and dm-search This commit updates the chi2 and dm-search scripts to add the ability to pass a run list on the comand line. --- utils/dm-search | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'utils/dm-search') diff --git a/utils/dm-search b/utils/dm-search index 17f107a..6c78d4e 100755 --- a/utils/dm-search +++ b/utils/dm-search @@ -481,6 +481,7 @@ if __name__ == '__main__': parser.add_argument("--walkers", type=int, default=100, help="number of walkers") parser.add_argument("--thin", type=int, default=10, help="number of steps to thin") parser.add_argument("--test", type=int, default=0, help="run tests to check discovery threshold") + parser.add_argument("--run-list", default=None, help="run list") args = parser.parse_args() setup_matplotlib(args.save) @@ -494,6 +495,10 @@ if __name__ == '__main__': evs.append(get_events(df.filename.values, merge_fits=True, nhit_thresh=args.nhit_thresh)) ev = pd.concat(evs) + if args.run_list is not None: + runs = np.genfromtxt(args.run_list) + ev = ev[ev.run.isin(runs)] + livetime = 0.0 livetime_pulse_gt = 0.0 for ev in evs: -- cgit