 |
ATLAS Offline Software
|
Go to the documentation of this file.
40 return StatusCode::SUCCESS;
54 return StatusCode::SUCCESS;
58 std::vector<const xAOD::TrackParticle*> xaodTracks;
60 std::vector<const Trk::Track*> origTracks;
62 std::vector<const Trk::TrackParameters*> origTrackParameters;
65 xaodTracks.push_back(
track->track());
67 if(
track->track()->track()) {
68 origTracks.push_back(
track->track()->track());
78 if(!origTracks.empty() && !origTrackParameters.empty()) {
79 ATH_MSG_ERROR(
"Inconsistent mix of Trk::Track and Trk::TrackParameter");
80 return StatusCode::FAILURE;
85 if(!origTracks.empty()) {
89 xAODvertex =
m_fitTool->fit(xaodTracks, seedPoint);
91 else if (!origTrackParameters.empty()) {
95 xAODvertex =
m_fitTool->fit(xaodTracks, seedPoint);
100 return StatusCode::SUCCESS;
119 return StatusCode::SUCCESS;
128 if (pVertex==
nullptr) {
129 ATH_MSG_WARNING(
"No primary vertex information for calculation of transverse flight path significance");
143 double sigma_fpt2 = (fpx * fpx * secVertex.covariancePosition()(
Trk::x,
Trk::x) +
144 fpx * fpy * secVertex.covariancePosition()(
Trk::x,
Trk::y) +
145 fpy * fpx * secVertex.covariancePosition()(
Trk::y,
Trk::x) +
146 fpy * fpy * secVertex.covariancePosition()(
Trk::y,
Trk::y)) / (fpt * fpt);
148 if (sigma_fpt2 <= 0.) {
153 double sign = (fpx * pTau.
p4().Px() + fpy * pTau.
p4().Py() > 0.) ? 1. : -1.;
155 return sign * fpt / std::sqrt(sigma_fpt2);
double trFlightPathSig(const xAOD::TauJet &pTau, const xAOD::Vertex &secVertex) const
determines the transverse flight path significance from the primary vertex and the secondary vertex o...
TauVertexVariables(const std::string &name)
virtual StatusCode initialize() override
Tool initializer.
Scalar perp() const
perp method - perpenticular length
Dummy class used to allow special convertors to be called for surfaces owned by a detector element.
size_t nTracks(TauJetParameters::TauTrackFlag flag=TauJetParameters::TauTrackFlag::classifiedCharged) const
const Amg::Vector3D & position() const
Returns the 3-pos.
#define ATH_MSG_VERBOSE(x)
void setVertexType(VxType::VertexType vType)
Set the type of the vertex.
ToolHandle< Trk::IVertexSeedFinder > m_SeedFinder
void setSecondaryVertex(const xAOD::VertexContainer *cont, const xAOD::Vertex *vertex)
::StatusCode StatusCode
StatusCode definition for legacy code.
void setSecondaryVertexLink(const VertexLink_t &vertexLink)
Class describing a tau jet.
ElementLink implementation for ROOT usage.
value_type push_back(value_type pElem)
Add an element to the end of the collection.
Eigen::Matrix< double, 3, 1 > Vector3D
ToolHandle< Trk::IVertexFitter > m_fitTool
Class describing a Vertex.
const Vertex * vertex() const
#define ATH_MSG_WARNING(x)
virtual FourMom_t p4() const
The full 4-momentum of the particle.
void setDetail(TauJetParameters::Detail detail, int value)
@ NotSpecified
Default value, no explicit type set.
std::vector< const TauTrack * > tracks(TauJetParameters::TauTrackFlag flag=TauJetParameters::TauTrackFlag::classifiedCharged) const
Get the v<const pointer> to a given tauTrack collection associated with this tau.
virtual StatusCode executeVertexVariables(xAOD::TauJet &pTau, xAOD::VertexContainer &pVertexContainer) const override