Skip to content

Commit

Permalink
Fix comment bugs in gwastro#4635 (gwastro#4645)
Browse files Browse the repository at this point in the history
  • Loading branch information
titodalcanton authored and bhooshan-gadre committed Mar 4, 2024
1 parent aa1775b commit ecded4c
Showing 1 changed file with 12 additions and 10 deletions.
22 changes: 12 additions & 10 deletions bin/pycbc_live
Original file line number Diff line number Diff line change
Expand Up @@ -542,6 +542,9 @@ class LiveEventManager(object):
)
logging.info('Coincident candidate! Saving as %s', fname)

# Which IFOs were active?
live_ifos = [ifo for ifo in sld if 'snr_series' in sld[ifo]]

# Verbally explain some details not obvious from the other info
comment = (
'Trigger produced as a {} coincidence.<br />'
Expand All @@ -553,9 +556,9 @@ class LiveEventManager(object):
comment = comment.format(
ppdets(coinc_ifos),
args.ranking_statistic,
set(ifos) - self.skymap_only_ifos,
ppdets(followup_ifos),
ppdets(self.skymap_only_ifos)
ppdets(set(ifos) - self.skymap_only_ifos),
ppdets(live_ifos),
ppdets(set(live_ifos) & self.skymap_only_ifos)
)

ifar = coinc_results['foreground/ifar']
Expand All @@ -577,9 +580,6 @@ class LiveEventManager(object):
# even if not running it - do this before the thread so no
# data buffers move on in a possible interim period

# Which IFOs were active?
live_ifos = [ifo for ifo in sld if 'snr_series' in sld[ifo]]

# Tell SNR optimized event about p_terr
if hasattr(event, 'p_terr') and event.p_terr is not None:
coinc_results['p_terr'] = event.p_terr
Expand Down Expand Up @@ -648,6 +648,9 @@ class LiveEventManager(object):
)
logging.info('Single-detector candidate! Saving as %s', fname)

# Which IFOs were active?
live_ifos = [ifo for ifo in sld if 'snr_series' in sld[ifo]]

# Verbally explain some details not obvious from the other info
comment = (
'Trigger produced as a {0} single.<br />'
Expand All @@ -656,7 +659,9 @@ class LiveEventManager(object):
'Detectors used only for localization: {2}.'
)
comment = comment.format(
ifo, ppdets(followup_ifos), ppdets(self.skymap_only_ifos)
ifo,
ppdets(live_ifos),
ppdets(set(live_ifos) & self.skymap_only_ifos)
)

# Has a coinc event at this time been uploaded recently?
Expand Down Expand Up @@ -694,9 +699,6 @@ class LiveEventManager(object):
# where there is already a coinc
continue

# Which IFOs were active?
live_ifos = [ifo for ifo in sld if 'snr_series' in sld[ifo]]

# Tell SNR optimized event about p_terr
if hasattr(event, 'p_terr') and event.p_terr is not None:
single['p_terr'] = event.p_terr
Expand Down

0 comments on commit ecded4c

Please sign in to comment.