示例#1
0
#mainidqdir = config.get('general', 'idqdir') ### get the main directory where idq pipeline is going to be running.

ifo = config.get('general', 'ifo')

usertag = config.get('general', 'usertag')
if usertag:
    usertag = "_%s" % usertag

#========================
# which classifiers
#========================
### ensure we have a section for each classifier and fill out dictionary of options
classifiersD, mla, ovl = idq.config_to_classifiersD(config)

### get combiners information and add these to classifiersD
combinersD, referenced_classifiers = idq.config_to_combinersD(config)
for combiner, value in combinersD.items():
    classifiersD[combiner] = value

classifiers = sorted(classifiersD.keys())

#if mla:
#    ### reading parameters from config file needed for mla
#    auxmvc_coinc_window = config.getfloat('build_auxmvc_vectors','time-window')
#    auxmc_gw_signif_thr = config.getfloat('build_auxmvc_vectors','signif-threshold')
#    auxmvc_selected_channels = config.get('general','selected-channels')
#    auxmvc_unsafe_channels = config.get('general','unsafe-channels')

#========================
# realtime
#========================
config = ConfigParser.SafeConfigParser()
config.read(opts.config_file)

mainidqdir = config.get('general', 'idqdir') ### get the main directory where idq pipeline is going to be running.

usertag = config.get('general', 'usertag')

ifo = config.get('general', 'ifo')

#========================
# which classifiers
#========================
### ensure we have a section for each classifier and fill out dictionary of options
classifiersD, mla, ovl = idq.config_to_classifiersD( config )
combinersD, _ = idq.config_to_combinersD( config )
classifiers = sorted(classifiersD.keys() + combinersD.keys())

### check that all requested classifiers exist...
for classifier in opts.classifier:
    if classifier not in classifiers:
        logger.info('WARNING: %s not present in config file : %s. skipping...'%(classifier, opts.config_file))
        opts.classifier.remove(classifier)

opts.classifier = sorted(list(set(opts.classifier)))

### check that FAPthrs make sense
opts.FAPthr = [FAPthr for FAPthr in opts.FAPthr if (FAPthr >=0) and (FAPthr <= 1)]

opts.FAPthr = sorted(list(set(opts.FAPthr)))
#mainidqdir = config.get('general', 'idqdir') ### get the main directory where idq pipeline is going to be running.

ifo = config.get('general', 'ifo')

usertag = config.get('general', 'usertag')
if usertag:
    usertag = "_%s"%usertag

#========================
# which classifiers
#========================
### ensure we have a section for each classifier and fill out dictionary of options
classifiersD, mla, ovl = idq.config_to_classifiersD( config )

### get combiners information and add these to classifiersD
combinersD, referenced_classifiers = idq.config_to_combinersD( config )
for combiner, value in combinersD.items():
    classifiersD[combiner] = value

classifiers = sorted(classifiersD.keys())

#if mla:
#    ### reading parameters from config file needed for mla
#    auxmvc_coinc_window = config.getfloat('build_auxmvc_vectors','time-window')
#    auxmc_gw_signif_thr = config.getfloat('build_auxmvc_vectors','signif-threshold')
#    auxmvc_selected_channels = config.get('general','selected-channels')
#    auxmvc_unsafe_channels = config.get('general','unsafe-channels')

#========================
# realtime
#========================
config.read(opts.config_file)

mainidqdir = config.get(
    'general', 'idqdir'
)  ### get the main directory where idq pipeline is going to be running.

usertag = config.get('general', 'usertag')

ifo = config.get('general', 'ifo')

#========================
# which classifiers
#========================
### ensure we have a section for each classifier and fill out dictionary of options
classifiersD, mla, ovl = idq.config_to_classifiersD(config)
combinersD, _ = idq.config_to_combinersD(config)
classifiers = sorted(classifiersD.keys() + combinersD.keys())

### check that all requested classifiers exist...
for classifier in opts.classifier:
    if classifier not in classifiers:
        logger.info(
            'WARNING: %s not present in config file : %s. skipping...' %
            (classifier, opts.config_file))
        opts.classifier.remove(classifier)

opts.classifier = sorted(list(set(opts.classifier)))

### check that FAPthrs make sense
opts.FAPthr = [
    FAPthr for FAPthr in opts.FAPthr if (FAPthr >= 0) and (FAPthr <= 1)