Commit b9928ca9 authored by Savanna Shaw's avatar Savanna Shaw
Browse files

Add dimuon invariant mass chain to LS2 menu

Some modifcations to get a dimuon chain with invariant mass cuts running:

- Setup the sequence for the invariant mass so that it is independent of the muon reco sequences
- Set the chains step with the invariant mass cut to have multiplicity of one to avoid it being treated as a combined hypo
- Some minor fixes for the hypo alg to allow for one-muon-per-RoI, and to not overwrite the feature link
- Added a test chain to the menu and updated the references.
parent 50f31578
......@@ -177,6 +177,7 @@ HLTConfigSvc::initialize() {
dummyChains["HLT_2mu6_L12MU6"] = "L1_2MU6";
dummyChains["HLT_2mu6Comb_L12MU6"] = "L1_2MU6";
dummyChains["HLT_2mu6_bJpsimumu_L12MU6"] = "L1_2MU6";
dummyChains["HLT_2mu6_10invm70_L1MU6"] = "L1_2MU6";
dummyChains["HLT_3j200_L1J20"] = "L1_J20";
dummyChains["HLT_5j70_0eta240_L14J20"] = "L1_4J20";
dummyChains["HLT_e3_etcut1step_mu6fast_L1EM8I_MU10"] = "L1_EM8I_MU10";
......
......@@ -80,7 +80,7 @@ StatusCode TrigMuonEFInvMassHypoAlg::execute( const EventContext& context ) cons
ATH_MSG_DEBUG( "Muinfo handle size: " << muonHandle->size() << " ..." );
// It is posisble that no muons are found, in this case we go to the next decision
if(muonHandle->size()<2) continue;
if(muonHandle->size()<1) continue;
muonDec.first = muonHandle.ptr();
muonDec.second = previousDecision;
vecMuDec.push_back(muonDec);
......@@ -109,7 +109,7 @@ StatusCode TrigMuonEFInvMassHypoAlg::execute( const EventContext& context ) cons
const ElementLink<xAOD::MuonContainer> muonEL1 = ElementLink<xAOD::MuonContainer>( *muonCont1, mu1->index() );
const ElementLink<xAOD::MuonContainer> muonEL2 = ElementLink<xAOD::MuonContainer>( *muonCont2, mu2->index() );
newd -> setObjectLink( featureString(), muonEL1 );
newd -> setObjectLink( featureString(), muonEL2 );
newd -> setObjectLink( "secondFeature", muonEL2 );
TrigCompositeUtils::linkToPrevious( newd, dec1, context );
TrigCompositeUtils::linkToPrevious( newd, dec2, context );
......
......@@ -6,14 +6,12 @@ TrigSignatureMoniMT INFO HLT_2g35_etcut_L12EM20VH
TrigSignatureMoniMT INFO HLT_2g35_etcut_L12EM20VH decisions 5 5 2 0 0
TrigSignatureMoniMT INFO HLT_2j330_a10t_lcw_jes_35smcINF_L1J1004 4 0 0 0 0 0 0
TrigSignatureMoniMT INFO HLT_2j330_a10t_lcw_jes_35smcINF_L1J100 decisions 0 0 0 0 0
TrigSignatureMoniMT INFO HLT_2mu10_bJpsimumu_L12MU10 3 3 3 0 0 0 0 0
TrigSignatureMoniMT INFO HLT_2mu10_bJpsimumu_L12MU10 decisions 18 0 0 0 0
TrigSignatureMoniMT INFO HLT_2mu10_bUpsimumu_L12MU10 3 3 3 0 0 0 0 0
TrigSignatureMoniMT INFO HLT_2mu10_bUpsimumu_L12MU10 decisions 18 0 0 0 0
TrigSignatureMoniMT INFO HLT_2mu14_L12MU10 3 3 3 1 1 1 0 1
TrigSignatureMoniMT INFO HLT_2mu14_L12MU10 decisions 18 6 4 4 0
TrigSignatureMoniMT INFO HLT_2mu6Comb_L12MU6 4 4 4 1 0 0 0 1
TrigSignatureMoniMT INFO HLT_2mu6Comb_L12MU6 decisions 24 6 0 0 0
TrigSignatureMoniMT INFO HLT_2mu6_10invm70_L1MU6 10 10 4 1 1 1 1 1
TrigSignatureMoniMT INFO HLT_2mu6_10invm70_L1MU6 decisions 24 6 4 4 1
TrigSignatureMoniMT INFO HLT_2mu6_L12MU6 4 4 4 1 1 1 0 1
TrigSignatureMoniMT INFO HLT_2mu6_L12MU6 decisions 24 6 4 4 0
TrigSignatureMoniMT INFO HLT_3j200_L1J100 4 4 0 0 0 0 0 0
......
......@@ -502,6 +502,8 @@ TrigSignatureMoniMT INFO HLT_2mu14_L12MU10
TrigSignatureMoniMT INFO HLT_2mu14_L12MU10 decisions 0 0 0 0 0
TrigSignatureMoniMT INFO HLT_2mu6Comb_L12MU6 20 20 0 0 0 0 0 0
TrigSignatureMoniMT INFO HLT_2mu6Comb_L12MU6 decisions 0 0 0 0 0
TrigSignatureMoniMT INFO HLT_2mu6_10invm70_L1MU6 20 20 0 0 0 0 0 0
TrigSignatureMoniMT INFO HLT_2mu6_10invm70_L1MU6 decisions 0 0 0 0 0
TrigSignatureMoniMT INFO HLT_2mu6_L12MU6 20 20 0 0 0 0 0 0
TrigSignatureMoniMT INFO HLT_2mu6_L12MU6 decisions 0 0 0 0 0
TrigSignatureMoniMT INFO HLT_3j200_L1J100 20 20 0 0 0 0 0 0
......
......@@ -55,6 +55,8 @@ def setupMenu():
ChainProp(name='HLT_mu6noL1_L1MU6', l1SeedThresholds=[''], groups=SingleMuonGroup),
ChainProp(name='HLT_mu6_msonly_L1MU6', groups=SingleMuonGroup),
ChainProp(name='HLT_2mu6_10invm70_L1MU6', groups=SingleMuonGroup),
# ATR-20049
ChainProp(name='HLT_mu26_ivarmedium_L1MU20', groups=SingleMuonGroup),
ChainProp(name='HLT_mu50_L1MU20', groups=SingleMuonGroup),
......
......@@ -9,9 +9,10 @@ from AthenaCommon.Logging import logging
logging.getLogger().info("Importing %s",__name__)
log = logging.getLogger("TriggerMenuMT.HLTMenuConfig.Muon.MuonDef")
from TriggerMenuMT.HLTMenuConfig.Menu.ChainConfigurationBase import ChainConfigurationBase
from TriggerMenuMT.HLTMenuConfig.Menu.ChainConfigurationBase import ChainConfigurationBase, RecoFragmentsPool
from TriggerMenuMT.HLTMenuConfig.Menu.MenuComponents import ChainStep
from TriggerMenuMT.HLTMenuConfig.Muon.MuonSequenceSetup import muFastSequence, muFastOvlpRmSequence, muCombSequence, muCombOvlpRmSequence, muEFMSSequence, muEFSASequence, muIsoSequence, muEFCBSequence, muEFSAFSSequence, muEFCBFSSequence, muEFIsoSequence, muEFCBInvMassSequence, muEFCBInvMassFSSequence
from TriggerMenuMT.HLTMenuConfig.Muon.MuonSequenceSetup import muFastSequence, muFastOvlpRmSequence, muCombSequence, muCombOvlpRmSequence, muEFMSSequence, muEFSASequence, muIsoSequence, muEFCBSequence, muEFSAFSSequence, muEFCBFSSequence, muEFIsoSequence, muEFCBInvMassSequence
......@@ -51,9 +52,6 @@ def FSmuEFSASequenceCfg(flags):
def FSmuEFCBSequenceCfg(flags):
return muEFCBFSSequence()
def FSmuEFCBInvMSequenceCfg(flags):
return muEFCBInvMassFSSequence()
def muEFIsoSequenceCfg(flags):
return muEFIsoSequence()
......@@ -84,6 +82,12 @@ class MuonChainConfiguration(ChainConfigurationBase):
for step in step_level:
chainSteps+=[step]
if 'invm' in self.chainPart['invMassInfo']:
steps=stepDictionary['invM']
for step_level in steps:
for step in step_level:
chainSteps+=[step]
myChain = self.buildChain(chainSteps)
return myChain
......@@ -107,6 +111,7 @@ class MuonChainConfiguration(ChainConfigurationBase):
"noL1":[[],[self.getFSmuEFSA(), self.getFSmuEFCB()]],
"msonly":[[self.getmuFast(), self.getmuMSEmpty(1)], [self.getmuEFMS()]],
"ivarmedium":[[self.getmuFast(), self.getmuComb()], [self.getmuEFSA(), self.getmuEFCB(), self.getmuEFIso()]],
"invM":[[],[self.getmuInvM()]],
}
return stepDictionary
......@@ -160,10 +165,7 @@ class MuonChainConfiguration(ChainConfigurationBase):
# --------------------
def getmuEFCB(self):
if 'invm' in self.chainPart['invMassInfo']:
return self.getStep(4,'EFCBinvM', [muEFCBInvMSequenceCfg])
else:
return self.getStep(4,'EFCB', [muEFCBSequenceCfg])
return self.getStep(4,'EFCB', [muEFCBSequenceCfg])
# --------------------
def getFSmuEFSA(self):
......@@ -171,10 +173,7 @@ class MuonChainConfiguration(ChainConfigurationBase):
# --------------------
def getFSmuEFCB(self):
if 'invm' in self.chainPart['invMassInfo']:
return self.getStep(2,'FSmuEFCB', [FSmuEFCBInvMSequenceCfg])
else:
return self.getStep(2,'FSmuEFCB', [FSmuEFCBSequenceCfg])
return self.getStep(2,'FSmuEFCB', [FSmuEFCBSequenceCfg])
#---------------------
def getmuEFIso(self):
......@@ -184,4 +183,11 @@ class MuonChainConfiguration(ChainConfigurationBase):
def getmuMSEmpty(self, stepID):
return self.getStep(stepID,'muMS_empty',[])
#--------------------
def getmuInvM(self):
stepName = 'Step5_muInvM'
log.debug("Configuring step " + stepName)
seq = RecoFragmentsPool.retrieve( muEFCBInvMSequenceCfg, None)
return ChainStep(stepName, [seq], multiplicity=1)
......@@ -295,21 +295,32 @@ def muEFCBSequence():
########################
def muEFCBInvMassSequence():
(muonEFCBSequence, efcbViewsMaker, sequenceOut) = RecoFragmentsPool.retrieve(muEFCBAlgSequence, ConfigFlags)
# setup EFCB hypo
from TrigMuonHypoMT.TrigMuonHypoMTConfig import TrigMuonEFCombinerHypoAlg, TrigMuonEFInvMassHypoAlg, TrigMuonEFInvMassHypoToolFromDict
trigMuonEFCBHypo = TrigMuonEFCombinerHypoAlg( "TrigMuonEFCombinerInvMHypoAlg" )
trigMuonEFCBHypo.MuonDecisions = sequenceOut
from AthenaCommon import CfgMgr
invMassRecoSequence = parOR("muInvMViewNode")
from TrigMuonHypoMT.TrigMuonHypoMTConfig import TrigMuonEFCombinerHypoToolFromDict
invMViewsMaker = EventViewCreatorAlgorithm("IMmuinvm")
invMViewsMaker.ViewFallThrough = True
invMViewsMaker.RoIsLink = "initialRoI" # -||-
invMViewsMaker.InViewRoIs = "muInvMRoIs" # contract with the consumer
invMViewsMaker.Views = "muInvMViewRoIs"
invMViewsMaker.ViewNodeName = invMassRecoSequence.name()
invMViewsMaker.RequireParentView = True
ViewVerifyEFCB = CfgMgr.AthViews__ViewDataVerifier("muInvMViewDataVerifier")
ViewVerifyEFCB.DataObjects = [( 'xAOD::MuonContainer' , 'StoreGateSvc+'+muNames.EFCBName )]
invMassRecoSequence += ViewVerifyEFCB
invMassSequence = seqAND( "muInvMSequence", [invMViewsMaker, invMassRecoSequence] )
from TrigMuonHypoMT.TrigMuonHypoMTConfig import TrigMuonEFInvMassHypoAlg, TrigMuonEFInvMassHypoToolFromDict
trigMuonEFInvMHypo = TrigMuonEFInvMassHypoAlg( "TrigMuonEFInvMassHypoAlg" )
trigMuonEFInvMHypo.MuonDecisions = sequenceOut
return MenuSequence( Sequence = muonEFCBSequence,
Maker = efcbViewsMaker,
Hypo = [trigMuonEFCBHypo, trigMuonEFInvMHypo],
HypoToolGen = [TrigMuonEFCombinerHypoToolFromDict, TrigMuonEFInvMassHypoToolFromDict] )
trigMuonEFInvMHypo.MuonDecisions = muNames.EFCBName
return MenuSequence( Sequence = invMassSequence,
Maker = invMViewsMaker,
Hypo = trigMuonEFInvMHypo,
HypoToolGen = TrigMuonEFInvMassHypoToolFromDict )
######################
### EF SA full scan ###
......@@ -389,29 +400,6 @@ def muEFCBFSSequence():
HypoToolGen = TrigMuonEFCombinerHypoToolFromDict )
######################
### EF CB FS with ##
### dimuon mass cut ##
######################
def muEFCBInvMassFSSequence():
(muonEFCBFSSequence, efcbfsInputMaker, sequenceOut) = RecoFragmentsPool.retrieve(muEFCBFSAlgSequence, ConfigFlags)
# setup EFCB hypo
from TrigMuonHypoMT.TrigMuonHypoMTConfig import TrigMuonEFCombinerHypoAlg, TrigMuonEFInvMassHypoAlg, TrigMuonEFInvMassHypoToolFromDict
trigMuonEFCBFSHypo = TrigMuonEFCombinerHypoAlg( "TrigMuonEFFSCombinerInvMHypoAlg" )
trigMuonEFCBFSHypo.MuonDecisions = sequenceOut
from TrigMuonHypoMT.TrigMuonHypoMTConfig import TrigMuonEFCombinerHypoToolFromDict
trigMuonEFInvMHypo = TrigMuonEFInvMassHypoAlg( "TrigMuonEFFSInvMassHypoAlg" )
trigMuonEFInvMHypo.MuonDecisions = sequenceOut
return MenuSequence( Sequence = muonEFCBFSSequence,
Maker = efcbfsInputMaker,
Hypo = [trigMuonEFCBFSHypo, trigMuonEFInvMHypo],
HypoToolGen = [TrigMuonEFCombinerHypoToolFromDict, TrigMuonEFInvMassHypoToolFromDict] )
######################
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment