ATLAS Offline Software
PixelClusteringTool.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #ifndef ACTSTRK_DATAPREPARATION_PIXEL_CLUSTERING_TOOL_H
6 #define ACTSTRK_DATAPREPARATION_PIXEL_CLUSTERING_TOOL_H
7 
8 
19 
20 
21 namespace ActsTrk {
22 
23 class PixelClusteringTool : public extends<AthAlgTool,IPixelClusteringTool> {
24 public:
25 
27  using CellCollection = std::vector<Cell>;
28 
29  struct Cluster {
30  std::vector<Identifier::value_type> ids;
31  std::vector<int> tots;
33  };
34 
35  using ClusterCollection = std::vector<Cluster>;
36 
37  PixelClusteringTool(const std::string& type,
38  const std::string& name,
39  const IInterface* parent);
40 
41  virtual StatusCode
43  const PixelID& pixelID,
44  const EventContext& ctx,
45  xAOD::PixelClusterContainer& container) const override;
46 
47  virtual StatusCode initialize() override;
48 
49 private:
50  // N.B. the cluster is added to the container
51  // and the tots and charges vectors will be moved to the xAOD object
52 
53  StatusCode makeCluster(const EventContext& ctx,
55  const PixelID& pixelID,
56  const InDetDD::SiDetectorElement* element,
57  const InDetDD::PixelModuleDesign& design,
58  const PixelChargeCalibCondData *calibData,
60  xAOD::PixelCluster& container) const;
61 
62 private:
63  ServiceHandle< InDetDD::IPixelReadoutManager > m_pixelReadout {this, "PixelReadoutManager", "ITkPixelReadoutManager",
64  "Pixel readout manager" };
65 
66  ToolHandle< InDet::PixelRDOTool > m_pixelRDOTool {this, "PixelRDOTool", "", "The Pixel RDO tool"};
67  ToolHandle< ISiLorentzAngleTool > m_pixelLorentzAngleTool {this, "PixelLorentzAngleTool", "", "Tool to retreive Lorentz angle of Pixel"};
68 
69  SG::ReadCondHandleKey<PixelChargeCalibCondData> m_chargeDataKey {this, "PixelChargeCalibCondData", "ITkPixelChargeCalibCondData",
70  "Pixel charge calibration data"};
71 
72  Gaudi::Property<bool> m_addCorners {this, "AddCorners", true};
73  Gaudi::Property<bool> m_useWeightedPos {this, "UseWeightedPosition", true};
74  Gaudi::Property<bool> m_broadErrors {this, "UseBroadErrors", false};
75 };
76 
77 } // namespace ActsTrk
78 
79 #endif // ACTS_PIXEL_CLUSTERING_TOOL_H
PixelID.h
This is an Identifier helper class for the Pixel subdetector. This class is a factory for creating co...
ActsTrk::PixelClusteringTool::m_broadErrors
Gaudi::Property< bool > m_broadErrors
Definition: PixelClusteringTool.h:74
ActsTrk::PixelClusteringTool::Cluster::tots
std::vector< int > tots
Definition: PixelClusteringTool.h:31
IPixelClusteringTool.h
ActsTrk::PixelClusteringTool::makeCluster
StatusCode makeCluster(const EventContext &ctx, PixelClusteringTool::Cluster &cluster, const PixelID &pixelID, const InDetDD::SiDetectorElement *element, const InDetDD::PixelModuleDesign &design, const PixelChargeCalibCondData *calibData, const PixelChargeCalibCondData::CalibrationStrategy calibStrategy, xAOD::PixelCluster &container) const
Definition: PixelClusteringTool.cxx:59
ActsTrk::PixelClusteringTool::m_pixelLorentzAngleTool
ToolHandle< ISiLorentzAngleTool > m_pixelLorentzAngleTool
Definition: PixelClusteringTool.h:67
InDetDD::PixelModuleDesign
Definition: PixelModuleDesign.h:48
max
constexpr double max()
Definition: ap_fixedTest.cxx:33
ActsTrk::PixelClusteringTool
Definition: PixelClusteringTool.h:23
ISiLorentzAngleTool.h
ActsTrk::PixelClusteringTool::m_useWeightedPos
Gaudi::Property< bool > m_useWeightedPos
Definition: PixelClusteringTool.h:73
ActsTrk::PixelClusteringTool::Cluster::ids
std::vector< Identifier::value_type > ids
Definition: PixelClusteringTool.h:30
python.CaloAddPedShiftConfig.type
type
Definition: CaloAddPedShiftConfig.py:42
ActsTrk::PixelClusteringTool::m_addCorners
Gaudi::Property< bool > m_addCorners
Definition: PixelClusteringTool.h:72
ActsTrk::PixelClusteringTool::m_chargeDataKey
SG::ReadCondHandleKey< PixelChargeCalibCondData > m_chargeDataKey
Definition: PixelClusteringTool.h:69
ActsTrk::PixelClusteringTool::PixelClusteringTool
PixelClusteringTool(const std::string &type, const std::string &name, const IInterface *parent)
Definition: PixelClusteringTool.cxx:53
ActsTrk::PixelClusteringTool::m_pixelReadout
ServiceHandle< InDetDD::IPixelReadoutManager > m_pixelReadout
Definition: PixelClusteringTool.h:63
PixelRDORawData.h
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
ActsTrk::PixelClusteringTool::initialize
virtual StatusCode initialize() override
Definition: PixelClusteringTool.cxx:40
PixelChargeCalibCondData
Definition: PixelChargeCalibCondData.h:24
PixelClusterContainer.h
InDetRawDataCollection
Definition: InDetRawDataCollection.h:31
test_pyathena.parent
parent
Definition: test_pyathena.py:15
PixelChargeCalibCondData::CalibrationStrategy
CalibrationStrategy
Definition: PixelChargeCalibCondData.h:34
DataVector
Derived DataVector<T>.
Definition: DataVector.h:794
IPixelReadoutManager.h
ActsTrk::PixelClusteringTool::clusterize
virtual StatusCode clusterize(const InDetRawDataCollection< PixelRDORawData > &RDOs, const PixelID &pixelID, const EventContext &ctx, xAOD::PixelClusterContainer &container) const override
Definition: PixelClusteringTool.cxx:238
ActsTrk::PixelClusteringTool::Cluster
Definition: PixelClusteringTool.h:29
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:240
ActsTrk::PixelClusteringTool::Cluster::lvl1min
int lvl1min
Definition: PixelClusteringTool.h:32
InDetDD::SiDetectorElement
Definition: SiDetectorElement.h:109
SG::ReadCondHandleKey< PixelChargeCalibCondData >
xAOD::PixelCluster_v1
Definition: PixelCluster_v1.h:17
ActsTrk::PixelClusteringTool::ClusterCollection
std::vector< Cluster > ClusterCollection
Definition: PixelClusteringTool.h:35
InDet::UnpackedPixelRDO
Definition: PixelRDOTool.h:31
PixelModuleDesign.h
ActsTrk::PixelClusteringTool::m_pixelRDOTool
ToolHandle< InDet::PixelRDOTool > m_pixelRDOTool
Definition: PixelClusteringTool.h:66
InDetRawDataCollection.h
ActsTrk
The AlignStoreProviderAlg loads the rigid alignment corrections and pipes them through the readout ge...
Definition: MuonDetectorBuilderTool.cxx:55
PixelID
Definition: PixelID.h:67
PixelChargeCalibCondData.h
ActsTrk::PixelClusteringTool::CellCollection
std::vector< Cell > CellCollection
Definition: PixelClusteringTool.h:27
ServiceHandle< InDetDD::IPixelReadoutManager >
PixelRDOTool.h