23 auto trkSummary = std::unique_ptr<Trk::TrackSummary>
27 std::vector<const Trk::TrackParameters*> parameters;
32 parameters.resize(indexMax);
37 auto fq = std::make_unique<Trk::FitQuality>
44 std::bitset<Trk::TrackInfo::NumberOfTrackProperties> properties(persObj->
bitsAndPieces[3]);
46 std::bitset<Trk::TrackInfo::NumberOfTrackRecoInfo> patternRecognition(persObj->
bitsAndPieces[4]);
49 unsigned int mask = (1<<(i-32));
59 const std::vector<const Trk::TrackParameters*>& parms =
61 if (!parms.empty() && parms.back()) {
67 fmom.
setE (std::sqrt ((
long double)mom.mag2() + (
long double)mpi*mpi));
73 std::move(trkSummary),
74 std::move(parameters),
99 if (!
m_parameterCnv) std::cout<<
"TrackParticleCnv_p3::transToPers WARNING! No m_parameterCnv"<<std::endl;
117 persObj->
bitsAndPieces[1] =
static_cast<unsigned int>(info.trackFitter());
118 persObj->
bitsAndPieces[2] =
static_cast<unsigned int>(info.particleHypothesis());
120 if (info.patternRecognition().size()<32) {
121 persObj->
bitsAndPieces[4] = info.patternRecognition().to_ulong();
125 unsigned int size=info.patternRecognition().size();
128 for (;i<32;++i) persObj->
bitsAndPieces[4] |= ((info.patternRecognition()[i]) << i);
129 for (i=32;i<size;++i) persObj->
bitsAndPieces[5] |= ((info.patternRecognition()[i]) << (i-32));
void setAthenaBarCode(AthenaBarCode_t id)
ElementLink implementation for ROOT usage.
CNV::Trans_t * createTransFromPStore(CNV **cnv, const TPObjRef &ref, MsgStream &log) const
virtual TopLevelTPCnvBase * topConverter()
TPObjRef toPersistent(CNV **cnv, const typename CNV::TransBase_t *transObj, MsgStream &log) const
Base interface class for all TP converters - typeless.
P4PxPyPzE is a class with 4-momentum behavior, for which Px, Py, Pz and M are data members.
virtual void setE(double theE)
set energy data member
virtual void setPz(double thePz)
set Pz data member
virtual void setPx(double thePx)
set Px data member
virtual void setPy(double thePy)
set Py data member
float m_fitQuality_m_numberDoF
std::vector< TPObjRef > m_trackParameters
float m_fitQuality_m_chiSquared
ElementLinkInt_p3 m_originalTrack
unsigned int bitsAndPieces[6]
bitsAndPieces contains the following: unsigned int m_trackParticleOrigin; Data properties related to ...
ElementLinkInt_p3 m_elVxCandidate
AthenaBarCode_t getAthenaBarCode() const
void setAthenaBarCode(AthenaBarCode_t)
ITPConverter * converterForType(const std::type_info &info) const
Find and return a TP converter for a given C++ type info.
New convertor which handles all track parameters in one go - i.e.
TrackSummaryCnv_p2 * m_trackSummaryCnv
ElementLinkCnv_p3< ElementLink< VxContainer > > m_elementLinkVxContainerConverter
ElementLinkCnv_p3< ElementLink< TrackCollection > > m_elementLinkTrackCollectionConverter
virtual void persToTrans(const Rec ::TrackParticle_p3 *persObj, Rec ::TrackParticle *transObj, MsgStream &log)
TrackParametersCnv_p2 * m_parameterCnv
AthenaBarCodeCnv_p1 m_AthenaBarCodeCnv
virtual void transToPers(const Rec ::TrackParticle *transObj, Rec ::TrackParticle_p3 *persObj, MsgStream &log)
int numberDoF() const
returns the number of degrees of freedom of the overall track or vertex fit as integer
double chiSquared() const
returns the of the overall track fit
Contains information about the 'fitter' of this track.
TrackFitter
enums to identify who created this track and what propertis does it have.
@ NumberOfTrackRecoInfo
Maximum number of enums.
const ElementLink< TrackCollection > * trackElementLink() const
Return the ElementLink to the Track.
const FitQuality * fitQuality() const
accessor function for FitQuality.
const TrackSummary * trackSummary() const
accessor function for TrackSummary.
const std::vector< const TrackParameters * > & trackParameters() const
Returns the track parameters.
const ElementLink< VxContainer > & reconstructedVertexLink() const
TrackParticleOrigin particleOriginType() const
Get the particle origin type.
const TrackInfo & info() const
returns the info of the track.
Eigen::Matrix< double, 3, 1 > Vector3D
constexpr double mass[PARTICLEHYPOTHESES]
the array of masses
VertexType TrackParticleOrigin
@ pz
global momentum (cartesian)
ParticleHypothesis
Enumeration for Particle hypothesis respecting the interaction with material.
ParametersBase< TrackParametersDim, Charged > TrackParameters