ATLAS Offline Software
InDetBoundaryCheckTool.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
3  */
4 
5 #ifndef ATHENA_INNERDETECTOR_TOOLS_BOUNDARYCHECKTOOL
6 #define ATHENA_INNERDETECTOR_TOOLS_BOUNDARYCHECKTOOL
7 
9 
13 
17 
19 class SCT_ID;
20 
21 namespace InDet {
23  public:
25  const std::string &,
26  const std::string &,
27  const IInterface *
28  );
29 
30  virtual StatusCode initialize() override;
31  virtual StatusCode finalize() override;
32 
34  const Trk::TrackParameters &
35  ) const override;
36  private:
37  bool isAlivePixel(
38  const InDetDD::SiDetectorElement &element,
40  ) const;
41 
42  bool isAliveSCT(
43  const InDetDD::SiDetectorElement &element,
45  ) const;
46 
47  bool isBadSCTChipStrip(
49  const Identifier &,
50  const Trk::TrackParameters &,
52  ) const;
53 
56  const Trk::TrackParameters &
57  ) const;
58 
60 
62 
63  ToolHandle<IInDetConditionsTool> m_sctCondSummaryTool{
64  this,
65  "SctSummaryTool",
66  "SCT_ConditionsSummaryTool/InDetSCT_ConditionsSummaryTool",
67  "Tool to retrieve SCT Conditions summary"
68  };
69 
70  ToolHandle<IInDetTestPixelLayerTool> m_pixelLayerTool{
71  this,
72  "PixelLayerTool",
73  "InDet::InDetTestPixelLayerTool",
74  "Tool to retrieve pixel conditions summary"
75  };
76 
78 
80  Gaudi::Property<double> m_etaTol{this, "ToleranceEta", 3.0};
81  Gaudi::Property<double> m_phiTol{this, "TolerancePhi", 3.0};
82 
84  Gaudi::Property<bool> m_usePixel{this, "UsePixel", true};
85  Gaudi::Property<bool> m_useSCT{this, "UseSCT", true};
86 
88  Gaudi::Property<bool> m_checkBadSCT{this, "CheckBadSCT", true};
89 
94  {this, "SCTDetElStatus", "", "Key of SiDetectorElementStatus for SCT"};
95 
96  const SCT_ID* m_sctID{nullptr};
97 
98  };
99 
102  if (!m_sctDetElStatus.empty()) {
104  if (!sctDetElStatus.isValid()) {
105  std::stringstream msg;
106  msg << "Failed to get " << m_sctDetElStatus.key() << " from StoreGate in " << name();
107  throw std::runtime_error(msg.str());
108  }
109  }
110  return sctDetElStatus;
111  }
112 }
113 
114 #endif
InDet::InDetBoundaryCheckTool::m_etaTol
Gaudi::Property< double > m_etaTol
eta and phi tolerances
Definition: InDetBoundaryCheckTool.h:80
IInDetConditionsTool.h
TrackParameters.h
Trk::BoundaryCheckResult
BoundaryCheckResult
Definition: IBoundaryCheckTool.h:14
SiDetectorElementStatus.h
SG::ReadHandle
Definition: StoreGate/StoreGate/ReadHandle.h:70
InDet::InDetBoundaryCheckTool::m_sctID
const SCT_ID * m_sctID
Definition: InDetBoundaryCheckTool.h:96
InDet::InDetBoundaryCheckTool::m_usePixel
Gaudi::Property< bool > m_usePixel
Control usage of pixel and SCT info.
Definition: InDetBoundaryCheckTool.h:84
InDet
DUMMY Primary Vertex Finder.
Definition: VP1ErrorUtils.h:36
InDet::InDetBoundaryCheckTool::boundaryCheck
virtual Trk::BoundaryCheckResult boundaryCheck(const Trk::TrackParameters &) const override
Definition: InDetBoundaryCheckTool.cxx:207
InDet::InDetBoundaryCheckTool::isAliveSCT
bool isAliveSCT(const InDetDD::SiDetectorElement &element, const Trk::TrackParameters &parameters) const
Definition: InDetBoundaryCheckTool.cxx:66
InDet::InDetBoundaryCheckTool::m_geoModelSvc
ServiceHandle< IGeoModelSvc > m_geoModelSvc
Definition: InDetBoundaryCheckTool.h:61
SG::VarHandleKey::key
const std::string & key() const
Return the StoreGate ID for the referenced object.
Definition: AthToolSupport/AsgDataHandles/Root/VarHandleKey.cxx:141
SG::ReadHandleKey< InDet::SiDetectorElementStatus >
SG::VarHandleKey::empty
bool empty() const
Test if the key is blank.
Definition: AthToolSupport/AsgDataHandles/Root/VarHandleKey.cxx:150
Trk::IBoundaryCheckTool
Definition: IBoundaryCheckTool.h:23
InDet::InDetBoundaryCheckTool::isAlivePixel
bool isAlivePixel(const InDetDD::SiDetectorElement &element, const Trk::TrackParameters &parameters) const
Definition: InDetBoundaryCheckTool.cxx:59
IInDetTestPixelLayerTool.h
InDet::SiDetectorElementStatus
Definition: SiDetectorElementStatus.h:62
Identifier
Definition: DetectorDescription/Identifier/Identifier/Identifier.h:32
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
InDet::InDetBoundaryCheckTool::initialize
virtual StatusCode initialize() override
Definition: InDetBoundaryCheckTool.cxx:26
InDet::InDetBoundaryCheckTool::finalize
virtual StatusCode finalize() override
Definition: InDetBoundaryCheckTool.cxx:55
AthAlgTool.h
Trk::ParametersBase
Definition: ParametersBase.h:55
InDet::InDetBoundaryCheckTool::m_pixelLayerTool
ToolHandle< IInDetTestPixelLayerTool > m_pixelLayerTool
Definition: InDetBoundaryCheckTool.h:70
InDet::InDetBoundaryCheckTool::isBadSCTChipStrip
bool isBadSCTChipStrip(const InDet::SiDetectorElementStatus *, const Identifier &, const Trk::TrackParameters &, const InDetDD::SiDetectorElement &) const
Definition: InDetBoundaryCheckTool.cxx:236
SG::ReadHandle::isValid
virtual bool isValid() override final
Can the handle be successfully dereferenced?
InDet::InDetBoundaryCheckTool::m_useSCT
Gaudi::Property< bool > m_useSCT
Definition: InDetBoundaryCheckTool.h:85
InDet::InDetBoundaryCheckTool::getSCTDetElStatus
SG::ReadHandle< InDet::SiDetectorElementStatus > getSCTDetElStatus(const EventContext &ctx) const
Definition: InDetBoundaryCheckTool.h:100
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:192
InDetDD::SiDetectorElement
Definition: SiDetectorElement.h:109
SiDetectorElement.h
InDet::InDetBoundaryCheckTool::InDetBoundaryCheckTool
InDetBoundaryCheckTool(const std::string &, const std::string &, const IInterface *)
Definition: InDetBoundaryCheckTool.cxx:13
SCT_ID
Definition: SCT_ID.h:68
InDet::InDetBoundaryCheckTool::m_atlasId
const AtlasDetectorID * m_atlasId
Definition: InDetBoundaryCheckTool.h:77
AthCommonMsg< AlgTool >::msg
MsgStream & msg() const
Definition: AthCommonMsg.h:24
IBoundaryCheckTool.h
physics_parameters.parameters
parameters
Definition: physics_parameters.py:144
AthAlgTool
Definition: AthAlgTool.h:26
InDet::InDetBoundaryCheckTool::m_sctCondSummaryTool
ToolHandle< IInDetConditionsTool > m_sctCondSummaryTool
Definition: InDetBoundaryCheckTool.h:63
InDet::InDetBoundaryCheckTool::m_checkBadSCT
Gaudi::Property< bool > m_checkBadSCT
Control check of bad SCT chip (should be false for ITk Strip)
Definition: InDetBoundaryCheckTool.h:88
InDet::InDetBoundaryCheckTool::boundaryCheckSiElement
Trk::BoundaryCheckResult boundaryCheckSiElement(const InDetDD::SiDetectorElement &, const Trk::TrackParameters &) const
Definition: InDetBoundaryCheckTool.cxx:79
IGeoModelSvc.h
InDet::InDetBoundaryCheckTool::m_sctDetElStatus
SG::ReadHandleKey< InDet::SiDetectorElementStatus > m_sctDetElStatus
Optional read handle to get status data to test whether a SCT detector element is good.
Definition: InDetBoundaryCheckTool.h:94
AtlasDetectorID
This class provides an interface to generate or decode an identifier for the upper levels of the dete...
Definition: AtlasDetectorID.h:57
InDet::InDetBoundaryCheckTool::m_phiTol
Gaudi::Property< double > m_phiTol
Definition: InDetBoundaryCheckTool.h:81
InDet::InDetBoundaryCheckTool
Definition: InDetBoundaryCheckTool.h:22
ServiceHandle< IGeoModelSvc >