def __init__(self, chainDict): self.L2sequenceList = [] self.EFsequenceList = [] self.L2signatureList = [] self.EFsignatureList = [] self.TErenamingDict = [] self.chainPart = chainDict['chainParts'] self.chainL1Item = chainDict['L1item'] self.chainPartL1Item = self.chainPart['L1item'] self.chainCounter = chainDict['chainCounter'] self.L2Name = 'L2_' + self.chainPart['chainPartName'] self.EFName = 'EF_' + self.chainPart['chainPartName'] #self.mult = int(self.chainPart['multiplicity']) self.chainName = chainDict['chainName'] self.chainPartName = self.chainPart['chainPartName'] self.L2InputL1Item = self.chainPartL1Item or self.chainL1Item if self.L2InputL1Item: self.L2InputTE = '' # Actually configure chains self.createChains() L2EFChainDef.__init__(self, self.chainName, self.L2Name, self.chainCounter, self.chainL1Item, self.EFName, self.chainCounter, self.L2InputTE)
def __init__(self, chainDict): self.EFsequenceList = [] self.L2signatureList = [] self.EFsignatureList = [] self.TErenamingDict = [] self.chainPart = chainDict['chainParts'] self.chainL1Item = chainDict['L1item'] self.chainPartL1Item = self.chainPart['L1item'] self.chainCounter = chainDict['chainCounter'] self.L2Name = 'L2_' + self.chainPart['chainPartName'] self.EFName = 'EF_' + self.chainPart['chainPartName'] self.mult = int(self.chainPart['multiplicity']) self.chainName = chainDict['chainName'] self.chainPartName = self.chainPart['chainPartName'] self.L2InputL1Item = self.chainPartL1Item or self.chainL1Item if self.L2InputL1Item: self.L2InputTE = getInputTEfromL1Item(self.L2InputL1Item) else: self.L2InputTE = '' self.Flag = 'TriggerFlags.TestSlice.do%s()' % self.chainName self.setupTestChain() L2EFChainDef.__init__(self, self.chainName, self.L2Name, self.chainCounter, self.chainL1Item, self.EFName, self.chainCounter, self.L2InputTE)
def __init__(self, chainDict): self.L2sequenceList = [] self.EFsequenceList = [] self.L2signatureList = [] self.EFsignatureList = [] self.TErenamingDict = [] self.chainName = chainDict['chainName'] self.chainPart = chainDict['chainParts'] self.chainL1Item = chainDict['L1item'] self.chainCounter = chainDict['chainCounter'] self.L2Name = 'L2_' + self.chainPart['chainPartName'] self.EFName = 'EF_' + self.chainPart['chainPartName'] self.chainPartName = self.chainPart['chainPartName'] self.streamingInfo = self.chainPart['streamingInfo'] self.L2InputTE = self.chainL1Item newL1items = self.L2InputTE # sequence/signature/TErenaming self.L2sequenceList += [[ self.L2InputTE.replace("TAU", "HA"), [], 'L2_' ]] #self.L2signatureList += [[['L2_']]] self.TErenamingDict = { 'L2_': 'L2_Streamer_' + self.chainName, } L2EFChainDef.__init__(self, self.chainName, self.L2Name, self.chainCounter, newL1items, self.EFName, self.chainCounter, self.L2InputTE)
def __init__(self, chainDict): self.L2sequenceList = [] self.EFsequenceList = [] self.L2signatureList = [] self.EFsignatureList = [] self.TErenamingDict = [] # May as well give the methods easy access to all the input information self.chainDict = chainDict l1_item_name = chainDict['L1item'] self.l2_input_tes = '' ##MET is un-seeded chain_counter = chainDict['chainCounter'] self.chainPart = chainDict['chainParts'] l2_name = 'L2_' + self.chainPart['chainPartName'] ef_name = 'EF_' + self.chainPart['chainPartName'] self.mult = int(self.chainPart['multiplicity']) chainName = chainDict['chainName'] sig_id = self.chainPart['chainPartName'] self.sig_id_noMult = sig_id[1:] if self.mult > 1 else sig_id self.setup_xeXX() L2EFChainDef.__init__(self, chainName, l2_name, chain_counter, l1_item_name, ef_name, chain_counter, self.l2_input_tes)
def __init__(self, chainDict): self.L2sequenceList = [] self.EFsequenceList = [] self.L2signatureList = [] self.EFsignatureList = [] self.TErenamingDict = [] self.chainName = chainDict['chainName'] self.chainPart = chainDict['chainParts'] self.chainL1Item = chainDict['L1item'] self.chainCounter = chainDict['chainCounter'] self.L2Name = 'L2_' + self.chainPart['chainPartName'] self.EFName = 'EF_' + self.chainPart['chainPartName'] self.chainPartName = self.chainPart['chainPartName'] self.algType = self.chainPart['algType'] self.L2InputTE = self.chainL1Item newL1items = self.L2InputTE # sequence/signature/TErenaming from TrigGenericAlgs.TrigGenericAlgsConf import PESA__DummyUnseededAllTEAlgo from TrigHypoCommonTools.TrigHypoCommonToolsConf import L1InfoHypo self.dummyAlg = PESA__DummyUnseededAllTEAlgo("EF_DummyFEX_%s" % (self.algType)) self.dummyAlg.createRoIDescriptors = False self.dummyAlg.NumberOfOutputTEs = 1 self.hypoEB = L1InfoHypo("EF_Hypo_%s" % (self.algType)) if self.algType in l1_seeds: self.hypoEB.L1ItemNames = l1_seeds[self.algType] self.hypoEB.AlwaysPass = False self.hypoEB.InvertSelection = False self.hypoEB.InvertL1ItemNameSelection = False self.hypoEB.L1TriggerBitMask = 0 self.hypoEB.TriggerTypeBitMask = 0 self.hypoEB.UseBeforePrescaleBit = True self.EFsequenceList += [[ '', [self.dummyAlg, self.hypoEB], 'EF_eb' ]] self.EFsignatureList += [[['EF_eb']]] self.TErenamingDict = { 'EF_eb': 'EF_' + self.chainName, } else: log.error("No configuration exist for EB chain: %s" % (self.algType)) self.hypoEB.L1ItemNames = [] L2EFChainDef.__init__(self, self.chainName, self.L2Name, self.chainCounter, newL1items, self.EFName, self.chainCounter, self.L2InputTE)
def __init__(self, chainDict): self.L2sequenceList = [] self.EFsequenceList = [] self.L2signatureList = [] self.EFsignatureList = [] self.TErenamingDict = [] self.chainPart = chainDict['chainParts'] self.chainL1Item = chainDict['L1item'] self.chainPartL1Item = self.chainPart['L1item'] self.chainCounter = chainDict['chainCounter'] self.L2Name = 'L2_'+self.chainPart['chainPartName'] self.EFName = 'EF_'+self.chainPart['chainPartName'] self.mult = int(self.chainPart['multiplicity']) self.chainName = chainDict['chainName'] self.chainPartName = self.chainPart['chainPartName'] self.L2InputL1Item = self.chainPartL1Item or self.chainL1Item if self.L2InputL1Item: from TriggerMenu.menu.L1Seeds import getInputTEfromL1Item self.L2InputTE = getInputTEfromL1Item(self.L2InputL1Item) else: self.L2InputTE = '' self.Flag='TriggerFlags.CosmicSlice.do%s()' % self.chainName log.verbose('in L2EFChain_CosmicTemplate constructor for %s', self.chainName) #--------------------------------- # CHAIN DEFINITION SPECIFICATIONS #--------------------------------- if ('tilecalib' in self.chainPart['purpose']) \ & ('laser' in self.chainPart['addInfo']): self.setupCosmicTileCalibration() elif 'larps' in self.chainPart['purpose']: self.setupCosmicLArPreSNoise() elif 'larhec' in self.chainPart['purpose']: self.setupCosmicLArHECNoise() elif ('sct' in self.chainPart['purpose']): self.setupCosmicIDNoiseCalibration() elif ('id' in self.chainPart['purpose']): self.setupCosmicAllTeChains() else: log.error('Chain %s could not be assembled' % (self.chainPartName)) return False L2EFChainDef.__init__(self, self.chainName, self.L2Name, self.chainCounter, self.chainL1Item, self.EFName, self.chainCounter, self.L2InputTE)
def __init__(self, chainDict): self.L2sequenceList = [] self.EFsequenceList = [] self.L2signatureList = [] self.EFsignatureList = [] self.TErenamingDict = [] self.chainPart = chainDict['chainParts'] self.chainL1Item = chainDict['L1item'] self.chainPartL1Item = self.chainPart['L1item'] self.chainCounter = chainDict['chainCounter'] self.L2Name = 'L2_' + self.chainPart['chainPartName'] self.EFName = 'EF_' + self.chainPart['chainPartName'] #self.mult = int(self.chainPart['multiplicity']) self.chainName = chainDict['chainName'] self.chainPartName = self.chainPart['chainPartName'] #self.chainPartNameNoMult = self.chainPartName[1:] if self.mult > 1 else self.chainPartName self.L2InputTE = self.chainPartL1Item or self.chainL1Item # cut of L1_, _EMPTY,..., & multiplicity if self.L2InputTE is not '': self.L2InputTE = self.L2InputTE.replace("L1_", "") self.L2InputTE = self.L2InputTE.split("_")[0] self.L2InputTE = self.L2InputTE[1:] if self.L2InputTE[0].isdigit( ) else self.L2InputTE if "sptrk" in self.chainPart['recoAlg']: self.setup_mb_sptrk() elif "sp" in self.chainPart['recoAlg']: self.setup_mb_sptrk() elif "mbts" in self.chainPart['recoAlg']: self.setup_mb_mbts() elif "perf" in self.chainPart['recoAlg']: self.setup_mb_perf() elif "idperf" in self.chainPart['recoAlg']: self.setup_mb_idperf() elif "zdcperf" in self.chainPart['recoAlg']: self.setup_mb_zdcperf() elif "hmt" in self.chainPart['recoAlg']: self.setup_mb_hmt() elif "hmtperf" in self.chainPart['recoAlg']: self.setup_mb_hmtperf() elif "noalg" in self.chainPart['recoAlg']: self.setup_mb_noalg() L2EFChainDef.__init__(self, self.chainName, self.L2Name, self.chainCounter, self.chainL1Item, self.EFName, self.chainCounter, self.L2InputTE)
def __init__(self, chainDict, theHypos): self.L2sequenceList = [] self.EFsequenceList = [] self.L2signatureList = [] self.EFsignatureList = [] self.TErenamingDict = {} self.hypoProvider = theHypos self.chainPart = chainDict['chainParts'] #if chainDict['stream'] == ['Combined']: # self.chainL1Item = self.chainPart['L1item'] #else: # self.chainL1Item = chainDict['L1item'] if self.chainPart['L1item']: self.chainL1Item = self.chainPart['L1item'] else: self.chainL1Item = chainDict['L1item'] self.chainCounter = chainDict['chainCounter'] self.L2Name = 'L2_'+self.chainPart['chainPartName'] self.EFName = 'EF_'+self.chainPart['chainPartName'] self.chainName = chainDict['chainName'] self.chainPartName = self.chainPart['chainPartName'] self.L2InputTE = L1InputTE(self.chainL1Item) # Book-keeping for updating sequences self.currentItem = self.L2InputTE self.currentStep = 0 selection = self.chainPart['selection'] preselection = self.chainPart['preselection'] if 'r1' in selection or 'r1' in preselection: # Run-I set-up self.setup_tauChainRunOne() else: # Run-II set-up self.setup_tauChain() L2EFChainDef.__init__(self, self.chainName, self.L2Name, self.chainCounter, chainDict['L1item'], self.EFName, self.chainCounter, self.L2InputTE)
def __init__(self, chainDict): self.L2sequenceList = [] self.EFsequenceList = [] self.L2signatureList = [] self.EFsignatureList = [] self.TErenamingDict = [] self.chainPart = chainDict['chainParts'] self.chainL1Item = chainDict['L1item'] self.chainPartL1Item = self.chainPart['L1item'] self.chainCounter = chainDict['chainCounter'] self.L2Name = 'L2_'+self.chainPart['chainPartName'] self.EFName = 'EF_'+self.chainPart['chainPartName'] self.mult = int(self.chainPart['multiplicity']) self.chainName = chainDict['chainName'] self.chainPartName = self.chainPart['chainPartName'] self.chainPartNameNoMult = self.chainPartName[1:] if self.mult > 1 else self.chainPartName self.chainPartNameNoMult += "_"+self.chainL1Item self.L2InputTE = self.chainPartL1Item or self.chainL1Item # cut of L1_, _EMPTY,..., & multiplicity self.L2InputTE = self.L2InputTE.replace("L1_","") self.L2InputTE = self.L2InputTE.split("_")[0] self.L2InputTE = self.L2InputTE[1:] if self.L2InputTE[0].isdigit() else self.L2InputTE # eXXvh_ID type chains: if self.chainPart['trkInfo']=='idperf': #True:# self.chainPart['IDinfo'] \ #and not self.chainPart['isoInfo'] \ #and not self.chainPart['FSinfo'] \ #and not self.chainPart['recoAlg'] \ #and not self.chainPart['hypoInfo'] \ #and not self.chainPart['trkInfo'] \ #and not self.chainPart['reccalibInfo']: self.setup_eXXvh_idperf() elif self.chainPart['L2IDAlg']: self.setup_eXXvh_ID() else: self.setup_eXXvh_ID_run2() L2EFChainDef.__init__(self, self.chainName, self.L2Name, self.chainCounter, self.chainL1Item, self.EFName, self.chainCounter, self.L2InputTE)
def __init__(self, chainDict): self.L2sequenceList = [] self.EFsequenceList = [] self.L2signatureList = [] self.EFsignatureList = [] self.TErenamingDict = [] self.chainPart = chainDict['chainParts'] self.chainL1Item = chainDict['L1item'] self.chainPartL1Item = self.chainPart['L1item'] self.chainCounter = chainDict['chainCounter'] self.L2Name = 'L2_' + self.chainPart['chainPartName'] self.EFName = 'EF_' + self.chainPart['chainPartName'] #self.mult = int(self.chainPart['multiplicity']) self.chainName = chainDict['chainName'] self.chainPartName = self.chainPart['chainPartName'] #self.chainPartNameNoMult = self.chainPartName[1:] if self.mult > 1 else self.chainPartName self.L2InputTE = self.chainPartL1Item or self.chainL1Item # cut of L1_, _EMPTY,..., & multiplicity if self.L2InputTE is not '': self.L2InputTE = self.L2InputTE.replace("L1_", "") self.L2InputTE = self.L2InputTE.split("_")[0] self.L2InputTE = self.L2InputTE[1:] if self.L2InputTE[0].isdigit( ) else self.L2InputTE if "v2" in self.chainPart['eventShape']: self.setup_hi_eventshape() elif "v3" in self.chainPart['eventShape']: self.setup_hi_eventshape() elif "ucc" in self.chainPart['recoAlg']: self.setup_hi_ultracentral() elif "upc" in self.chainPart['recoAlg']: if '' == self.chainPart['gap']: self.setup_hi_ultraperipheral() else: self.setup_hi_ultraperipheral_gap() L2EFChainDef.__init__(self, self.chainName, self.L2Name, self.chainCounter, self.chainL1Item, self.EFName, self.chainCounter, self.L2InputTE)
def __init__(self, chainDict): self.L2sequenceList = [] self.EFsequenceList = [] self.L2signatureList = [] self.EFsignatureList = [] self.TErenamingDict = [] self.chainName = chainDict['chainName'] self.chainPart = chainDict['chainParts'] self.chainL1Item = chainDict['L1item'] self.chainCounter = chainDict['chainCounter'] self.L2Name = 'L2_' + self.chainPart['chainPartName'] self.EFName = 'EF_' + self.chainPart['chainPartName'] self.monType = self.chainPart['monType'] self.L2InputTE = self.chainL1Item if ('robrequest' in self.monType): self.setupROBRequestMonChains() elif 'mistimemon' in self.chainName: # ('mistimemonl1bccorr' in self.monType or 'mistimemonl1bccorrnomu' in self.monType or 'mistimemoncaltimenomu' in self.monType or 'mistimemoncaltime' in self.monType): self.setupL1BCCorrMonChains(self.chainName) elif ('timeburner' in self.monType): self.setupTimeBurnerChain() elif ('idmon' in self.monType): self.setupIdmonTrkFS() elif ('costmonitor' in self.monType): self.setupCostMonChain() elif ('cscmon' in self.monType): self.setupCSCMonChain() elif ('l1calooverflow' in self.monType): self.setupL1CaloOverflow() elif ('l1topodebug' in self.monType): self.setupL1TopoTransmission() else: log.error("No suitable configuration for chain %s found!" % self.chainName) L2EFChainDef.__init__(self, self.chainName, self.L2Name, self.chainCounter, self.L2InputTE, self.EFName, self.chainCounter, self.L2InputTE)
def __init__(self, chainDict, theHypos): self.L2sequenceList = [] self.EFsequenceList = [] self.L2signatureList = [] self.EFsignatureList = [] self.TErenamingDict = {} self.hypoProvider = theHypos self.chainPart = chainDict['chainParts'] #if chainDict['stream'] == ['Combined']: # self.chainL1Item = self.chainPart['L1item'] #else: # self.chainL1Item = chainDict['L1item'] if self.chainPart['L1item']: self.chainL1Item = self.chainPart['L1item'] else: self.chainL1Item = chainDict['L1item'] self.chainCounter = chainDict['chainCounter'] self.L2Name = 'L2_'+self.chainPart['chainPartName'] self.EFName = 'EF_'+self.chainPart['chainPartName'] self.chainName = chainDict['chainName'] self.chainPartName = self.chainPart['chainPartName'] self.L2InputTE = L1InputTE(self.chainL1Item) # Book-keeping for updating sequences self.currentItem = self.L2InputTE self.currentStep = 0 self.setup_tauChain() L2EFChainDef.__init__(self, self.chainName, self.L2Name, self.chainCounter, chainDict['L1item'], self.EFName, self.chainCounter, self.L2InputTE)
def __init__(self, chainDict): self.L2sequenceList = [] self.EFsequenceList = [] self.L2signatureList = [] self.EFsignatureList = [] self.TErenamingDict = [] l1_item_name = chainDict['L1item'] self.l2_input_tes = '' ##MET is un-seeded chain_counter = chainDict['chainCounter'] self.chainPart = chainDict['chainParts'] l2_name = 'L2_'+self.chainPart['chainPartName'] ef_name = 'EF_'+self.chainPart['chainPartName'] self.mult = int(self.chainPart['multiplicity']) chainName = chainDict['chainName'] sig_id = self.chainPart['chainPartName'] self.sig_id_noMult = sig_id[1:] if self.mult > 1 else sig_id self.setup_xeXX() L2EFChainDef.__init__(self, chainName, l2_name, chain_counter, l1_item_name, ef_name, chain_counter, self.l2_input_tes)
def __init__(self, chainDict): self.L2sequenceList = [] self.EFsequenceList = [] self.L2signatureList = [] self.EFsignatureList = [] self.TErenamingDict = [] self.chainPart = chainDict['chainParts'] self.chainL1Item = chainDict['L1item'] self.chainPartL1Item = self.chainPart['L1item'] self.chainCounter = chainDict['chainCounter'] self.L2Name = 'L2_' + self.chainPart['chainPartName'] self.EFName = 'EF_' + self.chainPart['chainPartName'] self.chainName = chainDict['chainName'] self.chainPartName = self.chainPart['chainPartName'] self.L2InputL1Item = self.chainPartL1Item or self.chainL1Item self.hypo = self.chainPart['hypo'] self.location = self.chainPart['location'] self.addInfo = self.chainPart['addInfo'] self.l2IDAlg = self.chainPart['l2IDAlg'] self.eventBuildType = self.chainPart['eventBuildType'] self.L2InputTE = self.chainPartL1Item or self.chainL1Item self.L2InputTE = self.L2InputTE.replace("L1_", "") if ('trkFS' in self.chainPart['addInfo']) \ or ('activeTE' in self.chainPart['addInfo'] )\ or ('allTE' in self.chainPart['addInfo'] )\ or ('idperf' in self.chainPart['addInfo'] ): self.setupBeamspotChains() else: mlog.error( 'Cannot assemble chain %s - not the right info provided!' % (self.chainPartName)) L2EFChainDef.__init__(self, self.chainName, self.L2Name, self.chainCounter, self.chainL1Item, self.EFName, self.chainCounter, self.L2InputTE)
def __init__(self, chainDict): #self.HLTsequenceList = [] #self.HLTsignatureList = [] self.L2sequenceList = [] self.L2signatureList = [] self.EFsequenceList = [] self.EFsignatureList = [] self.TErenamingDict = [] self.chainPart = chainDict['chainParts'][0] self.chainL1Item = chainDict['L1item'] self.chainPartL1Item = self.chainPart['L1item'] self.chainCounter = chainDict['chainCounter'] self.L2Name = 'L2_'+self.chainPart['chainPartName'] self.EFName = 'EF_'+self.chainPart['chainPartName'] self.mult = int(self.chainPart['multiplicity']) self.chainName = chainDict['chainName'] self.chainPartName = self.chainPart['chainPartName'] self.chainPartNameNoMult = self.chainPartName[1:] if self.mult > 1 else self.chainPartName self.L2InputTE = self.chainPartL1Item or self.chainL1Item # cut of L1_, _EMPTY,..., & multiplicity self.L2InputTE = self.L2InputTE.replace("L1_","") self.L2InputTE = self.L2InputTE.split("_")[0] self.L2InputTE = self.L2InputTE[1:] if self.L2InputTE[0].isdigit() else self.L2InputTE #if (): self.setup_htXX() #else: # logJetHTDef.error('Chain %s could not be assembled' % (self.chainPartName)) # return False L2EFChainDef.__init__(self, self.chainName, self.L2Name, self.chainCounter, self.chainL1Item, self.EFName, self.chainCounter, self.L2InputTE)
def __init__(self, chainDict): self.L2sequenceList = [] self.EFsequenceList = [] self.L2signatureList = [] self.EFsignatureList = [] self.TErenamingDict = [] self.chainDict = chainDict self.chainPart = chainDict['chainParts'] self.chainL1Item = chainDict['L1item'] self.chainPartL1Item = self.chainPart['L1item'] self.chainCounter = chainDict['chainCounter'] self.L2Name = 'L2_'+self.chainPart['chainPartName'] self.EFName = 'EF_'+self.chainPart['chainPartName'] self.chainName = chainDict['chainName'] self.chainPartName = self.chainPart['chainPartName'] self.L2InputL1Item = self.chainPartL1Item or self.chainL1Item self.hypo = self.chainPart['hypo'] self.location = self.chainPart['location'] self.mult = int(self.chainPart['multiplicity']) self.chainPartNameNoMult = self.chainPartName[1:] if self.mult > 1 else self.chainPartName self.signatureCounterOffset = 0 self.L2InputTE = self.chainPartL1Item or self.chainL1Item if self.L2InputL1Item: self.L2InputTE = getInputTEfromL1Item(self.L2InputL1Item) else: self.L2InputTE = '' #if len(self.L2InputTE)>0: # self.L2InputTE = self.L2InputTE.replace("L1_","") # self.L2InputTE = self.L2InputTE.split("_")[0] # self.L2InputTE = self.L2InputTE[1:] if self.L2InputTE[0].isdigit() else self.L2InputTE #roi1 = 'HA8' if 'idcalib' in self.chainPart['purpose']: if 'HI_' not in TriggerFlags.triggerMenuSetup(): roi1 = 'HA8' #log.info('Using '+roi1+' as ROI for calibtrk chains, triggered by non-HI menuname) self.L2InputTE = roi1 self.setupTrkCalibChains() elif 'ibllumi' in self.chainPart['purpose']: self.setupIBLLumiChains() elif ('larcalib' in self.chainPart['purpose']) or ('tilelarcalib' in self.chainPart['purpose']): self.setupLArROBListWWriterLvl1Chain() elif 'l1calocalib' in self.chainPart['purpose']: self.L2InputTE = self.L2InputL1Item self.setupL1CaloCalibrationChains() elif 'alfacalib' in self.chainPart['purpose']: self.setupL1ALFACalibrationChains() elif 'larnoiseburst' in self.chainPart['purpose']: self.setupLarNoiseBurstChains() elif 'lumipeb' in self.chainPart['purpose']: self.setupLumiPEBChains() elif 'lhcfpeb' in self.chainPart['purpose']: self.setupLHCfChains() elif 'alfaidpeb' in self.chainPart['purpose']: self.setupALFAIDChains() elif 'l1satmon' in self.chainPart['purpose']: self.setupL1SaturatedMon() elif 'zdcpeb' in self.chainPart['purpose']: self.setupZDCPEBChains() elif 'calibAFP' in self.chainPart['purpose']: self.setupAFPCalibrationChains() else: log.error('Chain %s could not be assembled' % (self.chainPartName)) return False L2EFChainDef.__init__(self, self.chainName, self.L2Name, self.chainCounter, self.chainL1Item, self.EFName, self.chainCounter, self.L2InputTE, signatureCounterOffset=self.signatureCounterOffset)
def __init__(self, chainDict, seqObj): self.L2sequenceList = [] self.EFsequenceList = [] self.L2signatureList = [] self.EFsignatureList = [] self.TErenamingDict = {} self.chainPart = chainDict['chainParts'] self.seqObj = seqObj self.el_sequences = seqObj.get_sequences() self.chainL1Item = chainDict['L1item'] self.chainPartL1Item = self.chainPart['L1item'] self.chainCounter = chainDict['chainCounter'] self.L2Name = 'L2_' + self.chainPart['chainPartName'] self.EFName = 'EF_' + self.chainPart['chainPartName'] self.mult = int(self.chainPart['multiplicity']) self.chainName = chainDict['chainName'] self.chainPartName = self.chainPart['chainPartName'] self.chainPartNameNoMult = self.chainPartName[ 1:] if self.mult > 1 else self.chainPartName self.chainPartNameNoMult += "_" + self.chainL1Item self.L2InputTE = self.chainPartL1Item or self.chainL1Item # cut of L1_, _EMPTY,..., & multiplicity self.L2InputTE = self.L2InputTE.replace("L1_", "") if 'AFP' in self.L2InputTE: self.L2InputTE = self.L2InputTE.replace("AFP_C_", "") self.L2InputTE = self.L2InputTE.split("_")[0] self.L2InputTE = self.L2InputTE[1:] if self.L2InputTE[0].isdigit( ) else self.L2InputTE self.use_v7 = False self._ringer_selection = False self.setRingerSelection() #if TriggerFlags.run2Config() == '2017': if '_v7' in TriggerFlags.triggerMenuSetup(): self.use_v7 = True self.doCaloIsolation = False for item in self.chainPart['isoInfo']: if 'icalo' in item: self.doCaloIsolation = True # eXXvh_ID type chains: if self.use_v7: self.setup_electron() elif self.chainPart[ 'trkInfo'] == 'idperf': #True:# self.chainPart['IDinfo'] \ if 'ion' in self.chainPart['extra']: self.setup_eXXvh_idperf_heavyIon() else: self.setup_eXXvh_idperf() elif 'ringer' in self.chainPart['addInfo']: self.setup_eXXvh_ID_ringer() else: if 'ion' in self.chainPart['extra']: self.setup_eXXvh_ID_run2_heavyIon() else: self.setup_eXXvh_ID_run2() L2EFChainDef.__init__(self, self.chainName, self.L2Name, self.chainCounter, self.chainL1Item, self.EFName, self.chainCounter, self.L2InputTE)
def __init__(self, chainDict, seqObj): self.L2sequenceList = [] self.EFsequenceList = [] self.L2signatureList = [] self.EFsignatureList = [] self.TErenamingDict = {} self.chainPart = chainDict['chainParts'] self.seqObj = seqObj self.ph_sequences = seqObj.get_sequences() self.chainL1Item = chainDict['L1item'] self.chainPartL1Item = self.chainPart['L1item'] self.chainCounter = chainDict['chainCounter'] self.L2Name = 'L2_' + self.chainPart['chainPartName'] self.EFName = 'EF_' + self.chainPart['chainPartName'] self.mult = int(self.chainPart['multiplicity']) self.chainName = chainDict['chainName'] self.chainPartName = self.chainPart['chainPartName'] self.chainPartNameNoMult = self.chainPartName[ 1:] if self.mult > 1 else self.chainPartName self.chainPartNameNoMult += "_" + self.chainL1Item self.L2InputTE = self.chainPartL1Item or self.chainL1Item # cut of L1_, _EMPTY,..., & multiplicity self.L2InputTE = self.L2InputTE.replace("L1_", "") if 'AFP' in self.L2InputTE: self.L2InputTE = self.L2InputTE.replace("AFP_C_", "") self.L2InputTE = self.L2InputTE.split("_")[0] self.L2InputTE = self.L2InputTE[1:] if self.L2InputTE[0].isdigit( ) else self.L2InputTE self.use_v7 = False #if TriggerFlags.run2Config()=='2017': if '_v7' in TriggerFlags.triggerMenuSetup(): self.use_v7 = True self.doIsolation = False caloiso = [x for x in self.chainPart['isoInfo'] if 'icalo' in x] if len(caloiso) > 0: self.doIsolation = True log.debug('Sequences %s ', self.ph_sequences) # gXX_ID type chains: if "hiptrt" in self.chainPart['addInfo']: self.setup_gnocut_hiptrt() elif self.use_v7: self.setup_photon() else: if 'ringer' in self.chainPart['addInfo']: self.setup_gXX_ID_ringer() elif self.doIsolation: self.setup_gXX_ID_iso() else: if 'ion' in self.chainPart['extra']: self.setup_gXX_ID_heavyIon() else: self.setup_gXX_ID() #else: # log.error('Chain %s could not be assembled' % (self.chainPartName)) # return False L2EFChainDef.__init__(self, self.chainName, self.L2Name, self.chainCounter, self.chainL1Item, self.EFName, self.chainCounter, self.L2InputTE)
def __init__(self, chainDict, asymDiMuonChain=False): self.L2sequenceList = [] self.EFsequenceList = [] self.L2signatureList = [] self.EFsignatureList = [] self.TErenamingDict = [] self.chainName = chainDict['chainName'] self.chainL1Item = chainDict['L1item'] self.chainCounter = chainDict['chainCounter'] self.chainPart = chainDict['chainParts'] self.chainPartL1Item = self.chainPart['L1item'] self.L2Name = 'L2_' + self.chainPart['chainPartName'] self.EFName = 'EF_' + self.chainPart['chainPartName'] self.mult = int(self.chainPart['multiplicity']) self.chainPartName = self.chainPart['chainPartName'] self.chainPartNameNoMult = self.chainPartName[ 1:] if self.mult > 1 else self.chainPartName self.L2InputTE = self.chainPartL1Item or self.chainL1Item if self.L2InputTE: # cut of L1_, _EMPTY,..., & multiplicity self.L2InputTE = self.L2InputTE.replace("L1_", "") self.L2InputTE = self.L2InputTE.split("_")[0] self.L2InputTE = self.L2InputTE[1:] if self.L2InputTE[0].isdigit( ) else self.L2InputTE # --- when to run with ovlp removal --- self.ovlpRm = self.chainPart['overlapRemoval'] self.asymDiMuonChain = asymDiMuonChain self.doOvlpRm = False if (self.mult > 1) & ('wOvlpRm' in self.ovlpRm): self.doOvlpRm = True elif (self.asymDiMuonChain) and (self.mult > 1) and not self.chainPart[ 'extra'] and not self.chainPart['reccalibInfo']: self.doOvlpRm = True else: self.doOvlpRm = False # --- call corresponding functions to set up chains --- if not self.chainPart['extra'] \ and not self.chainPart['FSinfo'] \ and not self.chainPart['hypoInfo'] \ and not self.chainPart['reccalibInfo']: self.setup_muXX_ID() elif self.chainPart['extra']: self.setup_muXX_noL1() elif self.chainPart['reccalibInfo'] == "idperf": self.setup_muXX_idperf() elif self.chainPart['reccalibInfo'] == "msonly": self.setup_muXX_MSOnly() else: logMuonDef.error('Chain %s could not be assembled' % (self.chainPartName)) return False L2EFChainDef.__init__(self, self.chainName, self.L2Name, self.chainCounter, self.chainL1Item, self.EFName, self.chainCounter, self.L2InputTE)