|
ATLAS Offline Software
|
Go to the documentation of this file.
17 declareInterface<DerivationFramework::IAugmentationTool>(
this);
19 "DecorationPrefix",
m_decPrefix,
"Prefix for the decoration name");
49 return StatusCode::SUCCESS;
56 const EventContext& ctx = Gaudi::Hive::currentContext();
62 ATH_MSG_ERROR(
"Couldn't update photon calo pointing auxdata");
63 return StatusCode::FAILURE;
75 bool found_PV =
false;
78 for (
const auto *
vertex : *vertices) {
92 pt = sqrt(vmom.Px() * vmom.Px() + vmom.Py() * vmom.Py());
95 phi = acos(vmom.Px() /
pt);
104 if(!isMomentum_available){
109 if(!isSumPt_available) vtxSumPt(*
vertex) = sumPt;
112 if(!isSumPt2_available && found_PV) vtxSumPt2(*
vertex) = sumPt2;
116 return StatusCode::SUCCESS;
float getVertexSumPt(const xAOD::Vertex *vertex, int power=1, bool useAux=true)
Loop over track particles associated with vertex and return scalar sum of pT^power in GeV (from auxda...
PhotonVertexSelectionWrapper(const std::string &t, const std::string &n, const IInterface *p)
bool isAvailable()
Test to see if this variable exists in the store, for the referenced object.
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
SG::ReadHandleKey< xAOD::VertexContainer > m_vertexContainer
Input primary vertex container.
SG::WriteDecorHandleKey< xAOD::VertexContainer > m_vtxPt
ToolHandle< CP::IPhotonPointingTool > m_photonPointingTool
PhotonPointingTool.
::StatusCode StatusCode
StatusCode definition for legacy code.
Handle class for adding a decoration to an object.
std::string m_decPrefix
Prefix for the decorations.
def asinh(x)
helper methods ---------------------------------------------------------—
TLorentzVector getVertexMomentum(const xAOD::Vertex *vertex, bool useAux=true, const std::string &derivationPrefix="")
Return vector sum of tracks associated with vertex (from auxdata if available and useAux = true)
SG::WriteDecorHandleKey< xAOD::VertexContainer > m_vtxSumPt2
SG::WriteDecorHandleKey< xAOD::VertexContainer > m_vtxSumPt
SG::WriteDecorHandleKey< xAOD::VertexContainer > m_vtxPhi
SG::ReadHandleKey< xAOD::PhotonContainer > m_photonContainer
Input photon container.
StatusCode initialize() override final
SG::WriteDecorHandleKey< xAOD::VertexContainer > m_vtxEta
virtual StatusCode addBranches() const override final
Pass the thinning service