Skip to content
Snippets Groups Projects
Commit e3cd7a97 authored by Brian Moe's avatar Brian Moe
Browse files

Accomodate new CWB data format.

parent f10e7cd2
No related branches found
No related tags found
No related merge requests found
......@@ -391,15 +391,6 @@ class Translator(object):
class CwbData(Translator):
event_type = "cWB"
CWB_IFO_MAP = {
'1' : 'L1',
'2' : 'H1',
'3' : 'H2',
'4' : 'G1',
'5' : 'T1',
'6' : 'V1',
'7' : 'A1',
}
def __init__(self, datafile, *args, **kwargs):
self.datafile = datafile
......@@ -479,9 +470,7 @@ class CwbData(Translator):
data['likelihood'] = rawdata.get('likelihood',[None])[0]
data['far'] = rawdata.get('far',[None])[0]
ifos = []
for ifo in rawdata.get('ifo',[]):
ifos.append(self.CWB_IFO_MAP[ifo])
ifos = rawdata.get('ifo',[])
ifos.sort()
data['instruments'] = ','.join(ifos)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment