9#ifndef MUONTRUTHALGS_TruthHitSummaryAlg_H
10#define MUONTRUTHALGS_TruthHitSummaryAlg_H
33 using AthReentrantAlgorithm::AthReentrantAlgorithm;
37 virtual StatusCode
execute(
const EventContext& ctx)
const override;
43 using ChamberIdMap = std::map<Muon::MuonStationIndex::ChIndex, std::vector<Identifier>>;
52 using WriteDecor_uint8_t = std::unique_ptr<SG::WriteDecorHandle<xAOD::TruthParticleContainer, uint8_t>>;
53 using llvec = std::vector<unsigned long long>;
54 using WriteDecor_llvec = std::unique_ptr<SG::WriteDecorHandle<xAOD::TruthParticleContainer, llvec>>;
59 const EventContext& ctx) :
140 this,
"PRD_TruthMaps", {
"CSC_TruthMap",
"RPC_TruthMap",
"TGC_TruthMap",
"MDT_TruthMap"},
"remove NSW by default for now, can always be changed in the configuration"};
Property holding a SG store/key/clid from which a ReadHandle is made.
Property holding a SG store/key/clid/attr name from which a WriteDecorHandle is made.
Handle class for adding a decoration to an object.
An algorithm that can be simultaneously executed in multiple threads.
std::map< Muon::MuonStationIndex::ChIndex, std::vector< Identifier > > ChamberIdMap
This map contains all the hits corresponding to truth muons classified by chamber layer that recorded...
WriteDecorKey_t m_phiLayer3HitsKey
virtual StatusCode execute(const EventContext &ctx) const override
WriteDecorKey_t m_outerLargeHitsKey
WriteDecorKey_t m_truthStgcHitsKey
StatusCode addHitIDVectors(const xAOD::TruthParticle &truthParticle, const ChamberIdMap &ids, summaryDecors &myDecors) const
This function collapses the information given by the ChamberIdMap, which contains all hits from a tru...
SG::ReadHandleKey< xAOD::TruthParticleContainer > m_muonTruth
Key of the container of truth muons.
WriteDecorKey_t m_middleLargeHitsKey
WriteDecorKey_t m_etaLayer1HitsKey
WriteDecorKey_t m_phiLayer1HitsKey
virtual StatusCode initialize() override
ServiceHandle< Muon::IMuonIdHelperSvc > m_idHelperSvc
Handle for muonIdHelper service.
WriteDecorKey_t m_ntrigEtaLayersKey
WriteDecorKey_t m_extendedSmallHitsKey
WriteDecorKey_t m_truthMMHitsKey
WriteDecorKey_t m_truthMdtHitsKey
std::vector< unsigned long long > llvec
WriteDecorKey_t m_phiLayer2HitsKey
WriteDecorKey_t m_truthTgcHitsKey
WriteDecorKey_t m_nphiLayersKey
WriteDecorKey_t m_innerSmallHitsKey
WriteDecorKey_t m_extendedLargeHitsKey
std::unique_ptr< SG::WriteDecorHandle< xAOD::TruthParticleContainer, llvec > > WriteDecor_llvec
WriteDecorKey_t m_nprecLayersKey
WriteDecorKey_t m_truthCscHitsKey
SG::ReadHandleKeyArray< PRD_MultiTruthCollection > m_PRD_TruthNames
Keys for the containers of truth hits, grouped by detector technology.
WriteDecorKey_t m_phiLayer4HitsKey
WriteDecorKey_t m_truthRpcHitsKey
WriteDecorKey_t m_etaLayer2HitsKey
WriteDecorKey_t m_innerLargeHitsKey
WriteDecorKey_t m_etaLayer3HitsKey
WriteDecorKey_t m_middleSmallHitsKey
std::unique_ptr< SG::WriteDecorHandle< xAOD::TruthParticleContainer, uint8_t > > WriteDecor_uint8_t
Struct object encapsulating all write-decorators.
WriteDecorKey_t m_etaLayer4HitsKey
WriteDecorKey_t m_outerSmallHitsKey
StatusCode addHitCounts(const EventContext &ctx, const xAOD::TruthParticle &truthParticle, ChamberIdMap &ids, summaryDecors &myDecors) const
This is the actual function that decorates truth muons with hit counts.
SG::WriteDecorHandleKey< xAOD::TruthParticleContainer > WriteDecorKey_t
Key for each write-decorator.
friend struct summaryDecors
Property holding a SG store/key/clid from which a ReadHandle is made.
Property holding a SG store/key/clid/attr name from which a WriteDecorHandle is made.
NRpcCablingAlg reads raw condition data and writes derived condition data to the condition store.
DecorHandlePtr_wt< ContType, DataType > makeHandle(const EventContext &ctx, const SG::WriteDecorHandleKey< ContType > &key, const DataType defVal={})
Returns a unique_ptr with an initialized WriteDecorHandle.
HandleKeyArray< ReadHandle< T >, ReadHandleKey< T >, Gaudi::DataHandle::Reader > ReadHandleKeyArray
TruthParticle_v1 TruthParticle
Typedef to implementation.
WriteDecor_uint8_t phiLayer3HitsDecor
WriteDecor_llvec truthTgcHitsDecor
WriteDecor_llvec truthRpcHitsDecor
WriteDecor_uint8_t extendedLargeHitsDecor
WriteDecor_uint8_t etaLayer3HitsDecor
WriteDecor_uint8_t phiLayer1HitsDecor
WriteDecor_llvec truthMdtHitsDecor
WriteDecor_uint8_t innerLargeHitsDecor
WriteDecor_uint8_t middleLargeHitsDecor
WriteDecor_uint8_t innerSmallHitsDecor
const TruthHitSummaryAlg * m_parent
WriteDecor_uint8_t etaLayer2HitsDecor
WriteDecor_uint8_t extendedSmallHitsDecor
WriteDecor_uint8_t ntrigEtaLayersDecor
WriteDecor_uint8_t etaLayer4HitsDecor
WriteDecor_llvec truthMMHitsDecor
WriteDecor_uint8_t nprecLayersDecor
WriteDecor_uint8_t nphiLayersDecor
WriteDecor_uint8_t outerSmallHitsDecor
WriteDecor_llvec truthCscHitsDecor
summaryDecors(const TruthHitSummaryAlg *parent, const EventContext &ctx)
WriteDecor_uint8_t etaLayer1HitsDecor
WriteDecor_uint8_t phiLayer2HitsDecor
const EventContext & m_ctx
WriteDecor_uint8_t outerLargeHitsDecor
WriteDecor_uint8_t middleSmallHitsDecor
WriteDecor_uint8_t phiLayer4HitsDecor
WriteDecor_llvec truthStgcHitsDecor