Skip to content

Commit

Permalink
switch to segments/{} use fully in combine_statmap
Browse files Browse the repository at this point in the history
  • Loading branch information
Marton Tapai committed Feb 25, 2019
1 parent 20b6b0e commit 2e3d335
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions bin/hdfcoinc/pycbc_multiifo_combine_statmap
Original file line number Diff line number Diff line change
Expand Up @@ -117,11 +117,11 @@ trials_factors = numpy.zeros_like(f['foreground/ifar'][:])
test_times = numpy.array([pycbc.events.mean_if_greater_than_zero(tc)[0]
for tc in zip(*clustered_times)])
# Iterate over different ifo combinations
for key in f:
for key in f['segments']:
if key.startswith('foreground') or key.startswith('background'):
continue
end_times = numpy.array(f['%s/segments/end' % key][:])
start_times = numpy.array(f['%s/segments/start' % key][:])
end_times = numpy.array(f['segments/%s/end' % key][:])
start_times = numpy.array(f['segments/%s/start' % key][:])
idx_within_segment = pycbc.events.indices_within_times(test_times, start_times, end_times)
trials_factors[idx_within_segment] += numpy.ones_like(idx_within_segment)

Expand Down

0 comments on commit 2e3d335

Please sign in to comment.