def setup_eXXvh_ID_run2_heavyIon(self): precisecalocalib = self.el_sequences['precisecalocalib'] precisecalocalib.insert(1, theElectronUEMonitoring) seq_dict = self.el_sequences seq_dict['precisecalocalib'] = precisecalocalib seq_te_dict = collections.OrderedDict() seq_te_dict['fastcalo'] = ('L2_e_step1', 'cl') seq_te_dict['fasttrack'] = ('L2_e_step2', 'id') seq_te_dict['fastrec'] = ('L2_e_step3', '') seq_te_dict['precisecalo'] = ('EF_e_step1', 'calo') seq_te_dict['precisecalocalib'] = ('EF_e_step2', 'calocalib') seq_te_dict['precisetrack'] = ('EF_e_step3', 'id') seq_te_dict['preciserec'] = ('EF_e_step4', '') # First set the normal sequence self.setupFromDict(seq_te_dict, seq_dict) # Now insert additional steps self.EFsequenceList.insert( 0, [['L2_e_step3'], [theFSCellMaker], 'EF_e_step1_fs']) self.EFsequenceList.insert( 1, [['EF_e_step1_fs'], [theUEMaker], 'EF_e_step1_ue']) self.EFsignatureList.insert(0, [['EF_e_step1_fs']]) self.EFsignatureList.insert(1, [['EF_e_step1_ue']]) self.TErenamingDict['EF_e_step1_fs'] = mergeRemovingOverlap( 'EF_', self.chainPartNameNoMult + 'fs') self.TErenamingDict['EF_e_step1_ue'] = mergeRemovingOverlap( 'EF_', self.chainPartNameNoMult + 'ue')
def setupLArROBListWWriterLvl1Chain(self): self.L2sequenceList += [[ self.L2InputTE, [LArL2ROBListWriter('LArL2ROBListWriter_' + self.chainName, addCTPResult = True, addL2Result = True), L1CaloTileHackL2ROBListWriter('L1CaloTileHackL2ROBListWriter_' + self.chainName)], 'L2_step1']] if ('larcalib' in self.chainName): self.L2sequenceList += [[ ['L2_step1'], [CSCSubDetListWriter('CSCSubDetListWriter_' + self.chainName)], 'L2_step2']] Tespecifier='CSCsubdetlistwriter' elif ('tilelarcalib' in self.chainName): from TrigDetCalib.TrigDetCalibConfig import TileSubDetListWriter self.l2_tileSubDetListWriter = TileSubDetListWriter("L2_Cosmic_"+self.chainName+"_TileSubDetListWriter") self.l2_tileSubDetListWriter.Subdetectors = "Tile" self.l2_tileSubDetListWriter.MaxRoIsPerEvent = 1 self.l2_tileSubDetListWriter.addL1Calo = True self.L2sequenceList += [[ ['L2_step1'], [self.l2_tileSubDetListWriter], 'L2_step2']] Tespecifier='Tilesubdetlistwriter' else: log.error('Cannot find the right sequence for this chain.') Tespecifier='' self.L2signatureList += [ [['L2_step1']] ] self.L2signatureList += [ [['L2_step2']] ] self.TErenamingDict = { 'L2_step1': mergeRemovingOverlap('L2_', 'Cosmic_'+self.chainName), 'L2_step2': mergeRemovingOverlap('L2_', 'Cosmic_'+self.chainName+Tespecifier), }
def setup_mb_zdcperf(self): ########## L2 algos ################## if "zdcperf" in self.chainPart['recoAlg']: if "lg" in self.chainPart['ZDCinfo']: chainSuffix = "lg_zdcperf" theL2Fex1 = L2MbZdcFex_LG theL2Hypo1 = L2MbZdcHypo_PT elif "hg" in self.chainPart['ZDCinfo']: chainSuffix = "hg_zdcperf" theL2Fex1 = L2MbZdcFex_HG theL2Hypo1 = L2MbZdcHypo_PT ########## EF algos ################## ########### Sequence List ############## self.L2sequenceList += [["", [dummyRoI], 'L2_mb_step0']] self.L2sequenceList += [[['L2_mb_step0'], [theL2Fex1, theL2Hypo1], 'L2_mb_step1']] ########### Signatures ########### self.L2signatureList += [[['L2_mb_step0']]] self.L2signatureList += [[['L2_mb_step1']]] self.TErenamingDict = { 'L2_mb_step0': mergeRemovingOverlap('L2_', 'dummyroi_' + chainSuffix), 'L2_mb_step1': mergeRemovingOverlap('L2_', 'zdc_' + chainSuffix), }
def setup_mb_idperf(self): doHeavyIon = False if 'ion' in self.chainPart['extra']: doHeavyIon = True ########## EF algos ################## if "idperf" in self.chainPart['recoAlg']: chainSuffix = "idperf" if not doHeavyIon: theEFFex1 = efid else: theEFFex1 = efid_heavyIon ########### Sequence List ############## self.L2sequenceList += [["", [dummyRoI], 'L2_mb_step0']] self.EFsequenceList += [[['L2_mb_step0'], theEFFex1, 'EF_mb_step1']] ########### Signatures ########### self.L2signatureList += [[['L2_mb_step0']]] self.EFsignatureList += [[['EF_mb_step1']]] self.TErenamingDict = { 'L2_mb_step0': mergeRemovingOverlap('L2_', chainSuffix), 'EF_mb_step1': mergeRemovingOverlap('EF_', chainSuffix), }
def setupCosmicLArHECNoise(self): from TrigDetCalib.TrigDetCalibConfig import EtaHypo_HEC, LArL2ROBListWriter self.L2sequenceList += [[ self.L2InputTE, [ EtaHypo_HEC('EtaHypo_HEC_' + self.chainPartName), ], 'L2_step1' ]] self.L2sequenceList += [[ 'L2_step1', [ LArL2ROBListWriter('LArL2ROBListWriter_' + self.chainName, addCTPResult=True, addL2Result=True, etaWidth=0.2, phiWidth=0.2), ], 'L2_step2' ]] self.L2signatureList += [[['L2_step1'] * self.mult]] self.L2signatureList += [[['L2_step2'] * self.mult]] self.TErenamingDict = { 'L2_step1': mergeRemovingOverlap('L2_', 'EtaHypo_HEC_' + self.chainName), 'L2_step2': mergeRemovingOverlap('L2_', 'LArL2ROBListWriter_' + self.chainName), }
def setupLarNoiseBurstChains(self): fullScanSeqMap = getFullScanCaloSequences() from TrigCaloHypo.TrigCaloHypoConfig import EFCaloHypoNoiseConfig if "loose" in self.chainPart['addInfo']: theCaloHypo = EFCaloHypoNoiseConfig("EFCaloHypoNoiseConfigLoose") theCaloHypo.NoiseTool.BadChanPerFEB=1 theCaloHypo.NoiseTool.CellQualityCut=100 else: theCaloHypo = EFCaloHypoNoiseConfig() self.EFsequenceList += [['',fullScanSeqMap['EF_full'],'EF_full']] self.EFsequenceList += [[['EF_full'],fullScanSeqMap['EF_full_cell'],'EF_full_cell']] self.EFsequenceList += [[['EF_full_cell'],[theCaloHypo], 'jet_hypo']] self.L2signatureList += [ [['EF_full']] ] self.EFsignatureList += [ [['EF_full_cell']] ] self.EFsignatureList += [ [['jet_hypo']] ] antiktsize = 0 suffix = "_loose" if "loose" in self.chainPart['addInfo'] else "" self.TErenamingDict = { 'EF_full_cell' : mergeRemovingOverlap('HLT_full__cluster__', 'jr_antikt'+str(antiktsize)+'tc_had' ), 'jet_hypo' : mergeRemovingOverlap('HLT_full__cluster__', 'jr_antikt'+str(antiktsize)+'tc_had_noiseHypo'+suffix ), }
def setupCosmicTileCalibration(self): # Configuration from TrigDetCalib.TrigDetCalibConfig import TileSubDetListWriter self.l2_tileSubDetListWriter = TileSubDetListWriter("L2_Cosmic"+self.chainName+"TileSubDetListWriter") self.l2_tileSubDetListWriter.Subdetectors = "Tile" self.l2_tileSubDetListWriter.MaxRoIsPerEvent = 1 self.l2_tileSubDetListWriter.addL1Calo = True from TrigGenericAlgs.TrigGenericAlgsConf import DummyFEX self.EF_Dummy = DummyFEX("EF_%s" % self.chainName) # Sequences self.L2sequenceList += [[ self.L2InputTE, [self.l2_tileSubDetListWriter], 'L2_step1']] self.EFsequenceList += [[ ['L2_step1'], [self.EF_Dummy], 'EF_step1']] # Signatures self.L2signatureList += [ [['L2_step1']*self.mult] ] self.EFsignatureList += [ [['EF_step1']*self.mult] ] # TE renaming self.TErenamingDict = { 'L2_step1': mergeRemovingOverlap('L2_', 'Cosmic_'+self.chainName+'_TileSubDetListWriter'), 'EF_step1': mergeRemovingOverlap('EF_', self.chainName), }
def setup_hi_ultraperipheral(self): theL2MbtsFex = L2MbMbtsFex theL2MbtsHypo = MbMbtsHypo("L2MbMbtsHypo_1_1_inn_veto") theL2PixelFex = L2MbSpFex if 'loose' in self.chainPart['hypoL2Info']: minPixel = 6 maxPixel = 40 chainSuffix = 'loose_upc' if 'medium' in self.chainPart['hypoL2Info']: minPixel = 6 maxPixel = 30 chainSuffix = 'medium_upc' if 'tight' in self.chainPart['hypoL2Info']: minPixel = 6 maxPixel = 25 chainSuffix = 'tight_upc' if 'gg' in self.chainPart['hypoL2Info']: minPixel = 0 maxPixel = 10 chainSuffix = 'gg_upc' theL2PixelHypo = L2MbSpUPC( "MbPixelSpUPC_min" + str(minPixel) + '_max' + str(maxPixel), minPixel, maxPixel) ########### Sequence List ############## self.L2sequenceList += [["", [dummyRoI], 'L2_hi_step1']] self.L2sequenceList += [[['L2_hi_step1'], [theL2MbtsFex, theL2MbtsHypo], 'L2_hi_mbtsveto']] self.L2sequenceList += [[ 'L2_hi_mbtsveto', efiddataprep, 'L2_hi_iddataprep' ]] self.L2sequenceList += [[['L2_hi_iddataprep'], [theL2PixelFex, theL2PixelHypo], 'L2_hi_pixel']] ########### Signatures ########### self.L2signatureList += [[['L2_hi_step1']]] self.L2signatureList += [[['L2_hi_mbtsveto']]] self.L2signatureList += [[['L2_hi_iddataprep']]] self.L2signatureList += [[['L2_hi_pixel']]] self.TErenamingDict = { 'L2_hi_step1': mergeRemovingOverlap('L2_hi_step1_', chainSuffix), 'L2_hi_mbtsveto': mergeRemovingOverlap('EF_hi_mbtsveto_', chainSuffix), 'L2_hi_iddataprep': mergeRemovingOverlap('EF_hi_iddataprep_', chainSuffix), 'L2_hi_pixel': mergeRemovingOverlap('EF_hi_pixel_', chainSuffix), }
def setup_htXX(self): #import and configuration of fexes and hypos from TrigGenericAlgs.TrigGenericAlgsConf import PESA__DummyUnseededAllTEAlgo as DummyAlgo theDummyRoiCreator = DummyAlgo('RoiCreator') #TrigCaloCellMaker/CellMakerFullCalo_topo from TrigCaloRec.TrigCaloRecConfig import TrigCaloCellMaker_jet_fullcalo theTrigCaloCellMaker_jet_fullcalo = TrigCaloCellMaker_jet_fullcalo("CellMakerFullCalo_topo", doNoise=0, AbsE=True, doPers=True) #TrigCaloClusterMaker/TrigCaloClusterMaker_topo_fullscan from TrigCaloRec.TrigCaloRecConfig import TrigCaloClusterMaker_topo theTrigCaloClusterMaker_topo = TrigCaloClusterMaker_topo('TrigCaloClusterMaker_topo_fullscan', doMoments=True, doLC=True) #TrigHLTJetRec/TrigHLTJetRec_AntiKt04 antiktsize = 0 if ('a4' in self.chainPart['recoAlg']): antiktsize = 4 from TrigHLTJetRec.TrigHLTJetRecConfig import TrigHLTJetRec_AntiKt04 theTrigHLTJetRec_AntiKt = TrigHLTJetRec_AntiKt04() elif ('a10' in self.chainPart['recoAlg'] ): antiktsize = 10 from TrigHLTJetRec.TrigHLTJetRecConfig import TrigHLTJetRec_AntiKt10 theTrigHLTJetRec_AntiKt = TrigHLTJetRec_AntiKt10() else: logJetHTDef.error("NO HLT JET REC ALG GIVEN") theTrigHLTJetRec_AntiKt = None #TrigEFHTHypo/EFHT_HAD_ht500 -> uses ET cut on jets of 45 GeV!! efht_thresh = self.chainPart['threshold'] from TrigJetHypo.TrigEFHTHypoConfig import EFHT_HAD theEFHThypo_ht = EFHT_HAD("EFHT_HAD_ht%s"%efht_thresh,HT_cut=int(efht_thresh)*GeV) # Adding sequences self.L2sequenceList += [['', [theDummyRoiCreator], 'EF_full']] self.L2sequenceList += [[['EF_full'], [theTrigCaloCellMaker_jet_fullcalo, theTrigCaloClusterMaker_topo ], 'EF_full_cluster']] self.L2sequenceList += [[['EF_full_cluster'], [theTrigHLTJetRec_AntiKt], 'AntiKt']] self.L2sequenceList += [[['AntiKt'],[theEFHThypo_ht], 'jet_hypo']] # Adding signatures self.L2signatureList += [ [['EF_full']] ] self.EFsignatureList += [ [['EF_full_cluster']] ] self.EFsignatureList += [ [['AntiKt']] ] self.EFsignatureList += [ [['jet_hypo']] ] # Renaming TE self.TErenamingDict = { 'AntiKt' : mergeRemovingOverlap('HLT_full__cluster__', 'jr_antikt'+str(antiktsize)+'tc_had' ), 'jet_hypo' : mergeRemovingOverlap('HLT_full__cluster__', 'jr_antikt'+str(antiktsize)+'tc_had_ht'+efht_thresh ), }
def setupBeamspotChains(self): if 'peb'== self.eventBuildType: from TrigDetCalib.TrigDetCalibConfig import TrigSubDetListWriter robListWriter = TrigSubDetListWriter('IDSubDetListWriter') robListWriter.SubdetId = [ "SiOnly","TDAQ_CTP" ] robListWriter.addL1Calo = False theAlg = robListWriter elif 'pebTRT'== self.eventBuildType: from TrigDetCalib.TrigDetCalibConfig import TrigSubDetListWriter robListWriter = TrigSubDetListWriter('IDTRTSubDetListWriter') # robListWriter.SubdetId = [ "SiOnly","TDAQ_CTP","TRT" ] robListWriter.SubdetId = [ "InnerDetector","TDAQ_CTP" ] robListWriter.addL1Calo = False theAlg = robListWriter else: from TrigGenericAlgs.TrigGenericAlgsConf import PrescaleAlgo theAlg = PrescaleAlgo("terminateAlgo") if 'trkFS' in self.chainPart['addInfo'] : from TrigT2BeamSpot.T2VertexBeamSpotConfig import T2VertexBeamSpot_FTF theFex = T2VertexBeamSpot_FTF() elif 'activeTE' in self.chainPart['addInfo']: from TrigT2BeamSpot.T2VertexBeamSpotConfig import T2VertexBeamSpot_activeTE_FTF theFex = T2VertexBeamSpot_activeTE_FTF() elif 'allTE' in self.chainPart['addInfo']: from TrigT2BeamSpot.T2VertexBeamSpotConfig import T2VertexBeamSpot_activeAllTE_FTF theFex = T2VertexBeamSpot_activeAllTE_FTF() else: mlog.error('Cannot assemble chain %s - only configured for trkFS,allTE and activeTE' % (self.chainPartName)) from TrigInDetConf.TrigInDetSequence import TrigInDetSequence [trk_alg] = TrigInDetSequence("BeamSpot", "beamSpot", "IDTrig", sequenceFlavour=["FTF"]).getSequence() from TrigGenericAlgs.TrigGenericAlgsConf import PESA__DummyUnseededAllTEAlgo self.L2sequenceList += [ [[""], [PESA__DummyUnseededAllTEAlgo("L2DummyAlgo")]+trk_alg, 'L2_BeamSpottracks']] self.L2sequenceList +=[[['L2_BeamSpottracks'], [theFex], 'L2_fex']] self.L2sequenceList +=[[['L2_fex'], [theAlg], 'L2_']] self.L2signatureList += [ [['L2_BeamSpottracks']] ] self.L2signatureList += [ [['L2_fex']] ] self.L2signatureList += [ [['L2_']] ] self.TErenamingDict = { 'L2_fex' : mergeRemovingOverlap('L2_', self.chainName+'_fex'), 'L2_' : mergeRemovingOverlap('L2_', self.chainName), 'L2_BeamSpottracks': mergeRemovingOverlap('L2_', self.chainName+'_BeamSpottracks'), }
def setupFromDict(self, seq_te_dict, seq_dict=None): ''' Dictionary completely defines steps, algos, sequences, etc.. pass a dictionary with sequence key values and tuple with te_out and alias for TE renaming i.e. seq_te_dict['fastringer']=('L2_e_step1','cl') ''' # Use default sequence map if not passed modified map if seq_dict is None: seq_dict = self.ph_sequences #log.info('%s'%seq_dict) te_in = self.L2InputTE for step in seq_te_dict: level = seq_te_dict[step][0].split('_')[0] te_out = seq_te_dict[step][0] alias = seq_te_dict[step][-1] algos = seq_dict[step] #log.info('%s %s %s %s'%(level,te_in,algos,te_out)) if level == 'L2': self.L2sequenceList += [[te_in, algos, te_out]] self.L2signatureList += [[[te_out] * self.mult]] elif level == 'EF': self.EFsequenceList += [[te_in, algos, te_out]] self.EFsignatureList += [[[te_out] * self.mult]] else: log.error('Sequence TE dictionary incorrect') te_in = [te_out] self.TErenamingDict[te_out] = mergeRemovingOverlap( level + '_', self.chainPartNameNoMult + alias)
def setupCosmicLArPreSNoise(self): #L2 sequence setup if 'L1_EM' in self.chainL1Item: from TrigT2CaloEgamma.TrigT2CaloEgammaConfig import T2CaloEgamma_AllEm theTrigT2CaloEgammaFex = T2CaloEgamma_AllEm() else: # ('L1_J' in self.chainL1Item) | ('L1_TAU' in self.chainL1Item): from TrigT2CaloEgamma.TrigT2CaloEgammaConfig import T2CaloEgamma_All theTrigT2CaloEgammaFex = T2CaloEgamma_All() from TrigEgammaHypo.TrigL2CaloHypoConfig import TrigL2CaloLayersHypo_PreS_080 self.L2sequenceList += [[ self.L2InputTE, [ theTrigT2CaloEgammaFex, TrigL2CaloLayersHypo_PreS_080('TrigL2CaloLayersHypo_' + self.chainName + '_080') ], 'L2_step1' ]] self.L2signatureList += [[['L2_step1'] * self.mult]] self.TErenamingDict = { 'L2_step1': mergeRemovingOverlap( 'L2_', 'TrigL2CaloLayersHypo_' + self.chainName + '_080'), }
def setupL1SaturatedMon(self): from TrigCaloRec.TrigCaloRecConf import TrigL1BSTowerMaker from TrigCaloRec.TrigCaloRecConfig import TrigL1BSTowerHypoConfig theL1BS = TrigL1BSTowerMaker() theL1BSHypo = TrigL1BSTowerHypoConfig('TrigL1BSTowerHypoConfig_'+self.chainName.replace(".","")) self.L2sequenceList += [[self.L2InputTE, [theL1BS], 'L2_l1bs_step1']] self.L2sequenceList += [[['L2_l1bs_step1'],[theL1BSHypo],'L2_l1bs_step2']] self.L2signatureList += [ [['L2_l1bs_step1']*self.mult] ] self.L2signatureList += [ [['L2_l1bs_step2']*self.mult] ] self.TErenamingDict = { 'L2_l1bs_step1': mergeRemovingOverlap('L2_', self.chainName.replace(".","")+'_l1bs'), 'L2_l1bs_step2': mergeRemovingOverlap('L2_', self.chainName.replace(".","")+'_l1bsHypo'), }
def setup_gXX_ID(self): seq_te_dict = collections.OrderedDict() seq_te_dict['fastcalo'] = ('L2_g_step1', '_calo') seq_te_dict['fastrec'] = ('L2_g_step2', '') seq_te_dict['precisecalo'] = ('EF_g_step1', '_calo') seq_te_dict['precisecalocalib'] = ('EF_g_step2', '_calocalib') seq_te_dict['preciserec'] = ('EF_g_step3', '') self.setupFromDict(seq_te_dict) if 'larpeb' in self.chainPart['addInfo']: from TrigDetCalib.TrigDetCalibConfig import LArEFROBListWriter self.EFsequenceList += [ [['EF_g_step3'], [ LArEFROBListWriter('LArEFROBListWriter_' + self.chainName, addCTPResult=True, addL2Result=True, addEFResult=True) ], 'EF_g_step4'] ] if 'larpeb' in self.chainPart['addInfo']: self.EFsignatureList += [[['EF_g_step4'] * self.mult]] if 'larpeb' in self.chainPart['addInfo']: self.TErenamingDict['EF_g_step4'] = mergeRemovingOverlap( 'EF_', self.chainPartNameNoMult + '_larpeb')
def setup_gnocut_hiptrt(self): # list of required key values for sequences required_seq = ['precisecalo', 'precisecalocalib', 'preciserec'] # Check for required sequences for item in required_seq: if item not in self.ph_sequences: log.error('%s sequence not defined', item) else: log.debug('%s', self.seqObj.print_sequence(item)) ########### Sequences ########### self.L2sequenceList += [[ self.L2InputTE, self.hip_trt_seq, 'L2_g_step1' ]] self.EFsequenceList += [[['L2_g_step1'], self.ph_sequences['precisecalo'], 'EF_g_step1']] self.EFsequenceList += [[['EF_g_step1'], self.ph_sequences['precisecalocalib'], 'EF_g_step2']] self.EFsequenceList += [[['EF_g_step2'], self.ph_sequences['preciserec'], 'EF_g_step3']] ########### Signatures ########### self.L2signatureList += [[['L2_g_step1'] * self.mult]] self.EFsignatureList += [[['EF_g_step1'] * self.mult]] self.EFsignatureList += [[['EF_g_step2'] * self.mult]] self.EFsignatureList += [[['EF_g_step3'] * self.mult]] ########### TE renaming ########### self.TErenamingDict = { 'L2_g_step1': mergeRemovingOverlap('L2_', self.chainPartNameNoMult), 'EF_g_step1': mergeRemovingOverlap('EF_', self.chainPartNameNoMult + '_calo'), 'EF_g_step2': mergeRemovingOverlap('EF_', self.chainPartNameNoMult + '_calocalib'), 'EF_g_step3': mergeRemovingOverlap('EF_', self.chainPartNameNoMult), }
def setupTestChain(self): from TrigGenericAlgs.TrigGenericAlgsConf import DummyFEX self.EF_Dummy = DummyFEX("EF_%s" % self.chainName) # Sequences self.L2sequenceList += [[self.L2InputTE, [self.EF_Dummy], 'L2_step1']] self.EFsequenceList += [[['L2_step1'], [self.EF_Dummy], 'EF_step1']] # Signatures self.L2signatureList += [[['L2_step1'] * self.mult]] self.EFsignatureList += [[['EF_step1'] * self.mult]] # TE renaming self.TErenamingDict = { 'L2_step1': mergeRemovingOverlap('L2_', 'Test_' + self.chainName + '_step1'), 'EF_step1': mergeRemovingOverlap('EF_', self.chainName), }
def setup_mb_perf(self): ########## L2 algos ################## if "perf" in self.chainPart['recoAlg']: chainSuffix = "perf" theL2Fex1 = L2MbSpFex_noPix theL2Hypo1 = L2MbSpHypo_PT theL2Fex2 = L2MbMbtsFex theL2Hypo2 = L2MbMbtsHypo_PT ########## EF algos ################## ########### Sequence List ############## self.L2sequenceList += [["", [dummyRoI], 'L2_mb_dummy']] self.L2sequenceList += [[ 'L2_mb_dummy', efiddataprep, 'L2_mb_iddataprep' ]] self.L2sequenceList += [[['L2_mb_iddataprep'], [theL2Fex1, theL2Hypo1], 'L2_mb_step1']] self.L2sequenceList += [[['L2_mb_step1'], [theL2Fex2, theL2Hypo2], 'L2_mb_step2']] ########### Signatures ########### self.L2signatureList += [[['L2_mb_dummy']]] self.L2signatureList += [[['L2_mb_iddataprep']]] self.L2signatureList += [[['L2_mb_step1']]] self.L2signatureList += [[['L2_mb_step2']]] self.TErenamingDict = { 'L2_mb_dummy': mergeRemovingOverlap('L2_dummy', chainSuffix), 'L2_mb_iddataprep': mergeRemovingOverlap('L2_iddataprep_', chainSuffix), 'L2_mb_step1': mergeRemovingOverlap('L2_sp_', chainSuffix), 'L2_mb_step2': mergeRemovingOverlap('L2_mbts_', chainSuffix), }
def setup_gXX_ID_heavyIon(self): seq_te_dict = collections.OrderedDict() seq_te_dict['fastcalo'] = ('L2_g_step1', '_calo') seq_te_dict['fastrec'] = ('L2_g_step2', '') seq_te_dict['precisecalo'] = ('EF_g_step1', '_calo') seq_te_dict['precisecalocalib'] = ('EF_g_step2', '_calocalib') seq_te_dict['preciserec'] = ('EF_g_step3', '') # First set the normal sequence self.setupFromDict(seq_te_dict) # Now insert additional steps self.EFsequenceList.insert( 0, [['L2_g_step2'], [theFSCellMaker], 'EF_g_step1_fs']) self.EFsequenceList.insert( 1, [['EF_g_step1_fs'], [theUEMaker], 'EF_g_step1_ue']) self.EFsignatureList.insert(0, [['EF_g_step1_fs']]) self.EFsignatureList.insert(1, [['EF_g_step1_ue']]) self.TErenamingDict['EF_g_step1_fs'] = mergeRemovingOverlap( 'EF_', self.chainPartNameNoMult + '_fs') self.TErenamingDict['EF_g_step1_ue'] = mergeRemovingOverlap( 'EF_', self.chainPartNameNoMult + '_ue')
def setup_gXX_ID_ringer(self): ########### Sequences ########### self.L2sequenceList += [[ self.L2InputTE, self.ph_sequences['fastringer'], 'L2_g_step1' ]] self.EFsequenceList += [[['L2_g_step1'], self.ph_sequences['preciserec'], 'EF_g_step1']] self.EFsequenceList += [[['EF_g_step1'], [self.ph_sequences['precisecalocalib'][0]], 'EF_g_step2']] self.EFsequenceList += [[['EF_g_step2'], self.ph_sequences['preciserec'], 'EF_g_step3']] ########### Signatures ########### self.L2signatureList += [[['L2_g_step1'] * self.mult]] self.EFsignatureList += [[['EF_g_step1'] * self.mult]] self.EFsignatureList += [[['EF_g_step2'] * self.mult]] self.EFsignatureList += [[['EF_g_step3'] * self.mult]] ########### TE renaming ########### self.TErenamingDict = { 'L2_g_step1': mergeRemovingOverlap('L2_', self.chainPartNameNoMult + '_calo'), 'EF_g_step1': mergeRemovingOverlap('EF_', self.chainPartNameNoMult + '_calo'), 'EF_g_step2': mergeRemovingOverlap('EF_', self.chainPartNameNoMult + '_calocalib'), 'EF_g_step3': mergeRemovingOverlap('EF_', self.chainPartNameNoMult), }
def setupLarPEBChains(self): threshold=self.chainName.split("_")[0].replace("conej","") from TrigT2CaloJet.TrigT2CaloJetConfig import T2CaloJet_Jet_noCalib_noiseCut from TrigCaloHypo.TrigCaloHypoConfig import L2JetHypo from TrigDetCalib.TrigDetCalibConfig import EtaHypo_HEC from TrigDetCalib.TrigDetCalibConfig import EtaHypo_FCAL from TrigDetCalib.TrigDetCalibConfig import LArL2ROBListWriter theL2JetFex = T2CaloJet_Jet_noCalib_noiseCut() theL2JetHypo = L2JetHypo('L2JetHypo_j'+threshold,l2_thr=int(threshold)*GeV) theEtaHypo = EtaHypo_FCAL('EtaHypo_FCAL_fj'+threshold+'_larcalib') if "31ETA49" in self.L2InputTE else EtaHypo_HEC('EtaHypo_HEC_fj'+threshold+'_larcalib') theLArL2ROB = LArL2ROBListWriter('LArL2ROBListWriter_larcalib_j'+threshold) self.L2sequenceList += [[self.L2InputTE, [theL2JetFex], 'L2_larpeb_step1']] self.L2sequenceList += [[['L2_larpeb_step1'],[theL2JetHypo,theEtaHypo],'L2_larpeb_step2']] self.L2sequenceList += [[['L2_larpeb_step2'],[theLArL2ROB],'L2_larpeb_step3']] self.L2signatureList += [ [['L2_larpeb_step1']*self.mult] ] self.L2signatureList += [ [['L2_larpeb_step2']*self.mult] ] self.L2signatureList += [ [['L2_larpeb_step3']*self.mult] ] self.TErenamingDict = { 'L2_larpeb_step1': mergeRemovingOverlap('L2_', self.chainPartNameNoMult+'_'+self.L2InputTE+'_jetCalo'), 'L2_larpeb_step2': mergeRemovingOverlap('L2_', self.chainPartNameNoMult+'_'+self.L2InputTE+'_jetCaloHypo'), 'L2_larpeb_step3': mergeRemovingOverlap('L2_', self.chainPartNameNoMult+'_'+self.L2InputTE+'_jetEtaHypo'), }
def setupCosmicIDNoiseCalibration(self): from TrigDetCalib.TrigDetCalibConfig import TrigSubDetListWriter l2_SCTSubDetListWriter = TrigSubDetListWriter("CosmicSCTNoiseSubDetListWriter") l2_SCTSubDetListWriter.Subdetectors = "SCT" l2_SCTSubDetListWriter.extraROBs = [] theRobWriter= [l2_SCTSubDetListWriter] self.L2sequenceList += [[ '', theRobWriter, 'L2_step1']] self.L2signatureList+=[ [['L2_step1']*self.mult] ] self.TErenamingDict = { 'L2_step1': mergeRemovingOverlap('L2_','Calib'+self.chainName), }
def continueChain(self, level, identifier): lastLevel = self.currentItem.split('_')[0] if lastLevel != level: self.currentStep = 1 self.currentItem = level+'_tau_step'+str(self.currentStep) if level=='L2': self.L2signatureList += [ [[self.currentItem]] ] elif level=='EF': self.EFsignatureList += [ [[self.currentItem]] ] self.TErenamingDict[self.currentItem] = mergeRemovingOverlap(level+'_', self.chainPartName+'_'+identifier) self.currentStep += 1 return self.currentItem
def continueChain(self, level, identifier): lastLevel = self.currentItem.split('_')[0] if lastLevel != level: self.currentStep = 1 self.currentItem = level + '_tau_step' + str(self.currentStep) if level == 'L2': self.L2signatureList += [[[self.currentItem]]] elif level == 'EF': self.EFsignatureList += [[[self.currentItem]]] self.TErenamingDict[self.currentItem] = mergeRemovingOverlap( level + '_', self.chainPartName + '_' + identifier) self.currentStep += 1 return self.currentItem
def setup_mb_hmtperf(self): l2hypo1 = self.chainPart['hypoL2Info'] l2th1 = l2hypo1.lstrip('sp') ########### Sequence List ############## self.L2sequenceList += [["", [dummyRoI], 'L2_mb_dummy']] self.L2sequenceList += [[ 'L2_mb_dummy', efiddataprep, 'L2_mb_iddataprep' ]] self.L2sequenceList += [[['L2_mb_iddataprep'], [theL2Fex1, theL2Hypo1], 'L2_mb_step1']] self.L2sequenceList += [[['L2_mb_step1'], [theL2Fex2, theL2Hypo2], 'L2_mb_step2']] self.EFsequenceList += [[['L2_mb_step2'], [theEFMETFex, theEFMETHypo], 'EF_mb_step1']] self.EFsequenceList += [[['EF_mb_step1'], theEFFex1 + [theEFFex2, theEFFex3, theEFHypo], 'EF_mb_step2']] ########### Signatures ########### self.L2signatureList += [[['L2_mb_dummy']]] self.L2signatureList += [[['L2_mb_iddataprep']]] self.L2signatureList += [[['L2_mb_step1']]] self.L2signatureList += [[['L2_mb_step2']]] self.EFsignatureList += [[['EF_mb_step1']]] self.EFsignatureList += [[['EF_mb_step2']]] self.TErenamingDict = { 'L2_mb_dummy': mergeRemovingOverlap('L2_dummy_', chainSuffix), 'L2_mb_iddataprep': mergeRemovingOverlap('L2_iddataprep_', l2hypo1 + '_' + chainSuffix), 'L2_mb_step1': mergeRemovingOverlap('L2_', l2hypo1 + '_' + chainSuffix), 'L2_mb_step2': mergeRemovingOverlap('L2_pusup0', '_' + chainSuffix), 'EF_mb_step1': mergeRemovingOverlap('EF_sumet0', '_' + chainSuffix), 'EF_mb_step2': mergeRemovingOverlap('EF_trk0', '_' + chainSuffix), }
def setup_muXX_MSOnly(self): L2AlgName = self.getL2AlgName() muFastThresh = self.getMuFastThresh() EFExtrapolatorThresh = self.getEFExtrapolatorThresh() ########### L2 algos ################# if "l2muonSA" in self.chainPart['L2SAAlg']: from TrigL2MuonSA.TrigL2MuonSAConfig import TrigL2MuonSAConfig theL2StandAloneAlg = TrigL2MuonSAConfig(L2AlgName) from TrigMuonHypo.TrigMuonHypoConfig import MufastHypoConfig theL2StandAloneHypo = MufastHypoConfig(L2AlgName, muFastThresh) else: logMuonDef.error( "Chain built with %s but so far only l2muonSA is supported." % (self.chainPart['L2SAAlg'])) return False ########### EF algos ################# if 'SuperEF' in self.chainPart['EFAlg']: from AthenaCommon import CfgGetter theTrigMuSuperEF = CfgGetter.getAlgorithm("TrigMuSuperEF_SAonly") theEFAlg = theTrigMuSuperEF EFRecoAlgName = "Muon" else: logMuonDef.error( "Chain built with %s but so far only SuperEF is supported." % (self.chainPart['EFAlg'])) return False from TrigMuonHypo.TrigMuonHypoConfig import TrigMuonEFExtrapolatorHypoConfig theTrigMuonEFExtrapolatorHypoConfig = TrigMuonEFExtrapolatorHypoConfig( EFRecoAlgName, EFExtrapolatorThresh) ########### Sequence List ############## self.L2sequenceList += [[ self.L2InputTE, [theL2StandAloneAlg, theL2StandAloneHypo], 'L2_mu_step1' ]] self.EFsequenceList += [[['L2_mu_step1'], [ theEFAlg, theTrigMuonEFExtrapolatorHypoConfig ], 'EF_mu_step1']] ########### Signatures ########### self.L2signatureList += [[['L2_mu_step1'] * self.mult]] self.EFsignatureList += [[['EF_mu_step1'] * self.mult]] ########### TE renaming ########## self.TErenamingDict = { 'L2_mu_step1': mergeRemovingOverlap( 'L2_mu_SA_', L2AlgName + muFastThresh + '_' + self.L2InputTE), 'EF_mu_step1': mergeRemovingOverlap('EF_SuperEF_', self.chainPartNameNoMult), }
def setup_xeXX(self): ##EF only chain, run FEB or topo_cluster ##NoAlg at L2 ##if at a certain point different steps are used at EF, ## we need a way to encode the information of the threshold at both the two steps ##could be a dict here, or adding something to the SignatureDictionary threshold = int(self.chainPart['threshold']) calibration = self.chainPart['calib'] L2recoAlg = self.chainPart['L2recoAlg'] EFrecoAlg = self.chainPart['EFrecoAlg'] L2muon = self.chainPart['L2muonCorr'] EFmuon = self.chainPart['EFmuonCorr'] #muonSeed="EF_SuperEF_mu8" muonSeed="EF_mu_step2" logMETDef.info("Creating muon sequence") ## --- HARD-CODED MUON CHAIN --- muThreshold=8 L2AlgName = 'Muon' muFastThresh = '6GeV_v11a' muCombThresh = str(muThreshold)+"GeV" #id_alg_output = "STRATEGY_A" id_alg_output = "TrigFastTrackFinder_Muon" EFRecoAlgName = "Muon" from TrigL2MuonSA.TrigL2MuonSAConfig import TrigL2MuonSAConfig theL2StandAloneAlg = TrigL2MuonSAConfig(L2AlgName) from TrigMuonHypo.TrigMuonHypoConfig import MufastHypoConfig theL2StandAloneHypo = MufastHypoConfig(L2AlgName, muFastThresh) from TrigFastTrackFinder.TrigFastTrackFinder_Config import TrigFastTrackFinder_Muon theTrigFastTrackFinder_Muon = TrigFastTrackFinder_Muon() from InDetTrigRecExample.EFInDetConfig import TrigEFIDSequence theTrigEFIDDataPrep_Muon = TrigEFIDSequence("Muon","muon","DataPrep").getSequence() #from TrigL2SiTrackFinder.TrigL2SiTrackFinder_Config import TrigL2SiTrackFinder_MuonA #theTrigL2SiTrackFinder_MuonA = TrigL2SiTrackFinder_MuonA() #theL2IDAlg = theTrigL2SiTrackFinder_MuonA from TrigmuComb.TrigmuCombConfig import TrigmuCombConfig theL2CombinedAlg = TrigmuCombConfig(L2AlgName, id_alg_output) from TrigMuonHypo.TrigMuonHypoConfig import MucombHypoConfig theL2CombinedHypo = MucombHypoConfig(L2AlgName, muCombThresh) from InDetTrigRecExample.EFInDetConfig import TrigEFIDSequence theTrigEFIDInsideOut_Muon = TrigEFIDSequence("Muon","muon","InsideOutMerged") #theTrigEFIDInsideOut_Muon = TrigEFIDSequence("Muon","muon") ##Run1 tracking from AthenaCommon import CfgGetter theTrigMuSuperEF = CfgGetter.getAlgorithm("TrigMuSuperEF") theEFAlg = theTrigMuSuperEF from TrigMuonHypo.TrigMuonHypoConfig import TrigMuonEFCombinerHypoConfig theTrigMuonEFCombinerHypoConfig = TrigMuonEFCombinerHypoConfig(EFRecoAlgName,str(muThreshold)+"GeV") L2_mu_step1_TE = 'muonstandalone_'+L2AlgName+'_muFast'+muFastThresh L2muonInputTE = 'MU6' self.L2sequenceList += [[L2muonInputTE, [theL2StandAloneAlg , theL2StandAloneHypo], 'L2_mu_step1']] self.L2sequenceList += [[['L2_mu_step1'], theTrigEFIDDataPrep_Muon+ [theTrigFastTrackFinder_Muon, theL2CombinedAlg, theL2CombinedHypo], 'L2_mu_step2']] self.EFsequenceList += [[['L2_mu_step2'], theTrigEFIDInsideOut_Muon.getSequence(), 'EF_mu_step1']] self.EFsequenceList += [[['EF_mu_step1'], [ theEFAlg, theTrigMuonEFCombinerHypoConfig], 'EF_mu_step2']] ########### Imports for hypos and fexes ########### ##L1 MET from TrigL2MissingET.TrigL2MissingETConfig import L2MissingET_Fex theL2Fex = L2MissingET_Fex() from TrigMissingETMuon.TrigMissingETMuonConfig import L2TrigMissingETMuon_Fex theL2MuonFex = L2TrigMissingETMuon_Fex() ##FEB MET at L2 from TrigL2MissingET.TrigL2MissingETConfig import L2CaloMissingET_Fex_ReadL2L1 theL2FEBL1Check = L2CaloMissingET_Fex_ReadL2L1() from TrigMissingETMuon.TrigMissingETMuonConfig import L2CaloTrigMissingETMuon_Fex theL2FEBMuonFex = L2CaloTrigMissingETMuon_Fex() mucorr= '_wMu' if L2muon else '' if L2recoAlg=="L2FS": from TrigMissingETHypo.TrigMissingETHypoConfig import L2MetHypoFEBXE theL2MuonHypo = L2MetHypoFEBXE(name='L2MetHypo_xe%d%s_FEB'%(threshold,mucorr),l2_thr=threshold*GeV) else: from TrigMissingETHypo.TrigMissingETHypoConfig import L2MetHypoXE theL2MuonHypo = L2MetHypoXE('L2MetHypo_xe_noL2%s' %mucorr,l2_thr=threshold*GeV) ##MET with topo-cluster if EFrecoAlg=='tc' or EFrecoAlg=='pueta': ##Topo-cluster if EFrecoAlg=='tc': #MET fex from TrigEFMissingET.TrigEFMissingETConfig import EFMissingET_Fex_topoClusters theEFMETFex = EFMissingET_Fex_topoClusters() #Muon correction fex from TrigMissingETMuon.TrigMissingETMuonConfig import EFTrigMissingETMuon_Fex_topocl theEFMETMuonFex = EFTrigMissingETMuon_Fex_topocl() #TC hypo mucorr= '_wMu' if EFmuon else '' from TrigMissingETHypo.TrigMissingETHypoConfig import EFMetHypoTCXE if self.chainPart['trigType'] == "xs": from TrigMissingETHypo.TrigMissingETHypoConfig import EFMetHypoXS_2sided theEFMETHypo = EFMetHypoXS_2sided('EFMetHypo_xs_2sided_%i%s' % (threshold, mucorr),ef_thr=float(threshold)*0.1) elif self.chainPart['trigType'] == "te": from TrigMissingETHypo.TrigMissingETHypoConfig import EFMetHypoTE theEFMETHypo = EFMetHypoTE('EFMetHypo_te%d' % threshold,ef_thr=float(threshold)*GeV) else: theEFMETHypo = EFMetHypoTCXE('EFMetHypo_TC_xe%s_tc%s%s'%(threshold,calibration,mucorr),ef_thr=float(threshold)*GeV) ##Topo-cluster with Pile-up suppression if EFrecoAlg=='pueta': #MET fex from TrigEFMissingET.TrigEFMissingETConfig import EFMissingET_Fex_topoClustersPS theEFMETFex = EFMissingET_Fex_topoClustersPS() #Muon correction fex from TrigMissingETMuon.TrigMissingETMuonConfig import EFTrigMissingETMuon_Fex_topoclPS theEFMETMuonFex = EFTrigMissingETMuon_Fex_topoclPS() mucorr= '_wMu' if EFmuon else '' from TrigMissingETHypo.TrigMissingETHypoConfig import EFMetHypoTCPSXE theEFMETHypo = EFMetHypoTCPSXE('EFMetHypo_TCPS_xe%s_tc%s%s'%(threshold,calibration,mucorr),ef_thr=float(threshold)*GeV) ##2-SidedNoise Cell elif EFrecoAlg=='cell': #MET fex from TrigEFMissingET.TrigEFMissingETConfig import EFMissingET_Fex_2sidednoiseSupp theEFMETFex = EFMissingET_Fex_2sidednoiseSupp() #Muon correction fex from TrigMissingETMuon.TrigMissingETMuonConfig import EFTrigMissingETMuon_Fex theEFMETMuonFex = EFTrigMissingETMuon_Fex() #Hypo if self.chainPart['trigType'] == "xs": from TrigMissingETHypo.TrigMissingETHypoConfig import EFMetHypoXS_2sided theEFMETHypo = EFMetHypoXS_2sided('EFMetHypo_xs_2sided_%d%s' % (threshold, mucorr),ef_thr=float(threshold)*0.1) elif self.chainPart['trigType'] == "te": from TrigMissingETHypo.TrigMissingETHypoConfig import EFMetHypoTE theEFMETHypo = EFMetHypoTE('EFMetHypo_te%d'% threshold,ef_thr=threshold*GeV) else: from TrigMissingETHypo.TrigMissingETHypoConfig import EFMetHypoXE theEFMETHypo = EFMetHypoXE('EFMetHypo_xe%s%s'%(threshold,mucorr),ef_thr=float(threshold)*GeV) else: logMETDef.warning("MET EF algorithm not recognised") from TrigGenericAlgs.TrigGenericAlgsConf import PESA__DummyUnseededAllTEAlgo as DummyAlgo roi_topo = DummyAlgo('RoiCreator') from TrigCaloRec.TrigCaloRecConfig import TrigCaloCellMaker_jet_fullcalo cell_maker_fullcalo_topo = TrigCaloCellMaker_jet_fullcalo("CellMakerFullCalo_topo",doNoise=0, AbsE=True, doPers=True) from TrigCaloRec.TrigCaloRecConfig import TrigCaloClusterMaker_topo topocluster_maker_fullcalo = TrigCaloClusterMaker_topo('TrigCaloClusterMaker_topo_fullscan',doMoments=True,doLC=True) ########### Sequences ########### #Run L2-like algos only for l2fsperf and L2FS chains if L2recoAlg=="l2fsperf" or L2recoAlg=="L2FS": ##L1 MET self.L2sequenceList += [[ self.l2_input_tes, [theL2Fex], 'L2_xe_step1']] ##Moun Correction to L1 MET self.L2sequenceList += [[ ['L2_xe_step1', muonSeed], [theL2MuonFex], 'L2_xe_step2']] ##FEB Met self.L2sequenceList += [[ 'L2_xe_step2', [theL2FEBL1Check], 'L2_xe_step3']] if L2recoAlg=="l2fsperf": #Only execute Muon FEB MET and muon correction self.L2sequenceList += [[ ['L2_xe_step3',muonSeed], [theL2FEBMuonFex], 'L2_xe_step4']] if L2recoAlg=="L2FS": #Hypo on FEB MET self.L2sequenceList += [[ ['L2_xe_step3',muonSeed], [theL2FEBMuonFex,theL2MuonHypo], 'L2_xe_step4']] # --- EF --- #topocluster if EFrecoAlg=='tc' or EFrecoAlg=='pueta': self.EFsequenceList +=[[ '',[roi_topo],'EF_full']] self.EFsequenceList +=[[ 'EF_full',[cell_maker_fullcalo_topo, topocluster_maker_fullcalo],'EF_full_cluster']] self.EFsequenceList +=[[ ['EF_full_cluster'], [theEFMETFex], 'EF_xe_step1' ]] self.EFsequenceList +=[[ ['EF_xe_step1',muonSeed], [theEFMETMuonFex, theEFMETHypo], 'EF_xe_step2' ]] #cell based MET elif EFrecoAlg=='cell': self.EFsequenceList +=[[ [''], [theEFMETFex], 'EF_xe_step1' ]] self.EFsequenceList +=[[ ['EF_xe_step1',muonSeed], [theEFMETMuonFex, theEFMETHypo], 'EF_xe_step2' ]] ########### Signatures ########### #if L2muonSeed or EFmuonSeed: # self.L2signatureList += [ [['L2_mu_step1']*self.mult] ] # self.L2signatureList += [ [['L2_mu_step2']*self.mult] ] # self.EFsignatureList += [ [['EF_mu_step1']*self.mult] ] # self.EFsignatureList += [ [['EF_mu_step2']*self.mult] ] if L2recoAlg=="l2fsperf" or L2recoAlg=="L2FS" : self.L2signatureList += [ [['L2_xe_step1']] ] self.L2signatureList += [ [['L2_xe_step2']] ] self.L2signatureList += [ [['L2_xe_step3']] ] self.L2signatureList += [ [['L2_xe_step4']] ] #if EFrecoAlg=='tc': #self.EFsignatureList += [ [['EF_FSTopoClusters']] ] #self.EFsignatureList += [ [['EF_topocluster_step1']] ] #self.EFsignatureList += [ [['EF_topocluster_step2']] ] self.EFsignatureList += [ [['EF_xe_step1']] ] self.EFsignatureList += [ [['EF_xe_step2']] ] ########### TE renaming ########### self.TErenamingDict = {} if L2muon or EFmuon: muchain = 'mu8' self.TErenamingDict['L2_mu_step1']= mergeRemovingOverlap('L2_mu_SA_',L2AlgName+muFastThresh+'_'+L2muonInputTE) self.TErenamingDict['L2_mu_step2']= mergeRemovingOverlap('L2_mucomb_',muchain +'_'+L2muonInputTE) self.TErenamingDict['EF_mu_step1']= mergeRemovingOverlap('EF_EFIDInsideOut_' ,muchain) self.TErenamingDict['EF_mu_step2']= mergeRemovingOverlap('EF_SuperEF_', muchain) #self.TErenamingDict['L2_mu_step1']= mergeRemovingOverlap('L2_', "muon_standalone_"+ muchain) #self.TErenamingDict['L2_mu_step2']= mergeRemovingOverlap('L2_', muchain) #self.TErenamingDict['EF_mu_step1']= mergeRemovingOverlap('EFID_', muchain) #self.TErenamingDict['EF_mu_step2']= mergeRemovingOverlap('EF_', muchain) if L2recoAlg=="l2fsperf" or L2recoAlg=="L2FS" : self.TErenamingDict['L2_xe_step1']= mergeRemovingOverlap('L2_', self.sig_id_noMult+'_step1') self.TErenamingDict['L2_xe_step2']= mergeRemovingOverlap('L2_', self.sig_id_noMult+'_step2') self.TErenamingDict['L2_xe_step3']= mergeRemovingOverlap('L2_', self.sig_id_noMult+'_step3') self.TErenamingDict['L2_xe_step4']= mergeRemovingOverlap('L2_', self.sig_id_noMult+'_step4') self.TErenamingDict['EF_xe_step1']= mergeRemovingOverlap('EF_', self.sig_id_noMult+'_step1') self.TErenamingDict['EF_xe_step2']= mergeRemovingOverlap('EF_', self.sig_id_noMult)
def setup_hi_ultracentral(self): if 'perfzdc' in self.chainPart['extra']: from TrigHIHypo.UltraCentralHypos import UltraCentral_PT from TrigT2MinBias.TrigT2MinBiasConfig import L2MbZdcFex_LG, L2MbZdcFex_HG, L2MbZdcHypo_PT theL2Fex1 = L2MbZdcFex_LG theL2Fex2 = L2MbZdcFex_HG theL2Hypo1 = L2MbZdcHypo_PT chainSuffix = 'perfzdc_ucc' UChypo = UltraCentral_PT("UltraCentralHypo_PT") elif 'perf' in self.chainPart['extra']: from TrigHIHypo.UltraCentralHypos import UltraCentral_PT chainSuffix = 'perf_ucc' UChypo = UltraCentral_PT("UltraCentralHypo_PT") else: from TrigHIHypo.UltraCentralHypos import UCC_th threshold = self.chainPart['extra'] UChypo = UCC_th[threshold] chainSuffix = threshold if 'zdcpu' in self.chainPart['pileupInfo']: from TrigT2MinBias.TrigT2MinBiasConfig import L2MbZdcFex_LG from TrigT2MinBias.TrigT2MinBiasConfig import L2MbZdcHypo_sideAC_zdc_LG theL2Fex1 = L2MbZdcFex_LG theL2Hypo1 = L2MbZdcHypo_sideAC_zdc_LG from TrigHIHypo.UE import theUEMaker, theFSCellMaker ########### Sequence List ############## self.L2sequenceList += [["", [dummyRoI], 'L2_hi_step1']] self.EFsequenceList += [[['L2_hi_step1'], [theFSCellMaker], 'EF_hi_step1_fs']] self.EFsequenceList += [[['EF_hi_step1_fs'], [theUEMaker], 'EF_hi_step1_ue']] self.EFsequenceList += [[['EF_hi_step1_ue'], [UChypo], 'EF_hi_step2']] if 'perfzdc' in self.chainPart['extra']: self.EFsequenceList += [[['EF_hi_step2'], [theL2Fex1], 'EF_hi_step3']] self.EFsequenceList += [[['EF_hi_step3'], [theL2Fex2, theL2Hypo1], 'EF_hi_step4']] if 'zdcpu' in self.chainPart['pileupInfo']: self.EFsequenceList += [[['EF_hi_step2'], [theL2Fex1, theL2Hypo1], 'EF_hi_step3']] ########### Signatures ########### self.L2signatureList += [[['L2_hi_step1']]] self.EFsignatureList += [[['EF_hi_step1_fs']]] self.EFsignatureList += [[['EF_hi_step1_ue']]] self.EFsignatureList += [[['EF_hi_step2']]] if 'perfzdc' in self.chainPart['extra']: self.EFsignatureList += [[['EF_hi_step3']]] self.EFsignatureList += [[['EF_hi_step4']]] if 'zdcpu' in self.chainPart['pileupInfo']: self.EFsignatureList += [[['EF_hi_step3']]] self.TErenamingDict = { 'L2_hi_step1': mergeRemovingOverlap('L2_hi_step1_', chainSuffix), 'EF_hi_step1_fs': mergeRemovingOverlap('EF_hi_fs_', chainSuffix), 'EF_hi_step1_ue': mergeRemovingOverlap('EF_hi_ue_', chainSuffix), 'EF_hi_step2': mergeRemovingOverlap('EF_hi_lg_', chainSuffix), } if 'perfzdc' in self.chainPart['extra']: self.TErenamingDict['EF_hi_step3'] = mergeRemovingOverlap( 'EF_hi_hg_', chainSuffix) self.TErenamingDict['EF_hi_step4'] = mergeRemovingOverlap( 'EF_hi_', chainSuffix) if 'zdcpu' in self.chainPart['pileupInfo']: self.TErenamingDict['EF_hi_step3'] = mergeRemovingOverlap( 'EF_hi_', chainSuffix + '_zdcpu')
def setup_hi_eventshape(self): EShypo_temp = self.chainPart['extra'] ESth = EShypo_temp.lstrip('th') #print 'igb: ES threshold:', ESth VetoHypo = None ESHypo = None ESDiHypo = None if 'v2' == self.chainPart['eventShape']: from TrigHIHypo.VnHypos import V2_th chainSuffix = 'v2_th' + ESth assert V2_th.has_key( int(ESth)), "Missing V2 configuration for threshold " + ESth ESHypo = V2_th[int(ESth)] if self.chainPart['eventShapeVeto'] == 'veto3': from TrigHIHypo.VnHypos import V3_th1_veto VetoHypo = V3_th1_veto elif 'v3' == self.chainPart['eventShape']: from TrigHIHypo.VnHypos import V3_th chainSuffix = 'v3_th' + ESth assert V3_th.has_key( int(ESth)), "Missing V3 configuration for threshold " + ESth ESHypo = V3_th[int(ESth)] if self.chainPart['eventShapeVeto'] == 'veto2': from TrigHIHypo.VnHypos import V2_th1_veto VetoHypo = V2_th1_veto elif 'v23' == self.chainPart['eventShape']: from TrigHIHypo.VnHypos import V3_th, V2_th chainSuffix = 'th' + ESth th = int(ESth) ESDiHypo = [V2_th[th], V3_th[th]] elif 'v2A' == self.chainPart['eventShape']: from TrigHIHypo.VnHypos import V2Assym chainSuffix = 'v2A_th' + ESth ESHypo = V2Assym(ESth, 'A') elif 'v2C' == self.chainPart['eventShape']: from TrigHIHypo.VnHypos import V2Assym chainSuffix = 'v2C_th' + ESth ESHypo = V2Assym(ESth, 'C') #print "ERROR", ESHypo, VetoHypo, ESDiHypo, " when making chain ", self.chainPart from TrigHIHypo.UE import theUEMaker, theFSCellMaker ########### Sequence List ############## self.L2sequenceList += [["", [dummyRoI], 'L2_hi_step1']] self.EFsequenceList += [[['L2_hi_step1'], [theFSCellMaker], 'EF_hi_step1_fs']] self.EFsequenceList += [[['EF_hi_step1_fs'], [theUEMaker], 'EF_hi_step1_ue']] self.L2signatureList += [[['L2_hi_step1']]] self.EFsignatureList += [[['EF_hi_step1_fs']]] self.EFsignatureList += [[['EF_hi_step1_ue']]] if ESHypo: self.EFsequenceList += [[['EF_hi_step1_ue'], [ESHypo], 'EF_hi_step2']] self.EFsignatureList += [[['EF_hi_step2']]] if VetoHypo: self.EFsequenceList += [[['EF_hi_step2'], [VetoHypo], 'EF_hi_step_veto']] self.EFsignatureList += [[['EF_hi_step_veto']]] if ESDiHypo: self.EFsequenceList += [[['EF_hi_step1_ue'], [ESDiHypo[0]], 'EF_hi_step2']] self.EFsequenceList += [[['EF_hi_step2'], [ESDiHypo[1]], 'EF_hi_step3']] self.EFsignatureList += [[['EF_hi_step2']]] self.EFsignatureList += [[['EF_hi_step3']]] self.TErenamingDict = { 'L2_hi_step1': mergeRemovingOverlap('L2_hi_step1_', chainSuffix), 'EF_hi_step1_fs': mergeRemovingOverlap('EF_hi_fs_', chainSuffix), 'EF_hi_step1_ue': mergeRemovingOverlap('EF_hi_ue_', chainSuffix), 'EF_hi_step2': mergeRemovingOverlap('EF_hi_', chainSuffix), 'EF_hi_step3': mergeRemovingOverlap('EF_hi_', '_and_v3_' + chainSuffix), 'EF_hi_step_veto': mergeRemovingOverlap('EF_hi_veto_', chainSuffix), }
def setup_photon(self): #log.info('Setup Photon for v7 %s'%self.chainName) seq_te_dict = collections.OrderedDict() # required to preserve some backward compatibility # need to hack a bit the fastcalo step to use the T2CaloRinger fastcaloseq = self.ph_sequences['fastcalorec'] log.debug('Photon L2 sequence %s', fastcaloseq) fastcaloseq.extend(self.ph_sequences['fastcalohypo']) log.debug('Photon L2 sequence %s', fastcaloseq) seq_dict = self.ph_sequences seq_dict['fastcalo'] = fastcaloseq seq_te_dict['fastcalo'] = ('L2_g_step1', '_calo') seq_te_dict['fastrec'] = ('L2_g_step2', '') seq_te_dict['precisecalo'] = ('EF_g_step1', '_calo') seq_te_dict['precisecalocalib'] = ('EF_g_step2', '_calocalib') if not self.doIsolation: seq_te_dict['preciserec'] = ('EF_g_step3', '') self.setupFromDict(seq_te_dict, seq_dict) if self.doIsolation: # full scan topo and merging w/ RoI TEs te_in = '' pos = 2 for step in self.fullScanSeqMap: self.EFsequenceList.insert( pos, [[te_in], self.fullScanSeqMap[step], step]) self.EFsignatureList.insert(pos, [[step]]) te_in = step pos += 1 self.EFsequenceList.insert( pos, [['EF_g_step2', te_in], [self.DummyMergerAlgo], 'EF_gCache_step2']) self.EFsignatureList.insert(pos, [['EF_gCache_step2']]) self.EFsequenceList.insert( pos + 1, [['EF_gCache_step2'], self.ph_sequences['preciserec'], 'EF_g_step3']) self.EFsignatureList.insert(pos + 1, [['EF_g_step3'] * self.mult]) ########### TE renaming ########### self.TErenamingDict['EF_full'] = mergeRemovingOverlap( 'EF_', self.chainPartNameNoMult + '_fs') self.TErenamingDict['EF_full_cell'] = mergeRemovingOverlap( 'EF_', self.chainPartNameNoMult + '_fscalocell') self.TErenamingDict['EF_FSTopoClusters'] = mergeRemovingOverlap( 'EF_', self.chainPartNameNoMult + '_fscalotopo') self.TErenamingDict['EF_FSTopoClustersED'] = mergeRemovingOverlap( 'EF_', self.chainPartNameNoMult + '_fscalotopoed') self.TErenamingDict['EF_gCache_step2'] = mergeRemovingOverlap( 'EF_', self.chainPartNameNoMult + 'ED') self.TErenamingDict['EF_g_step3'] = mergeRemovingOverlap( 'EF_', self.chainPartNameNoMult) # larpeb if 'larpeb' in self.chainPart['addInfo']: from TrigDetCalib.TrigDetCalibConfig import LArEFROBListWriter self.EFsequenceList += [ [['EF_g_step3'], [ LArEFROBListWriter('LArEFROBListWriter_' + self.chainName, addCTPResult=True, addL2Result=True, addEFResult=True) ], 'EF_g_step4'] ] if 'larpeb' in self.chainPart['addInfo']: self.EFsignatureList += [[['EF_g_step4'] * self.mult]] if 'larpeb' in self.chainPart['addInfo']: self.TErenamingDict['EF_g_step4'] = mergeRemovingOverlap( 'EF_', self.chainPartNameNoMult + '_larpeb')
def setup_eXXvh_ID_run2(self): threshold = self.chainPart['threshold'] IDinfo = self.chainPart['IDinfo'] isoInfo = self.chainPart['isoInfo'] addInfo = self.chainPart['addInfo'] trkInfo = self.chainPart['trkInfo'] logElectronDef.debug('setup_eXXvh_ID_run2') logElectronDef.debug('threshold: %s',threshold) logElectronDef.debug('isoInfo: %s',isoInfo) logElectronDef.debug('IDinfo: %s',IDinfo) logElectronDef.debug('trkInfo: %s',trkInfo) # common imports required for EtCut and Electron ID chains # L2 Calo FEX from TrigT2CaloEgamma.TrigT2CaloEgammaConfig import T2CaloEgamma_eGamma theT2CaloEgamma_eGamma = T2CaloEgamma_eGamma() # L2 Elecgtron FEX from TrigEgammaHypo.TrigL2ElectronFexConfig import L2ElectronFex_1 # Depends on L2 Strategy theL2ElectronFex = L2ElectronFex_1() # EF Calo from TrigCaloRec.TrigCaloRecConfig import TrigCaloCellMaker_eGamma, TrigCaloTowerMaker_eGamma, TrigCaloClusterMaker_slw theTrigCaloCellMaker_eGamma = TrigCaloCellMaker_eGamma() theTrigCaloTowerMaker_eGamma = TrigCaloTowerMaker_eGamma() theTrigCaloClusterMaker_slw = TrigCaloClusterMaker_slw() from TrigEgammaHypo.TrigEFCaloCalibFexConfig import TrigEFCaloCalibFex_Electron theTrigEFCaloCalibFex = TrigEFCaloCalibFex_Electron() # EF Tracking theEFElectronIDFex = theTrigEFIDInsideOutMerged_Electron # EF Electron FEX #from TrigEgammaRec.TrigEgammaRecConfig import TrigEgammaRec #theTrigEgammaRec_eGamma = TrigEgammaRec(name = "TrigEgammaRec_eGamma") #print 'ESETUP', self.chainPart # these can be made more configurable later (according to tracking algorithms etc...) if 'etcut' in self.chainPart['addInfo']: from TrigEgammaHypo.TrigL2CaloHypoConfig import L2CaloHypo_NoCut from TrigEgammaHypo.TrigL2ElectronHypoConfig import L2ElectronHypo_e_NoCut from TrigEgammaHypo.TrigEFTrackHypoConfig import EFTrackHypo_e_NoCut from TrigEgammaHypo.TrigEFElectronHypoConfig import TrigEFElectronHypo_e_EtCut from TrigEgammaHypo.TrigEFCaloHypoConfig import TrigEFCaloHypo_EtCut theL2CaloHypo = L2CaloHypo_NoCut("L2CaloHypo_e"+str(threshold)+"_NoCut",threshold ) theL2ElectronHypo = L2ElectronHypo_e_NoCut("L2ElectronHypo_e"+str(threshold)+"_NoCut",threshold ) theTrigEFCaloHypo = TrigEFCaloHypo_EtCut("TrigEFCaloHypo_e"+str(threshold)+"_EtCut",threshold); theEFTrackHypo = EFTrackHypo_e_NoCut("EFTrackHypo_e"+str(threshold)+"_NoCut",threshold) theEFElectronHypo = TrigEFElectronHypo_e_EtCut("TrigEFElectronHypo_e"+str(threshold)+"_EtCut",threshold) elif 'perf' in self.chainPart['addInfo']: from TrigEgammaHypo.TrigL2CaloHypoConfig import L2CaloHypo_NoCut from TrigEgammaHypo.TrigL2ElectronHypoConfig import L2ElectronHypo_e_NoCut from TrigEgammaHypo.TrigEFTrackHypoConfig import EFTrackHypo_e_NoCut from TrigEgammaHypo.TrigEFElectronHypoConfig import TrigEFElectronHypo_e_NoCut from TrigEgammaHypo.TrigEFCaloHypoConfig import TrigEFCaloHypo_All theL2CaloHypo = L2CaloHypo_NoCut("L2CaloHypo_e"+str(threshold)+"_NoCut",threshold ) theL2ElectronHypo = L2ElectronHypo_e_NoCut("L2ElectronHypo_e"+str(threshold)+"_NoCut",threshold ) theTrigEFCaloHypo = TrigEFCaloHypo_All("TrigEFCaloHypo_e"+str(threshold)+"_NoCut",threshold); theEFTrackHypo = EFTrackHypo_e_NoCut("EFTrackHypo_e"+str(threshold)+"_NoCut",threshold) # EF Electron theEFElectronHypo = TrigEFElectronHypo_e_NoCut("TrigEFElectronHypo_e"+str(threshold)+"_NoCut",threshold) elif self.chainPart['IDinfo']: algoSuffix = "e%s_%s()" % (str(threshold),IDinfo) logElectronDef.debug('chain suffix: %s', algoSuffix) #if 'mvt' in algoSuffix: # algoSuffix = algoSuffix.replace('mvt','') from TrigEgammaHypo.TrigL2CaloHypoConfig import L2CaloHypo_e_ID from TrigEgammaHypo.TrigL2ElectronHypoConfig import L2ElectronHypo_e_ID from TrigEgammaHypo.TrigEFElectronHypoConfig import TrigEFElectronHypo_e_ID from TrigEgammaHypo.TrigEFElectronHypoConfig import TrigEFElectronHypo_e_Iso from TrigEgammaHypo.TrigEFTrackHypoConfig import EFTrackHypo_e from TrigEgammaHypo.TrigEFCaloHypoConfig import TrigEFCaloHypo_e_ID # L2 Calo theL2CaloHypo = L2CaloHypo_e_ID("TrigL2CaloHypo_e"+str(threshold)+"_"+str(IDinfo),threshold,IDinfo) # L2 Electron theL2ElectronHypo = L2ElectronHypo_e_ID("TrigL2ElectronHypo_e"+str(threshold)+"_"+str(IDinfo),threshold,IDinfo) # EF Calo theTrigEFCaloHypo = TrigEFCaloHypo_e_ID("TrigEFCaloHypo_e"+str(threshold)+"_"+str(IDinfo),threshold,IDinfo); # EF Track theEFTrackHypo = EFTrackHypo_e("EFTrackHypo_e"+str(threshold)+"_"+str(IDinfo),threshold) # EF Electron if self.chainPart['isoInfo']: theEFElectronHypo = TrigEFElectronHypo_e_Iso("TrigEFElectronHypo_e"+str(threshold)+"_"+str(IDinfo)+"_"+str(isoInfo),threshold,IDinfo,isoInfo) else: theEFElectronHypo = TrigEFElectronHypo_e_ID("TrigEFElectronHypo_e"+str(threshold)+"_"+str(IDinfo),threshold,IDinfo) else: algoSuffix = "e%s_%s()" % (str(threshold),IDinfo) logElectronDef.error('Chain %s could not be assembled', self.chainPartName) logElectronDef.erro('chain suffix: %s', algoSuffix) return False ########### Sequences ########### trkcomb1st = list(theTrigEFIDDataPrep_Electron) trkcomb1st.append(theTrigFastTrackFinder_Electron) trkcomb1st += theFastTrackFinderxAOD trkcombfull = list(trkcomb1st) trkcombfull += theTrigEFIDInsideOutMerged_Electron self.L2sequenceList += [[self.L2InputTE, [theT2CaloEgamma_eGamma, theL2CaloHypo], 'L2_e_step1']] self.L2sequenceList += [[['L2_e_step1'], trkcomb1st, 'L2_e_step2']] self.L2sequenceList += [[['L2_e_step2'], [theL2ElectronFex, theL2ElectronHypo], 'L2_e_step3']] self.EFsequenceList += [[['L2_e_step3'], [theTrigCaloCellMaker_eGamma, theTrigCaloTowerMaker_eGamma, theTrigCaloClusterMaker_slw], 'EF_e_step1']] self.EFsequenceList += [[['EF_e_step1'], [theTrigEFCaloCalibFex,theTrigEFCaloHypo], 'EF_e_step2']] self.EFsequenceList += [[['EF_e_step2'], theEFElectronIDFex+[ theEFTrackHypo], #trkcombfull+[ theEFTrackHypo], 'EF_e_step3']] self.EFsequenceList += [[['EF_e_step3'], [theTrigEgammaRec_eGamma, theEFElectronHypo], 'EF_e_step4']] ########### Signatures ########### self.L2signatureList += [ [['L2_e_step1']*self.mult] ] self.L2signatureList += [ [['L2_e_step2']*self.mult] ] self.L2signatureList += [ [['L2_e_step3']*self.mult] ] self.EFsignatureList += [ [['EF_e_step1']*self.mult] ] self.EFsignatureList += [ [['EF_e_step2']*self.mult] ] self.EFsignatureList += [ [['EF_e_step3']*self.mult] ] self.EFsignatureList += [ [['EF_e_step4']*self.mult] ] ########### TE renaming ########### self.TErenamingDict = { 'L2_e_step1': mergeRemovingOverlap('L2_', self.chainPartNameNoMult+'cl'), 'L2_e_step2': mergeRemovingOverlap('L2_', self.chainPartNameNoMult+'id'), 'L2_e_step3': mergeRemovingOverlap('L2_', self.chainPartNameNoMult), 'EF_e_step1': mergeRemovingOverlap('EF_', self.chainPartNameNoMult+'calo'), 'EF_e_step2': mergeRemovingOverlap('EF_', self.chainPartNameNoMult+'calocalib'), 'EF_e_step3': mergeRemovingOverlap('EF_', self.chainPartNameNoMult+'id'), 'EF_e_step4': mergeRemovingOverlap('EF_', self.chainPartNameNoMult), }
def setup_muXX_idperf(self): L2AlgName = self.getL2AlgName() muFastThresh = self.getMuFastThresh() EFExtrapolatorThresh = self.getEFExtrapolatorThresh() EFCombinerThresh = self.getEFCombinerThresh() ########### L2 algos ################# if "l2muonSA" in self.chainPart['L2SAAlg']: from TrigL2MuonSA.TrigL2MuonSAConfig import TrigL2MuonSAConfig theL2StandAloneAlg = TrigL2MuonSAConfig(L2AlgName) from TrigMuonHypo.TrigMuonHypoConfig import MufastHypoConfig theL2StandAloneHypo = MufastHypoConfig(L2AlgName, muFastThresh) else: logMuonDef.error( "Chain built with %s but so far only l2muonSA is supported." % (self.chainPart['L2SAAlg'])) return False from TrigFastTrackFinder.TrigFastTrackFinder_Config import TrigFastTrackFinder_Muon theTrigFastTrackFinder_Muon = TrigFastTrackFinder_Muon() from InDetTrigRecExample.EFInDetConfig import TrigEFIDSequence theTrigEFIDDataPrep_Muon = TrigEFIDSequence("Muon", "muon", "DataPrep").getSequence() #id_alg_output = "STRATEGY_A" id_alg_output = "TrigFastTrackFinder_Muon" if "muComb" in self.chainPart['L2CBAlg']: muCombThresh = self.getMuCombThresh() from TrigmuComb.TrigmuCombConfig import TrigmuCombConfig theL2CombinedAlg = TrigmuCombConfig(L2AlgName, id_alg_output) from TrigMuonHypo.TrigMuonHypoConfig import MucombHypoConfig theL2CombinedHypo = MucombHypoConfig(L2AlgName, muCombThresh) else: logMuonDef.error( "Chain built with %s but so far only muComb is supported." % (self.chainPart['L2CBAlg'])) return False ########### EF algos ################# if 'SuperEF' in self.chainPart['EFAlg']: from AthenaCommon import CfgGetter theTrigMuSuperEF = CfgGetter.getAlgorithm("TrigMuSuperEF_TMEFonly") theEFAlg = theTrigMuSuperEF EFRecoAlgName = "Muon" else: logMuonDef.error( "Chain built with %s but so far only SuperEF is supported." % (self.chainPart['EFAlg'])) return False from TrigMuonHypo.TrigMuonHypoConfig import TrigMuonEFCombinerHypoConfig theTrigMuonEFCombinerHypoConfig = TrigMuonEFCombinerHypoConfig( EFRecoAlgName, EFCombinerThresh) from InDetTrigRecExample.EFInDetConfig import TrigEFIDSequence theTrigEFIDInsideOutMerged_Muon = TrigEFIDSequence( "Muon", "muon", "InsideOutMerged") theTrigEFIDInsideOut_Muon = TrigEFIDSequence( "Muon", "muon") # ---> this is Run1 tracking - keep it here #theTrigEFIDInsideOut_Muon_MergedDP = TrigEFIDSequence("Muon","muon","DataPrep") #theTrigEFIDOutsideInTRTOnly_Muon = TrigEFIDSequence("Muon","muon","TRTOnly") from TrigMuonHypo.TrigMuonHypoConfig import TrigMuonEFExtrapolatorHypoConfig theTrigMuonEFExtrapolatorHypoConfig = TrigMuonEFExtrapolatorHypoConfig( EFRecoAlgName, EFExtrapolatorThresh) ########### Sequence List ############## self.L2sequenceList += [[ self.L2InputTE, [theL2StandAloneAlg, theL2StandAloneHypo], 'L2_mu_step1' ]] self.L2sequenceList += [[ ['L2_mu_step1'], theTrigEFIDDataPrep_Muon + [theTrigFastTrackFinder_Muon, theL2CombinedAlg, theL2CombinedHypo], 'L2_mu_step2' ]] EFinputTE = 'L2_mu_step2' if "L2Star" in self.chainPart[ 'L2IDAlg']: # ---> this is Run1 tracking - keep it here self.EFsequenceList += [[[EFinputTE], theTrigEFIDInsideOut_Muon.getSequence(), 'EF_mu_step1']] else: self.EFsequenceList += [ [[EFinputTE], theTrigEFIDInsideOutMerged_Muon.getSequence(), 'EF_mu_step1'] ] #self.EFsequenceList += [[['EF_mu_step1'], # [theTrigEFIDOutsideInTRTOnly_Muon.getSequence()], # 'EF_mu_step2']] self.EFsequenceList += [[['EF_mu_step1'], [ theEFAlg, theTrigMuonEFExtrapolatorHypoConfig ], 'EF_mu_step3']] self.EFsequenceList += [[['EF_mu_step3'], [theTrigMuonEFCombinerHypoConfig], 'EF_mu_step4']] ########### Signatures ########### self.L2signatureList += [[['L2_mu_step1'] * self.mult]] self.L2signatureList += [[['L2_mu_step2'] * self.mult]] self.EFsignatureList += [[['EF_mu_step1'] * self.mult]] #self.EFsignatureList += [ [['EF_mu_step2']*self.mult] ] self.EFsignatureList += [[['EF_mu_step3'] * self.mult]] self.EFsignatureList += [[['EF_mu_step4'] * self.mult]] ########### TE renaming ########## self.TErenamingDict = { 'L2_mu_step1': mergeRemovingOverlap( 'L2_mu_SA_', L2AlgName + muFastThresh + '_' + self.L2InputTE), 'L2_mu_step2': mergeRemovingOverlap( 'L2_mucomb_', self.chainPartNameNoMult.replace( '_' + self.chainPart['isoInfo'], '') + '_' + self.L2InputTE), 'EF_mu_step1': mergeRemovingOverlap('EF_EFIDInsideOutMerged_', self.chainPartNameNoMult), #'EF_mu_step2': mergeRemovingOverlap('EF_TRT_', self.chainPartNameNoMult), 'EF_mu_step3': mergeRemovingOverlap('EF_SuperEF_TMEFOnly_', self.chainPartNameNoMult), 'EF_mu_step4': mergeRemovingOverlap('EF_Comb_', self.chainPartNameNoMult), }
def setup_muXX_ID(self): L2AlgName = self.getL2AlgName() muFastThresh = self.getMuFastThresh() EFCombinerThresh = self.getEFCombinerThresh() ########### L2 algos ################# if "l2muonSA" in self.chainPart['L2SAAlg']: from TrigL2MuonSA.TrigL2MuonSAConfig import TrigL2MuonSAConfig theL2StandAloneAlg = TrigL2MuonSAConfig(L2AlgName) from TrigMuonHypo.TrigMuonHypoConfig import MufastHypoConfig theL2StandAloneHypo = MufastHypoConfig(L2AlgName, muFastThresh) else: logMuonDef.error( "Chain built with %s but so far only l2muonSA is supported." % (self.chainPart['L2SAAlg'])) return False from TrigFastTrackFinder.TrigFastTrackFinder_Config import TrigFastTrackFinder_Muon theTrigFastTrackFinder_Muon = TrigFastTrackFinder_Muon() from InDetTrigRecExample.EFInDetConfig import TrigEFIDSequence theTrigEFIDDataPrep_Muon = TrigEFIDSequence("Muon", "muon", "DataPrep").getSequence() id_alg_output = "TrigFastTrackFinder_Muon" if "muComb" in self.chainPart['L2CBAlg']: muCombThresh = self.getMuCombThresh() from TrigmuComb.TrigmuCombConfig import TrigmuCombConfig theL2CombinedAlg = TrigmuCombConfig(L2AlgName, id_alg_output) from TrigMuonHypo.TrigMuonHypoConfig import MucombHypoConfig theL2CombinedHypo = MucombHypoConfig(L2AlgName, muCombThresh) else: logMuonDef.error( "Chain built with %s but so far only muComb is supported." % (self.chainPart['L2CBAlg'])) return False if "wOvlpRm" in self.chainPart['overlapRemoval']: from TrigMuonHypo.TrigL2MuonOverlapRemoverConfig import TrigL2MuonOverlapRemoverConfig theL2OvlpRmConfig_mufast = TrigL2MuonOverlapRemoverConfig( 'Mufast', 'nominal') theL2OvlpRmConfig_mucomb = TrigL2MuonOverlapRemoverConfig( 'Mucomb', 'nominal') ########### EF algos ################# if 'SuperEF' in self.chainPart['EFAlg']: from AthenaCommon import CfgGetter theTrigMuSuperEF = CfgGetter.getAlgorithm("TrigMuSuperEF") theEFAlg = theTrigMuSuperEF EFRecoAlgName = "Muon" else: logMuonDef.error( "Chain built with %s but so far only SuperEF is supported." % (self.chainPart['EFAlg'])) return False from TrigMuonHypo.TrigMuonHypoConfig import TrigMuonEFCombinerHypoConfig theTrigMuonEFCombinerHypoConfig = TrigMuonEFCombinerHypoConfig( EFRecoAlgName, EFCombinerThresh) from TrigMuonEF.TrigMuonEFConfig import TrigMuonEFTrackIsolationConfig from TrigMuonHypo.TrigMuonHypoConfig import TrigMuonEFTrackIsolationHypoConfig from InDetTrigRecExample.EFInDetConfig import TrigEFIDSequence #theTrigEFIDInsideOut_Muon = TrigEFIDSequence("Muon","muon") # ---> this is Run1 tracking - keep it here theTrigEFIDInsideOutMerged_Muon = TrigEFIDSequence( "Muon", "muon", "InsideOutMerged") theTrigEFIDInsideOut_MuonIso = TrigEFIDSequence( "MuonIso", "muonIso", "InsideOut") ########### Sequence List ############## self.L2sequenceList += [[ self.L2InputTE, [theL2StandAloneAlg, theL2StandAloneHypo], 'L2_mu_step1' ]] EFinputTE = '' if (self.doOvlpRm): self.L2sequenceList += [[['L2_mu_step1'], [theL2OvlpRmConfig_mufast], 'L2_step1a_wOvlpRm']] self.L2sequenceList += [[['L2_step1a_wOvlpRm'], theTrigEFIDDataPrep_Muon + [ theTrigFastTrackFinder_Muon, theL2CombinedAlg, theL2CombinedHypo ], 'L2_step1b_wOvlpRm']] self.L2sequenceList += [[['L2_step1b_wOvlpRm'], [theL2OvlpRmConfig_mucomb], 'L2_step2_wOvlpRm']] EFinputTE = 'L2_step2_wOvlpRm' else: self.L2sequenceList += [[['L2_mu_step1'], theTrigEFIDDataPrep_Muon + [ theTrigFastTrackFinder_Muon, theL2CombinedAlg, theL2CombinedHypo ], 'L2_mu_step2']] EFinputTE = 'L2_mu_step2' #self.EFsequenceList += [[[EFinputTE], # ---> this is Run1 tracking - keep it here # theTrigEFIDInsideOut_Muon.getSequence(), # 'EF_mu_step1']] self.EFsequenceList += [[[EFinputTE], theTrigEFIDInsideOutMerged_Muon.getSequence(), 'EF_mu_step1']] self.EFsequenceList += [[['EF_mu_step1'], [theEFAlg, theTrigMuonEFCombinerHypoConfig], 'EF_mu_step2']] if self.chainPart['isoInfo']: if self.chainPart['isoInfo'] == "iloose": theTrigMuonEFTrackIsolationHypoConfig = TrigMuonEFTrackIsolationHypoConfig( "Muon", "RelEFOnlyMedium") elif self.chainPart['isoInfo'] == "imedium": theTrigMuonEFTrackIsolationHypoConfig = TrigMuonEFTrackIsolationHypoConfig( "Muon", "RelEFOnlyTightWide") else: logMuonDef.error("Isolation %s not yet supported." % (self.chainPart['isoInfo'])) return False self.EFsequenceList += [ [['EF_mu_step2'], theTrigEFIDInsideOut_MuonIso.getSequence(), 'EF_mu_step3'] ] self.EFsequenceList += [[ ['EF_mu_step3'], [ TrigMuonEFTrackIsolationConfig("TrigMuonEFTrackIsolation"), theTrigMuonEFTrackIsolationHypoConfig ], 'EF_mu_step4' ]] ########### Signatures ########### self.L2signatureList += [[['L2_mu_step1'] * self.mult]] if (self.doOvlpRm): self.L2signatureList += [[['L2_step1a_wOvlpRm'] * self.mult]] self.L2signatureList += [[['L2_step1b_wOvlpRm'] * self.mult]] self.L2signatureList += [[['L2_step2_wOvlpRm'] * self.mult]] else: self.L2signatureList += [[['L2_mu_step2'] * self.mult]] self.EFsignatureList += [[['EF_mu_step1'] * self.mult]] self.EFsignatureList += [[['EF_mu_step2'] * self.mult]] if (self.chainPart['isoInfo'] ): # == "iloose" or self.chainPart['isoInfo'] == "imedium": self.EFsignatureList += [[['EF_mu_step3'] * self.mult]] self.EFsignatureList += [[['EF_mu_step4'] * self.mult]] ########### TE renaming ########## self.TErenamingDict = { 'L2_mu_step1': mergeRemovingOverlap( 'L2_mu_SA_', L2AlgName + muFastThresh + '_' + self.L2InputTE), 'L2_mu_step2': mergeRemovingOverlap( 'L2_mucomb_', self.chainPartNameNoMult.replace( '_' + self.chainPart['isoInfo'], '') + '_' + self.L2InputTE), 'EF_mu_step1': mergeRemovingOverlap('EF_EFIDInsideOut_', self.chainPartNameNoMult), 'EF_mu_step2': mergeRemovingOverlap('EF_SuperEF_', self.chainPartNameNoMult), } if (self.chainPart['isoInfo']): self.TErenamingDict.update({ 'EF_mu_step1': mergeRemovingOverlap( 'EF_EFIDInsideOut_', self.chainPartNameNoMult.replace( '_' + self.chainPart['isoInfo'], '')), 'EF_mu_step2': mergeRemovingOverlap( 'EF_SuperEF_', self.chainPartNameNoMult.replace( '_' + self.chainPart['isoInfo'], '')), 'EF_mu_step3': mergeRemovingOverlap('EF_muI_efid_', self.chainPartNameNoMult), 'EF_mu_step4': mergeRemovingOverlap('EF_trkIso_', self.chainPartNameNoMult) }) if self.doOvlpRm: self.TErenamingDict.update({ 'L2_step1a_wOvlpRm': mergeRemovingOverlap( 'L2_mu_SAOvlpRm_', L2AlgName + muFastThresh + '_' + self.L2InputTE + '_wOvlpRm'), 'L2_step1b_wOvlpRm': mergeRemovingOverlap( 'L2_muon_comb', L2AlgName + muCombThresh + '_' + self.L2InputTE + '_wOvlpRm'), 'L2_step2_wOvlpRm': mergeRemovingOverlap( 'L2_mu_combOvlpRm_', L2AlgName + muCombThresh + '_' + self.L2InputTE + '_wOvlpRm'), 'EF_mu_step1': mergeRemovingOverlap('EF_EFIDInsideOut_', self.chainPartNameNoMult + '_wOvlpRm'), 'EF_mu_step2': mergeRemovingOverlap('EF_SuperEF_', self.chainPartNameNoMult + '_wOvlpRm') }) if self.doOvlpRm and self.chainPart['isoInfo']: self.TErenamingDict.update({ 'L2_step1a_wOvlpRm': mergeRemovingOverlap( 'L2_mu_SAOvlpRm_', L2AlgName + muFastThresh + '_' + self.L2InputTE + '_wOvlpRm'), 'L2_step1b_wOvlpRm': mergeRemovingOverlap( 'L2_muon_comb', L2AlgName + muCombThresh + '_' + self.L2InputTE + '_wOvlpRm'), 'L2_step2_wOvlpRm': mergeRemovingOverlap( 'L2_mu_combOvlpRm_', L2AlgName + muCombThresh + '_' + self.L2InputTE + '_wOvlpRm'), 'EF_mu_step1': mergeRemovingOverlap('EF_EFIDInsideOut_', self.chainPartNameNoMult + '_wOvlpRm'), 'EF_mu_step2': mergeRemovingOverlap('EF_SuperEF_', self.chainPartNameNoMult + '_wOvlpRm'), 'EF_mu_step3': mergeRemovingOverlap('EF_muI_efid_', self.chainPartNameNoMult + '_wOvlpRm'), 'EF_mu_step4': mergeRemovingOverlap('EF_trkIso_', self.chainPartNameNoMult + '_wOvlpRm') })
def setup_eXXvh_idperf(self): threshold = self.chainPart['threshold'] IDinfo = self.chainPart['IDinfo'] isoInfo = self.chainPart['isoInfo'] run1 = self.chainPart['trkInfo'] logElectronDef.debug('setup_eXXvh_idperf') logElectronDef.debug('threshold: %s',threshold) logElectronDef.debug('isoInfo: %s',isoInfo) logElectronDef.debug('IDinfo: %s',IDinfo) logElectronDef.debug('trkInfo: %s',run1) # L2 Tracking FEX from TrigL2SiTrackFinder.TrigL2SiTrackFinder_Config import TrigL2SiTrackFinder_eGammaA from TrigL2SiTrackFinder.TrigL2SiTrackFinder_Config import TrigL2SiTrackFinder_eGammaB from TrigL2SiTrackFinder.TrigL2SiTrackFinder_Config import TrigL2SiTrackFinder_eGammaC theTrigL2SiTrackFinder_eGammaA=TrigL2SiTrackFinder_eGammaA() theTrigL2SiTrackFinder_eGammaB=TrigL2SiTrackFinder_eGammaB() theTrigL2SiTrackFinder_eGammaC=TrigL2SiTrackFinder_eGammaC() # EF Calo from TrigCaloRec.TrigCaloRecConfig import TrigCaloCellMaker_eGamma_cells theTrigCaloCellMaker_eGamma_cells= TrigCaloCellMaker_eGamma_cells() from TrigCaloRec.TrigCaloRecConfig import TrigCaloCellMaker_eGamma, TrigCaloTowerMaker_eGamma, TrigCaloClusterMaker_slw theTrigCaloCellMaker_eGamma = TrigCaloCellMaker_eGamma() theTrigCaloTowerMaker_eGamma = TrigCaloTowerMaker_eGamma() theTrigCaloClusterMaker_slw = TrigCaloClusterMaker_slw() # EF Tracking from InDetTrigRecExample.EFInDetConfig import TrigEFIDInsideOut_Electron theEFElectronIDFex = TrigEFIDInsideOut_Electron("Electron").getSequence() # EF Electron FEX # from TrigEgammaRec.TrigEgammaRecConfig import TrigEgammaRec #theTrigEgammaRec_eGamma = TrigEgammaRec(name = "TrigEgammaRec_eGamma") #print 'ESETUP', self.chainPart # these can be made more configurable later (according to tracking algorithms etc...) algoSuffix = "e%s_%s()" % (str(threshold),IDinfo) if 'etcut' in self.chainPart['addInfo']: from TrigEgammaHypo.TrigL2CaloHypoConfig import L2CaloHypo_NoCut from TrigEgammaHypo.TrigEFElectronHypoConfig import TrigEFElectronHypo_e_EtCut theL2CaloHypo = L2CaloHypo_NoCut("L2CaloHypo_e"+str(threshold)+"_NoCut",threshold ) theEFElectronHypo = TrigEFElectronHypo_e_EtCut("TrigEFElectronHypo_e"+str(threshold)+"_EtCut",threshold) elif self.chainPart['IDinfo']: from TrigEgammaHypo.TrigL2CaloHypoConfig import L2CaloHypo_e_ID theL2CaloHypo = L2CaloHypo_e_ID("TrigL2CaloHypo_e"+str(threshold)+"_"+str(IDinfo),threshold,IDinfo) from TrigEgammaHypo.TrigEFElectronHypoConfig import TrigEFElectronHypo_e_ID_CaloOnly theEFElectronHypo = \ TrigEFElectronHypo_e_ID_CaloOnly("TrigEFElectronHypo_e"+str(threshold)+"_"+str(IDinfo)+"_CaloOnly",threshold,IDinfo) ########### Sequences ########### trkseq = list(theTrigEFIDDataPrep_Electron) trkseq.append(theTrigFastTrackFinder_Electron) trkseq += theFastTrackFinderxAOD trkseq+=theTrigEFIDInsideOutMerged_Electron #calo thresholds here? self.L2sequenceList += [[self.L2InputTE, [theT2CaloEgamma_cells_e, theL2CaloHypo], 'L2_e_step1']] self.EFsequenceList += [[['L2_e_step1'], [theTrigCaloCellMaker_eGamma, theTrigCaloTowerMaker_eGamma, theTrigCaloClusterMaker_slw], 'EF_e_step1']] if 'L2Star' in self.chainPart['addInfo']: self.EFsequenceList += [[['EF_e_step1'], [theTrigL2SiTrackFinder_eGammaA]+theL2StarxAOD+ [theTrigL2SiTrackFinder_eGammaB]+theL2StarxAOD+ [theTrigL2SiTrackFinder_eGammaC]+theL2StarxAOD+theEFElectronIDFex, 'EF_e_step2']] else: self.EFsequenceList += [[['EF_e_step1'], trkseq, 'EF_e_step2']] self.EFsequenceList += [[['EF_e_step2'], [theTrigEgammaRec_eGamma, theEFElectronHypo], 'EF_e_step3']] ########### Signatures ########### self.L2signatureList += [ [['L2_e_step1']*self.mult] ] #self.L2signatureList += [ [['L2_e_step2']*self.mult] ] #self.L2signatureList += [ [['L2_e_step3']*self.mult] ] self.EFsignatureList += [ [['EF_e_step1']*self.mult] ] self.EFsignatureList += [ [['EF_e_step2']*self.mult] ] self.EFsignatureList += [ [['EF_e_step3']*self.mult] ] ########### TE renaming ########### self.TErenamingDict = { 'L2_e_step1': mergeRemovingOverlap('L2_', self.chainPartNameNoMult+'cl'), 'EF_e_step1': mergeRemovingOverlap('EF_', self.chainPartNameNoMult+'cl'), 'EF_e_step2': mergeRemovingOverlap('EF_', self.chainPartNameNoMult+'trk'), 'EF_e_step3': mergeRemovingOverlap('EF_', self.chainPartNameNoMult), }
def setup_gXX_ID_iso(self): seq_te_dict = collections.OrderedDict() seq_te_dict['fastcalo'] = ('L2_g_step1', '_calo') seq_te_dict['fastrec'] = ('L2_g_step2', '') seq_te_dict['precisecalo'] = ('EF_g_step1', '_calo') seq_te_dict['precisecalocalib'] = ('EF_g_step2', '_calocalib') #seq_te_dict['preciserec']=('EF_g_step3','') self.setupFromDict(seq_te_dict) # full scan topo and merging w/ RoI TEs te_in = '' pos = 2 for step in self.fullScanSeqMap: self.EFsequenceList.insert( pos, [[te_in], self.fullScanSeqMap[step], step]) self.EFsignatureList.insert(pos, [[step]]) te_in = step pos += 1 self.EFsequenceList.insert( pos, [['EF_g_step2', te_in], [self.DummyMergerAlgo], 'EF_gCache_step2']) self.EFsignatureList.insert(pos, [['EF_gCache_step2']]) self.EFsequenceList.insert( pos + 1, [['EF_gCache_step2'], self.ph_sequences['preciserec'], 'EF_g_step3']) self.EFsignatureList.insert(pos + 1, [['EF_g_step3'] * self.mult]) if 'larpeb' in self.chainPart['addInfo']: from TrigDetCalib.TrigDetCalibConfig import LArEFROBListWriter self.EFsequenceList += [ [['EF_g_step3'], [ LArEFROBListWriter('LArEFROBListWriter_' + self.chainName, addCTPResult=True, addL2Result=True, addEFResult=True) ], 'EF_g_step4'] ] if 'larpeb' in self.chainPart['addInfo']: self.EFsignatureList += [[['EF_g_step4'] * self.mult]] ########### TE renaming ########### self.TErenamingDict['EF_full'] = mergeRemovingOverlap( 'EF_', self.chainPartNameNoMult + '_fs') self.TErenamingDict['EF_full_cell'] = mergeRemovingOverlap( 'EF_', self.chainPartNameNoMult + '_fscalocell') self.TErenamingDict['EF_FSTopoClusters'] = mergeRemovingOverlap( 'EF_', self.chainPartNameNoMult + '_fscalotopo') self.TErenamingDict['EF_FSTopoClustersED'] = mergeRemovingOverlap( 'EF_', self.chainPartNameNoMult + '_fscalotopoed') self.TErenamingDict['EF_gCache_step2'] = mergeRemovingOverlap( 'EF_', self.chainPartNameNoMult + 'ED') self.TErenamingDict['EF_g_step3'] = mergeRemovingOverlap( 'EF_', self.chainPartNameNoMult) if 'larpeb' in self.chainPart['addInfo']: self.TErenamingDict['EF_g_step4'] = mergeRemovingOverlap( 'EF_', self.chainPartNameNoMult + '_larpeb')
def setup_eXXvh_ID(self): threshold = self.chainPart['threshold'] IDinfo = self.chainPart['IDinfo'] isoInfo = self.chainPart['isoInfo'] addInfo = self.chainPart['addInfo'] trkInfo = self.chainPart['trkInfo'] L2IDAlg = self.chainPart['L2IDAlg'] logElectronDef.debug('setup_eXXvh_ID') logElectronDef.debug('threshold: %s',threshold) logElectronDef.debug('isoInfo: %s',isoInfo) logElectronDef.debug('IDinfo: %s',IDinfo) logElectronDef.debug('addInfo: %s',addInfo) logElectronDef.debug('trkInfo: %s',trkInfo) # common imports required for EtCut and Electron ID chains # L2 Calo FEX from TrigT2CaloEgamma.TrigT2CaloEgammaConfig import T2CaloEgamma_eGamma theT2CaloEgamma_eGamma = T2CaloEgamma_eGamma() # L2 Tracking FEX from TrigL2SiTrackFinder.TrigL2SiTrackFinder_Config import TrigL2SiTrackFinder_eGammaA from TrigL2SiTrackFinder.TrigL2SiTrackFinder_Config import TrigL2SiTrackFinder_eGammaB from TrigL2SiTrackFinder.TrigL2SiTrackFinder_Config import TrigL2SiTrackFinder_eGammaC # L2 Elecgtron FEX from TrigEgammaHypo.TrigL2ElectronFexConfig import L2ElectronFex_L2StarA from TrigEgammaHypo.TrigL2ElectronFexConfig import L2ElectronFex_L2StarB from TrigEgammaHypo.TrigL2ElectronFexConfig import L2ElectronFex_L2StarC from TrigEgammaHypo.TrigL2ElectronFexConfig import L2ElectronFex_all_NoCut # Depends on L2 Strategy logElectronDef.debug('L2IDAlg: %s', self.chainPart['L2IDAlg']) if self.chainPart['L2IDAlg']: if L2IDAlg == 'L2StarA': theL2TrackingFex = TrigL2SiTrackFinder_eGammaA() theL2ElectronFex = L2ElectronFex_L2StarA() elif L2IDAlg == 'L2StarB': theL2TrackingFex = TrigL2SiTrackFinder_eGammaB() theL2ElectronFex = L2ElectronFex_L2StarB() elif L2IDAlg == 'L2StarC': theL2TrackingFex = TrigL2SiTrackFinder_eGammaC() theL2ElectronFex = L2ElectronFex_L2StarC() else: logElectronDef.info('Incorrect L2IDAlg') # Default else: logElectronDef.debug('Use default L2StarA tracking') theL2TrackingFex = TrigL2SiTrackFinder_eGammaA() theL2ElectronFex = L2ElectronFex_L2StarA() # EF Calo from TrigCaloRec.TrigCaloRecConfig import TrigCaloCellMaker_eGamma, TrigCaloTowerMaker_eGamma, TrigCaloClusterMaker_slw theTrigCaloCellMaker_eGamma = TrigCaloCellMaker_eGamma() theTrigCaloTowerMaker_eGamma = TrigCaloTowerMaker_eGamma() theTrigCaloClusterMaker_slw = TrigCaloClusterMaker_slw() # EF Tracking from InDetTrigRecExample.EFInDetConfig import TrigEFIDInsideOut_Electron theEFElectronIDFex = TrigEFIDInsideOut_Electron("Electron").getSequence() # EF Electron FEX # from TrigEgammaRec.TrigEgammaRecConfig import TrigEgammaRec # theTrigEgammaRec_eGamma = TrigEgammaRec(name = "TrigEgammaRec_eGamma") #print 'ESETUP', self.chainPart # these can be made more configurable later (according to tracking algorithms etc...) if 'etcut' in self.chainPart['addInfo']: from TrigEgammaHypo.TrigL2CaloHypoConfig import L2CaloHypo_NoCut from TrigEgammaHypo.TrigL2ElectronHypoConfig import L2ElectronHypo_e_NoCut from TrigEgammaHypo.TrigEFTrackHypoConfig import EFTrackHypo_e_NoCut from TrigEgammaHypo.TrigEFElectronHypoConfig import TrigEFElectronHypo_e_EtCut theL2CaloHypo = L2CaloHypo_NoCut("L2CaloHypo_e"+str(threshold)+"_NoCut",threshold ) theL2ElectronHypo = L2ElectronHypo_e_NoCut("L2ElectronHypo_e"+str(threshold)+"_NoCut",threshold ) theEFTrackHypo = EFTrackHypo_e_NoCut("EFTrackHypo_e"+str(threshold)+"_NoCut",threshold) theEFElectronHypo = TrigEFElectronHypo_e_EtCut("TrigEFElectronHypo_e"+str(threshold)+"_EtCut",threshold) elif 'perf' in self.chainPart['addInfo']: from TrigEgammaHypo.TrigL2CaloHypoConfig import L2CaloHypo_NoCut from TrigEgammaHypo.TrigL2ElectronHypoConfig import L2ElectronHypo_e_NoCut from TrigEgammaHypo.TrigEFTrackHypoConfig import EFTrackHypo_e_NoCut from TrigEgammaHypo.TrigEFElectronHypoConfig import TrigEFElectronHypo_e_NoCut theL2CaloHypo = L2CaloHypo_NoCut("L2CaloHypo_e"+str(threshold)+"_NoCut",threshold ) theL2ElectronHypo = L2ElectronHypo_e_NoCut("L2ElectronHypo_e"+str(threshold)+"_NoCut",threshold ) theEFTrackHypo = EFTrackHypo_e_NoCut("EFTrackHypo_e"+str(threshold)+"_NoCut",threshold) # EF Electron theEFElectronHypo = TrigEFElectronHypo_e_NoCut("TrigEFElectronHypo_e"+str(threshold)+"_NoCut",threshold) elif self.chainPart['IDinfo']: algoSuffix = "e%s_%s()" % (str(threshold),IDinfo) logElectronDef.debug('chain suffix: %s', algoSuffix) #if 'mvt' in algoSuffix: # algoSuffix = algoSuffix.replace('mvt','') from TrigEgammaHypo.TrigL2CaloHypoConfig import L2CaloHypo_e_ID from TrigEgammaHypo.TrigL2ElectronHypoConfig import L2ElectronHypo_e_ID from TrigEgammaHypo.TrigL2ElectronHypoConfig import L2ElectronHypo_e_ID_L2TrkAlg from TrigEgammaHypo.TrigEFElectronHypoConfig import TrigEFElectronHypo_e_ID from TrigEgammaHypo.TrigEFElectronHypoConfig import TrigEFElectronHypo_e_Iso from TrigEgammaHypo.TrigEFTrackHypoConfig import EFTrackHypo_e # L2 Calo theL2CaloHypo = L2CaloHypo_e_ID("TrigL2CaloHypo_e"+str(threshold)+"_"+str(IDinfo),threshold,IDinfo) # L2 Electron if self.chainPart['L2IDAlg']: theL2ElectronHypo = L2ElectronHypo_e_ID_L2TrkAlg("TrigL2ElectronHypo_e"+str(threshold)+"_"+str(IDinfo)+"_"+str(L2IDAlg),threshold,IDinfo,L2IDAlg) else: theL2ElectronHypo = L2ElectronHypo_e_ID("TrigL2ElectronHypo_e"+str(threshold)+"_"+str(IDinfo),threshold,IDinfo) # EF Track theEFTrackHypo = EFTrackHypo_e("EFTrackHypo_e"+str(threshold)+"_"+str(IDinfo),threshold) # EF Electron if self.chainPart['isoInfo']: theEFElectronHypo = TrigEFElectronHypo_e_Iso("TrigEFElectronHypo_e"+str(threshold)+"_"+str(IDinfo)+"_"+str(isoInfo),threshold,IDinfo,isoInfo) else: theEFElectronHypo = TrigEFElectronHypo_e_ID("TrigEFElectronHypo_e"+str(threshold)+"_"+str(IDinfo),threshold,IDinfo) else: algoSuffix = "e%s_%s()" % (str(threshold),IDinfo) logElectronDef.error('Chain %s could not be assembled', self.chainPartName) logElectronDef.erro('chain suffix: %s', algoSuffix) return False ########### Sequences ########### self.L2sequenceList += [[self.L2InputTE, [theT2CaloEgamma_eGamma, theL2CaloHypo], 'L2_e_step1']] self.L2sequenceList += [[['L2_e_step1'], [theL2TrackingFex]+theL2StarxAOD, 'L2_e_step2']] self.L2sequenceList += [[['L2_e_step2'], [theL2ElectronFex, theL2ElectronHypo], 'L2_e_step3']] self.EFsequenceList += [[['L2_e_step3'], [theTrigCaloCellMaker_eGamma, theTrigCaloTowerMaker_eGamma, theTrigCaloClusterMaker_slw], 'EF_e_step1']] self.EFsequenceList += [[['EF_e_step1'], theEFElectronIDFex+[ theEFTrackHypo], 'EF_e_step2']] self.EFsequenceList += [[['EF_e_step2'], [theTrigEgammaRec_eGamma, theEFElectronHypo], 'EF_e_step3']] ########### Signatures ########### self.L2signatureList += [ [['L2_e_step1']*self.mult] ] self.L2signatureList += [ [['L2_e_step2']*self.mult] ] self.L2signatureList += [ [['L2_e_step3']*self.mult] ] self.EFsignatureList += [ [['EF_e_step1']*self.mult] ] self.EFsignatureList += [ [['EF_e_step2']*self.mult] ] self.EFsignatureList += [ [['EF_e_step3']*self.mult] ] ########### TE renaming ########### self.TErenamingDict = { 'L2_e_step1': mergeRemovingOverlap('L2_', self.chainPartNameNoMult+'cl'), 'L2_e_step2': mergeRemovingOverlap('L2_', self.chainPartNameNoMult+'id'), 'L2_e_step3': mergeRemovingOverlap('L2_', self.chainPartNameNoMult), 'EF_e_step1': mergeRemovingOverlap('EF_', self.chainPartNameNoMult+'calo'), 'EF_e_step2': mergeRemovingOverlap('EF_', self.chainPartNameNoMult+'id'), 'EF_e_step3': mergeRemovingOverlap('EF_', self.chainPartNameNoMult), }
def setup_muXX_noL1(self): ########### EF algos ################# from TrigGenericAlgs.TrigGenericAlgsConf import PESA__DummyUnseededAllTEAlgo from AthenaCommon import CfgGetter from TrigMuonHypo.TrigMuonHypoConfig import TrigMuonEFExtrapolatorMultiHypoConfig if self.chainName.find("2g20_loose1") or self.chainName.find( "e28_tight1_iloose"): if self.chainName.find("2mu"): if self.chainName.find("mu2") >= 0: hypocut = '0GeV_0GeV' theTrigMuonEFSA_FS_Hypo = TrigMuonEFExtrapolatorMultiHypoConfig( 'Muon', '0GeV', '0GeV') else: hypocut = '2GeV_2GeV' theTrigMuonEFSA_FS_Hypo = TrigMuonEFExtrapolatorMultiHypoConfig( 'Muon', '2GeV', '2GeV') else: if self.chainName.find("mu2") >= 0: hypocut = '0GeV' theTrigMuonEFSA_FS_Hypo = TrigMuonEFExtrapolatorMultiHypoConfig( 'Muon', '0GeV') else: hypocut = '2GeV' theTrigMuonEFSA_FS_Hypo = TrigMuonEFExtrapolatorMultiHypoConfig( 'Muon', '2GeV') else: if self.chainName.find("2mu"): if self.chainName.find("mu2") >= 0: hypocut = '0GeV_0GeV_0GeV' theTrigMuonEFSA_FS_Hypo = TrigMuonEFExtrapolatorMultiHypoConfig( 'Muon', '0GeV', '0GeV', '0GeV') else: hypocut = '2GeV_2GeV_2GeV' theTrigMuonEFSA_FS_Hypo = TrigMuonEFExtrapolatorMultiHypoConfig( 'Muon', '2GeV', '2GeV', '2GeV') else: if self.chainName.find("mu2") >= 0: hypocut = '0GeV_0GeV' theTrigMuonEFSA_FS_Hypo = TrigMuonEFExtrapolatorMultiHypoConfig( 'Muon', '0GeV', '0GeV') else: hypocut = '2GeV_2GeV' theTrigMuonEFSA_FS_Hypo = TrigMuonEFExtrapolatorMultiHypoConfig( 'Muon', '2GeV', '2GeV') from InDetTrigRecExample.EFInDetConfig import TrigEFIDSequence theTrigEFIDDataPrep_Muon = TrigEFIDSequence("Muon", "muon", "DataPrep").getSequence() from TrigFastTrackFinder.TrigFastTrackFinder_Config import TrigFastTrackFinder_Muon theTrigFastTrackFinder_Muon = TrigFastTrackFinder_Muon() theTrigEFIDInsideOutMerged_Muon = TrigEFIDSequence( "Muon", "muon", "InsideOutMerged").getSequence() #theTrigEFIDInsideOut_Muon = TrigEFIDSequence("Muon","muon","InsideOut").getSequence() for the fallback on line 605 from TrigMuonEF.TrigMuonEFConfig import TrigMuonEFRoiAggregatorConfig from TrigMuonHypo.TrigMuonHypoConfig import TrigMuonEFCombinerMultiHypoConfig if self.chainName == "mu20_mu8noL1" or self.chainName == "mu20_iloose_mu8noL1" or self.chainName == "mu20_imedium_mu8noL1": theTrigMuonEFCombinerMultiHypoConfig = TrigMuonEFCombinerMultiHypoConfig( 'Muon', '20GeV', '8GeV') hypocutEF = 'MultiComb_20GeV_8GeV' elif self.chainName == "mu20_2mu4noL1" or self.chainName == "mu20_iloose_2mu4noL1" or self.chainName == "mu20_imedium_2mu4noL1": theTrigMuonEFCombinerMultiHypoConfig = TrigMuonEFCombinerMultiHypoConfig( 'Muon', '20GeV', '4GeV', '4GeV') hypocutEF = 'MultiComb_20GeV_4GeV_4GeV' elif self.chainName == "mu24_mu8noL1": theTrigMuonEFCombinerMultiHypoConfig = TrigMuonEFCombinerMultiHypoConfig( 'Muon', '24GeV', '8GeV') hypocutEF = 'MultiComb_24GeV_8GeV' elif self.chainName == "mu24_2mu4noL1": theTrigMuonEFCombinerMultiHypoConfig = TrigMuonEFCombinerMultiHypoConfig( 'Muon', '24GeV', '4GeV', '4GeV') hypocutEF = 'MultiComb_24GeV_4GeV_4GeV' elif self.chainName == "e28_tight1_iloose_mu8noL1": theTrigMuonEFCombinerMultiHypoConfig = TrigMuonEFCombinerMultiHypoConfig( 'Muon', '8GeV') hypocutEF = 'MultiComb_8GeV' elif self.chainName == "2g20_loose1_mu20noL1": theTrigMuonEFCombinerMultiHypoConfig = TrigMuonEFCombinerMultiHypoConfig( 'Muon', '20GeV') hypocutEF = 'MultiComb_20GeV' else: logMuonDef.error("Chain %s is not yet supported." % (self.chainName)) ########### Sequence List ############## self.EFsequenceList += [[ '', [PESA__DummyUnseededAllTEAlgo("EFDummyAlgo")] + [ CfgGetter.getAlgorithm("TrigMuSuperEF_FSSA"), theTrigMuonEFSA_FS_Hypo ], 'EF_SA_FS' ]] self.EFsequenceList += [[ 'EF_SA_FS', [CfgGetter.getAlgorithm("TrigMuonEFFSRoiMaker")], 'EF_SAR_FS' ]] self.EFsequenceList += [[ 'EF_SAR_FS', theTrigEFIDDataPrep_Muon + [theTrigFastTrackFinder_Muon] + theTrigEFIDInsideOutMerged_Muon, #theTrigEFIDInsideOut_Muon, #a fallback - it should be replaced by the previous line if it works 'EF_FStracksMuon' ]] self.EFsequenceList += [[ 'EF_FStracksMuon', [CfgGetter.getAlgorithm("TrigMuSuperEF_TMEFCombinerOnly")], 'EF_CB_FS_single' ]] self.EFsequenceList += [[ 'EF_CB_FS_single', [ TrigMuonEFRoiAggregatorConfig('TrigMuonEFFSRoiAggregator'), theTrigMuonEFCombinerMultiHypoConfig ], 'EF_CB_FS' ]] ########### Signatures ########### self.EFsignatureList += [[['EF_SA_FS'] * self.mult]] self.EFsignatureList += [[['EF_SAR_FS'] * self.mult]] self.EFsignatureList += [[['EF_FStracksMuon'] * self.mult]] self.EFsignatureList += [[['EF_CB_FS_single'] * self.mult]] self.EFsignatureList += [[['EF_CB_FS'] * self.mult]] ########### TE renaming ########## self.TErenamingDict = { 'EF_SA_FS': mergeRemovingOverlap('EF_SA_FS_', 'SAFSHypo' + hypocut + '_' + hypocutEF), 'EF_SAR_FS': mergeRemovingOverlap('EF_SAR_FS_', 'SAFSHypo' + hypocut + '_' + hypocutEF), 'EF_FStracksMuon': mergeRemovingOverlap('EF_FStracksMuon_', 'SAFSHypo' + hypocut + '_' + hypocutEF), 'EF_CB_FS_single': mergeRemovingOverlap('EF_CB_FS_single_', 'SAFSHypo' + hypocut + '_' + hypocutEF), 'EF_CB_FS': mergeRemovingOverlap('EF_CB_FS_', 'SAFSHypo' + hypocut + '_' + hypocutEF), }