25 m_aod(
"VxPrimaryCandidate"),
48 return StatusCode::SUCCESS;
54 if (!
m_aod.isValid()) {
56 return StatusCode::SUCCESS;
63 m_xaodout = std::make_unique<xAOD::VertexContainer>();
64 m_xauxout = std::make_unique<xAOD::VertexAuxContainer>();
74 auto itr =
m_aod->cbegin();
75 auto end =
m_aod->cend();
78 for( ; itr != end; ++itr ) {
83 const Amg::Vector3D& position = (*itr)->recVertex().position();
84 vertex->setPosition(position);
86 const AmgSymMatrix(3)& covariance = (*itr)->recVertex().covariancePosition();
87 vertex->setCovariancePosition(covariance);
89 vertex->setFitQuality((*itr)->recVertex().fitQuality().chiSquared(),
static_cast<float>((*itr)->recVertex().fitQuality().doubleNumberDoF ()));
93 unsigned int VTAVsize = (*itr)->vxTrackAtVertex()->size();
94 for (
unsigned int i = 0 ; i < VTAVsize ; ++i)
114 ATH_MSG_DEBUG (
"Cast of element link failed, skip this VxTrack/NeutralAtVertex !!!!!");
120 return StatusCode::SUCCESS;
Helpers for checking error return status codes and reporting errors.
#define AmgSymMatrix(dim)
AthAlgorithm(const std::string &name, ISvcLocator *pSvcLocator)
Constructor with parameters:
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T, V, H > &t)
ElementLink implementation for ROOT usage.
void resetWithKeyAndIndex(const ID_type &dataID, index_type elemID, IProxyDict *sg=0)
Set the link to an element given by string key and index.
index_type index() const
Get the index of the element inside of its container.
An abstract class which is meant to represent an element link to the Trk::Track or Trk::TrackParticle...
Element link to XAOD NeutralParticle.
The VxTrackAtVertex is a common class for all present TrkVertexFitters The VxTrackAtVertex is designe...
double vtxCompatibility(void) const
Information about fast compatibility estimation, to be given to the annealing.
const ITrackLink * trackOrParticleLink(void) const
VertexCnvAlg(const std::string &name, ISvcLocator *svcLoc)
Regular algorithm constructor.
virtual StatusCode initialize()
Function initialising the algorithm.
SG::ReadHandle< VxContainer > m_aod
The key of the input Container.
SG::WriteHandle< xAOD::VertexAuxContainer > m_xauxout
SG::WriteHandle< xAOD::VertexContainer > m_xaodout
The key for the output xAOD::Container.
virtual StatusCode execute()
Function executing the algorithm.
std::string m_TPContainerName
The key for the track particle links Container.
std::string m_NPContainerName
The key for the neutral particle links Container.
Eigen::Matrix< double, 3, 1 > Vector3D
Vertex_v1 Vertex
Define the latest version of the vertex class.