From a87d6f6f0b143443eb8c9d65c69e11c4c5bf62dc Mon Sep 17 00:00:00 2001 From: Russ <47442711+russbate42@users.noreply.github.com> Date: Wed, 3 Apr 2024 16:39:17 +0200 Subject: [PATCH] Added TightBad eventClean (#1677) Co-authored-by: Russell Bate --- Root/EventInfo.cxx | 6 ++++++ xAODAnaHelpers/EventInfo.h | 1 + 2 files changed, 7 insertions(+) diff --git a/Root/EventInfo.cxx b/Root/EventInfo.cxx index 2142d2cc66..8aa1cffede 100644 --- a/Root/EventInfo.cxx +++ b/Root/EventInfo.cxx @@ -54,6 +54,7 @@ void EventInfo::setTree(TTree *tree) connectBranch(tree, "SCTFlags", &m_SCTFlags); connectBranch(tree, "LArFlags", &m_LArFlags); connectBranch(tree, "eventClean_LooseBad", &m_eventClean_LooseBad); + connectBranch(tree, "eventClean_TightBad", &m_eventClean_TightBad); } if ( m_infoSwitch.m_pileup ) { @@ -160,6 +161,7 @@ void EventInfo::setBranches(TTree *tree) tree->Branch("SCTFlags", &m_SCTFlags, "SCTFlags/i"); tree->Branch("LArFlags", &m_LArFlags, "LArFlags/i"); tree->Branch("eventClean_LooseBad",&m_eventClean_LooseBad,"eventClean_LooseBad/O"); + tree->Branch("eventClean_TightBad",&m_eventClean_TightBad,"eventClean_TightBad/O"); } if ( m_infoSwitch.m_pileup ) { @@ -235,6 +237,7 @@ void EventInfo::clear() m_TileFlags = 0; m_SCTFlags = 0; m_eventClean_LooseBad = false; + m_eventClean_TightBad = false; m_mcEventWeight = 1.; m_DistEmptyBCID = -999; m_DistLastUnpairedBCID = -999; @@ -332,6 +335,9 @@ void EventInfo::FillEvent( const xAOD::EventInfo* eventInfo, xAOD::TEvent* event static SG::AuxElement::ConstAccessor< char > acc_DFCommonJets_eventClean_LooseBad("DFCommonJets_eventClean_LooseBad"); if ( acc_DFCommonJets_eventClean_LooseBad.isAvailable( *eventInfo )) m_eventClean_LooseBad = acc_DFCommonJets_eventClean_LooseBad( *eventInfo ); + static SG::AuxElement::ConstAccessor< char > acc_DFCommonJets_eventClean_TightBad("DFCommonJets_eventClean_TightBad"); + if ( acc_DFCommonJets_eventClean_TightBad.isAvailable( *eventInfo )) + m_eventClean_TightBad = acc_DFCommonJets_eventClean_TightBad( *eventInfo ); } diff --git a/xAODAnaHelpers/EventInfo.h b/xAODAnaHelpers/EventInfo.h index 374aa80e4d..0142177171 100644 --- a/xAODAnaHelpers/EventInfo.h +++ b/xAODAnaHelpers/EventInfo.h @@ -47,6 +47,7 @@ namespace xAH { uint32_t m_LArFlags; uint32_t m_SCTFlags; bool m_eventClean_LooseBad; + bool m_eventClean_TightBad; int m_mcEventNumber; int m_mcChannelNumber; float m_mcEventWeight;