Skip to content
Snippets Groups Projects
Commit c42782ee authored by Baptiste Ravina's avatar Baptiste Ravina Committed by Tadej Novak
Browse files

CPAlgorithms: two fixes for the global trigger SFs

CPAlgorithms: two fixes for the global trigger SFs
parent ec3e74b4
No related branches found
No related tags found
29 merge requests!78241Draft: FPGATrackSim: GenScan code refactor,!78236Draft: Switching Streams https://its.cern.ch/jira/browse/ATR-27417,!78056AFP monitoring: new synchronization and cleaning,!78041AFP monitoring: new synchronization and cleaning,!77990Updating TRT chip masks for L1TRT trigger simulation - ATR-28372,!77733Draft: add new HLT NN JVT, augmented with additional tracking information,!77731Draft: Updates to ZDC reconstruction,!77728Draft: updates to ZDC reconstruction,!77522Draft: sTGC Pad Trigger Emulator,!76725ZdcNtuple: Fix cppcheck warning.,!76611L1CaloFEXByteStream: Fix out-of-bounds array accesses.,!76475Punchthrough AF3 implementation in FastG4,!76474Punchthrough AF3 implementation in FastG4,!76343Draft: MooTrackBuilder: Recalibrate NSW hits in refine method,!75729New implementation of ZDC nonlinear FADC correction.,!75703Draft: Update to HI han config for HLT jets,!75184Draft: Update file heavyions_run.config,!74430Draft: Fixing upper bound for Delayed Jet Triggers,!73963Changing the path of the histograms to "Expert" area,!73875updating ID ART reference plots,!73874AtlasCLHEP_RandomGenerators: Fix cppcheck warnings.,!73449Add muon detectors to DarkJetPEBTLA partial event building,!73343Draft: [TrigEgamma] Add photon ringer chains on bootstrap mechanism,!72336Fixed TRT calibration crash,!72176Draft: Improving L1TopoOnline chain that now gets no-empty plots. Activating it by default,!72012Draft: Separate JiveXMLConfig.py into Config files,!71876Fix MET trigger name in MissingETMonitoring,!71820Draft: Adding new TLA End-Of-Fill (EOF) chains and removing obsolete DIPZ chains,!71434CPAlgorithms: two fixes for the global trigger SFs
......@@ -103,7 +103,7 @@ Trigger:
triggerChainsPerYear:
'2015':
- 'HLT_e24_lhmedium_L1EM20VH || HLT_e60_lhmedium || HLT_e120_lhloose'
- 'HLT_mu20_iloose_L1MU15 || HLT_mu50'
- 'HLT_mu20_iloose_L1MU15 || HLT_mu40'
- 'HLT_2g20_tight'
'2016':
- 'HLT_e26_lhtight_nod0_ivarloose || HLT_e60_lhmedium_nod0 || HLT_e140_lhloose_nod0'
......
......@@ -10,7 +10,7 @@ from AnalysisAlgorithmsConfig.ConfigAccumulator import ConfigAccumulator, DataTy
# Config:
triggerChainsPerYear = {
'2015': ['HLT_e24_lhmedium_L1EM20VH || HLT_e60_lhmedium || HLT_e120_lhloose', 'HLT_mu20_iloose_L1MU15 || HLT_mu50', 'HLT_2g20_tight'],
'2015': ['HLT_e24_lhmedium_L1EM20VH || HLT_e60_lhmedium || HLT_e120_lhloose', 'HLT_mu20_iloose_L1MU15 || HLT_mu40', 'HLT_2g20_tight'],
'2016': ['HLT_e26_lhtight_nod0_ivarloose || HLT_e60_lhmedium_nod0 || HLT_e140_lhloose_nod0', 'HLT_mu26_ivarmedium || HLT_mu50', 'HLT_g35_loose_g25_loose'],
'2017': ['HLT_e26_lhtight_nod0_ivarloose || HLT_e60_lhmedium_nod0 || HLT_e140_lhloose_nod0', 'HLT_2g22_tight_L12EM15VHI', 'HLT_mu50'],
'2018': ['HLT_e26_lhtight_nod0_ivarloose || HLT_e60_lhmedium_nod0 || HLT_e140_lhloose_nod0', 'HLT_g35_medium_g25_medium_L12EM20VH', 'HLT_mu26_ivarmedium', 'HLT_2mu14'],
......
......@@ -128,8 +128,8 @@ StatusCode CP::TrigGlobalEfficiencyAlg::initialize()
handles.push_back(t->getHandle());
std::string name = handles[handles.size()-1].name();
legsPerTool[name] = triggers;
// and add the efficiency systematics (not SF!)
if (!isSFTool) ANA_CHECK(m_systematicsList.addSystematics( *handles[handles.size()-1] ));
// and add the systematics
ANA_CHECK(m_systematicsList.addSystematics( *handles[handles.size()-1] ));
}
}
}
......@@ -158,8 +158,8 @@ StatusCode CP::TrigGlobalEfficiencyAlg::initialize()
handles.push_back(t->getHandle());
std::string name = handles[handles.size()-1].name();
legsPerTool[name] = triggers;
// and add the efficiency systematics (not SF!)
if (!isSFTool) ANA_CHECK(m_systematicsList.addSystematics( *handles[handles.size()-1] ));
// and add the systematics
ANA_CHECK(m_systematicsList.addSystematics( *handles[handles.size()-1] ));
}
}
}
......
......@@ -152,6 +152,13 @@ class TriggerAnalysisSFBlock (ConfigBlock):
def makeAlgs (self, config) :
if (self.multiTriggerChainsPerYear and self.triggerChainsPerYear and
self.triggerChainsPerYear is not self.multiTriggerChainsPerYear.get('')):
raise Exception('multiTriggerChainsPerYear and triggerChainsPerYear cannot be configured at the same time!')
if self.triggerChainsPerYear and not self.multiTriggerChainsPerYear:
self.multiTriggerChainsPerYear = {'': self.triggerChainsPerYear}
# Create the decision algorithm, keeping track of the decision tool for later
decisionTool = self.makeTriggerDecisionTool(config)
......@@ -160,7 +167,7 @@ class TriggerAnalysisSFBlock (ConfigBlock):
# Calculate multi-lepton (electron/muon/photon) trigger efficiencies and SFs
if self.multiTriggerChainsPerYear and not self.noGlobalTriggerEff:
for suffix, trigger_chains in self.multiTriggerChainsPerYear:
for suffix, trigger_chains in self.multiTriggerChainsPerYear.items():
self.triggerChainsPerYear = trigger_chains
self.makeTriggerGlobalEffCorrAlg(config, matchingTool, self.noEffSF, suffix)
......
......@@ -1056,7 +1056,9 @@ CP::SystematicSet TrigGlobalEfficiencyCorrectionTool::recommendedSystematics() c
StatusCode TrigGlobalEfficiencyCorrectionTool::applySystematicVariation(const CP::SystematicSet& systematic)
{
for (auto&& t: m_suppliedElectronEfficiencyTools) ANA_CHECK(t->applySystematicVariation(systematic));
for (auto&& t: m_suppliedElectronScaleFactorTools) ANA_CHECK(t->applySystematicVariation(systematic));
for (auto&& t: m_suppliedPhotonEfficiencyTools) ANA_CHECK(t->applySystematicVariation(systematic));
for (auto&& t: m_suppliedPhotonScaleFactorTools) ANA_CHECK(t->applySystematicVariation(systematic));
for (auto&& t: m_suppliedMuonTools) ANA_CHECK(t->applySystematicVariation(systematic));
return StatusCode::SUCCESS;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment