ATLAS Offline Software
Loading...
Searching...
No Matches
StripClusterTruthDecoratorAlg.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3*/
4
6// Header file for class StipClusterTruthDecoratorAlg
7//
8// The algorithm extends xAOD::StripClusterContainer
9// with additional decorations associated to truth information
10// And stores the results in a TrackMeasurementValidationContainer
11// for compatibility with monitoring tools
13
14#ifndef STRIPCLUSTERTRUTHDECORATORALG_H
15#define STRIPCLUSTERTRUTHDECORATORALG_H
16
18#include "GaudiKernel/ServiceHandle.h"
21
25
29
30#include "Identifier/Identifier.h"
32
35
36namespace ActsTrk {
37
39 public:
40 StripClusterTruthDecoratorAlg(const std::string &name,ISvcLocator *pSvcLocator);
41 virtual ~StripClusterTruthDecoratorAlg() = default;
42
43 virtual StatusCode initialize() override;
44 virtual StatusCode execute(const EventContext& ctx) const override;
45
46 private:
47 // This function is used to mark the clusters and decide which one to keep
48 // and which one to skip. It does so by filling a std::vector<bool>, which
49 // size is the same as the cluster collection.
50 StatusCode labelMeasurementToKeep(const EventContext& ctx,
51 const xAOD::StripClusterContainer& clusters,
52 std::vector<bool>& labels) const;
53
54 private:
55 SG::ReadHandleKey<xAOD::StripClusterContainer> m_clustercontainer_key{this,"ClusterContainer", "", "Input Strip Cluster container"};
56 SG::ReadHandleKey<MeasurementToTruthParticleAssociation> m_associationMap_key{this,"AssociationMapOut", "", "Association map between measurements and truth particles"};
57 SG::ReadCondHandleKey<InDetDD::SiDetectorElementCollection> m_stripDetEleCollKey{this, "StripDetectorElements", "ITkStripDetectorElementCollection"};
58
59 SG::ReadHandleKeyArray< xAOD::TrackParticleContainer > m_trackParticlesKey {this, "TrackParticles", {}, "Input xAOD::TrackParticles"};
60
61 SG::WriteHandleKey<xAOD::TrackMeasurementValidationContainer> m_write_xaod_key{this,"MeasurementContainer","", "Output Strip Validation Clusters"};
62
64
67
83
84 Gaudi::Property<bool> m_useTruthInfo {this, "UseTruthInfo", true};
85 Gaudi::Property<bool> m_keepOnlyOnTrackMeasurements {this, "KeepOnlyOnTrackMeasurements", false, "Keep on on-track measurements instead of the full collection"};
86
87 const SCT_ID* m_stripHelper {nullptr};
88 };
89}
90
91
92#endif
This is an Identifier helper class for the SCT subdetector.
Property holding a SG store/key/clid/attr name from which a ReadDecorHandle 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.
SG::ReadCondHandleKey< InDetDD::SiDetectorElementCollection > m_stripDetEleCollKey
SG::WriteDecorHandleKey< xAOD::TrackMeasurementValidationContainer > m_measurement_phi_module
SG::WriteDecorHandleKey< xAOD::TrackMeasurementValidationContainer > m_measurement_SiWidth
SG::WriteDecorHandleKey< xAOD::TrackMeasurementValidationContainer > m_measurement_layer
SG::WriteDecorHandleKey< xAOD::TrackMeasurementValidationContainer > m_measurement_eta_module
virtual StatusCode execute(const EventContext &ctx) const override
SG::WriteDecorHandleKey< xAOD::TrackMeasurementValidationContainer > m_measurement_centroid_xeta
SG::WriteDecorHandleKey< xAOD::TrackMeasurementValidationContainer > m_measurement_detectorElementID
SG::ReadHandleKey< xAOD::StripClusterContainer > m_clustercontainer_key
virtual ~StripClusterTruthDecoratorAlg()=default
SG::WriteDecorHandleKey< xAOD::TrackMeasurementValidationContainer > m_measurement_side
StripClusterTruthDecoratorAlg(const std::string &name, ISvcLocator *pSvcLocator)
SG::ReadHandleKeyArray< xAOD::TrackParticleContainer > m_trackParticlesKey
SG::WriteDecorHandleKey< xAOD::TrackMeasurementValidationContainer > m_measurement_waferID
SG::WriteHandleKey< xAOD::TrackMeasurementValidationContainer > m_write_xaod_key
SG::WriteDecorHandleKey< xAOD::TrackMeasurementValidationContainer > m_measurement_sizePhi
SG::WriteDecorHandleKey< xAOD::StripClusterContainer > m_trackMeasurement_link
SG::WriteDecorHandleKey< xAOD::TrackMeasurementValidationContainer > m_measurement_LorentzShift
SG::WriteDecorHandleKey< xAOD::TrackMeasurementValidationContainer > m_measurement_sizeZ
SG::WriteDecorHandleKey< xAOD::TrackMeasurementValidationContainer > m_measurement_omegay
SG::WriteDecorHandleKey< xAOD::TrackMeasurementValidationContainer > m_measurement_centroid_xphi
StatusCode labelMeasurementToKeep(const EventContext &ctx, const xAOD::StripClusterContainer &clusters, std::vector< bool > &labels) const
SG::WriteDecorHandleKey< xAOD::TrackMeasurementValidationContainer > m_measurement_omegax
SG::WriteDecorHandleKey< xAOD::TrackMeasurementValidationContainer > m_measurement_bec
SG::WriteDecorHandleKey< xAOD::TrackMeasurementValidationContainer > m_measurement_truth_barcodes
SG::ReadHandleKey< MeasurementToTruthParticleAssociation > m_associationMap_key
SG::WriteDecorHandleKey< xAOD::TrackMeasurementValidationContainer > m_measurement_truth_indices
An algorithm that can be simultaneously executed in multiple threads.
This is an Identifier helper class for the SCT subdetector.
Definition SCT_ID.h:68
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.
Property holding a SG store/key/clid from which a WriteHandle is made.
The AlignStoreProviderAlg loads the rigid alignment corrections and pipes them through the readout ge...
HandleKeyArray< ReadHandle< T >, ReadHandleKey< T >, Gaudi::DataHandle::Reader > ReadHandleKeyArray
StripClusterContainer_v1 StripClusterContainer
Define the version of the strip cluster container.