ATLAS Offline Software
Public Member Functions | Static Public Member Functions | Protected Member Functions | Private Member Functions | Private Attributes | Static Private Attributes | List of all members
Trk::TrackParticleCreatorTool Class Referencefinal

#include <TrackParticleCreatorTool.h>

Inheritance diagram for Trk::TrackParticleCreatorTool:
Collaboration diagram for Trk::TrackParticleCreatorTool:

Public Member Functions

 TrackParticleCreatorTool (const std::string &, const std::string &, const IInterface *)
 
virtual ~TrackParticleCreatorTool ()=default
 
virtual StatusCode initialize () override
 
virtual xAOD::TrackParticlecreateParticle (const EventContext &ctx, const Rec::TrackParticle &trackParticle, xAOD::TrackParticleContainer *container) const override final
 Method to construct a xAOD::TrackParticle from a Rec::TrackParticle. More...
 
virtual xAOD::TrackParticlecreateParticle (const EventContext &ctx, const Trk::Track &track, xAOD::TrackParticleContainer *container, const xAOD::Vertex *vxCandidate, xAOD::ParticleHypothesis prtOrigin) const override final
 Method to construct a xAOD::TrackParticle from a passed Track. More...
 
virtual xAOD::TrackParticlecreateParticle (const EventContext &ctx, const ElementLink< TrackCollection > &trackLink, xAOD::TrackParticleContainer *container, const xAOD::Vertex *vxCandidate, xAOD::ParticleHypothesis prtOrigin) const override final
 Method to construct a TrackParticle from a passed Track. More...
 
virtual xAOD::TrackParticlecreateParticle (const EventContext &ctx, const Perigee *perigee, const FitQuality *fq, const TrackInfo *trackInfo, const TrackSummary *summary, const std::vector< const Trk::TrackParameters * > &parameters, const std::vector< xAOD::ParameterPosition > &positions, xAOD::ParticleHypothesis prtOrigin, xAOD::TrackParticleContainer *container) const override final
 create a xAOD::TrackParticle out of constituents More...
 
virtual const InDet::BeamSpotDataCacheBeamSpotData (const EventContext &ctx) const override final
 
void setFitQuality (xAOD::TrackParticle &tp, const FitQuality &fq) const
 Method to set FitQuality of a xAOD::TrackParticle. More...
 
void setTrackInfo (xAOD::TrackParticle &tp, const TrackInfo &trackInfo, xAOD::ParticleHypothesis prtOrigin) const
 Method to set TrackInfo of a xAOD::TrackParticle. More...
 
void setTrackSummary (xAOD::TrackParticle &tp, const TrackSummary &summary) const
 Method to set TrackSummary of a xAOD::TrackParticle. More...
 
void addPIDInformation (const EventContext &ctx, const Track *track, xAOD::TrackParticle &tp) const
 Add Pixel and TRT PID information to the track particle. More...
 
void addDetailedHitInformation (const Trk::TrackStates *trackStates, xAOD::TrackParticle &tp) const
 Add extra detailed hit summary info not computed in Trk::TrkSummary. More...
 
void addExpectedHitInformation (const Perigee *perigee, xAOD::TrackParticle &tp) const
 Add expected hit info for innermost pixel layers not computed in Trk::TrkSummary. More...
 
void addOutlierHitInformation (const Trk::TrackStates *trackStates, xAOD::TrackParticle &tp) const
 Add outlier hit info not computed in Trk::TrkSummary anymore. More...
 
void addSharedHitInformation (const Track *track, xAOD::TrackParticle &tp) const
 Add shared hit info not computed in Trk::TrkSummary anymore. More...
 
void setDefiningParameters (xAOD::TrackParticle &tp, const Perigee &perigee) const
 Method to set Defining parameters of a xAOD::TrackParticle. More...
 
void setParameters (const EventContext &ctx, xAOD::TrackParticle &tp, const std::vector< const Trk::TrackParameters * > &parameters, const std::vector< xAOD::ParameterPosition > &positions) const
 Method to set parameters of a xAOD::TrackParticle. More...
 

Static Public Member Functions

static void addDummyEndcapSharedHitInformation (xAOD::TrackParticle &tp)
 Add dummy endcap shared hit info as AuxDyn variable in case nominal shared hit info not computed (for ITk fast tracking) More...
 
static void setTilt (xAOD::TrackParticle &tp, float tiltx, float tilty)
 
static void setHitPattern (xAOD::TrackParticle &tp, unsigned long hitpattern)
 
static void setNumberOfUsedHits (xAOD::TrackParticle &tp, int hits)
 
static void setNumberOfOverflowHits (xAOD::TrackParticle &tp, int overflows)
 
static const std::string & trtdEdxUsedHitsAuxName ()
 Get the name used for the decoration of the track particle with the number of used hits for TRT dE/dx computation. More...
 

Protected Member Functions

xAOD::TrackParticlecreateParticle (const EventContext &ctx, const Perigee *perigee, const FitQuality *fq, const TrackInfo *trackInfo, const TrackSummary *summary, const std::vector< const Trk::TrackParameters * > &parameters, const std::vector< xAOD::ParameterPosition > &positions, xAOD::ParticleHypothesis prtOrigin, xAOD::TrackParticleContainer *container, const Trk::Track *track) const
 create a xAOD::TrackParticle out of constituents More...
 

Private Member Functions

void compare (const Rec::TrackParticle &tp, const xAOD::TrackParticle &tpx) const
 
void compare (const TrackParameters &tp1, const TrackParameters &tp2) const
 
const Trk::ClusterSplitProbabilityContainer::ProbabilityInfogetClusterSplittingProbability (const InDet::PixelCluster *pix) const
 

Private Attributes

const AtlasDetectorIDm_detID
 atlas id helper More...
 
const PixelIDm_pixelID
 
const SCT_IDm_sctID
 
const TRT_IDm_trtID
 
PublicToolHandle< IExtendedTrackSummaryToolm_trackSummaryTool
 
ToolHandle< Reco::ITrackToVertexm_trackToVertex
 
ToolHandle< Muon::IMuonHitSummaryToolm_hitSummaryTool
 
ServiceHandle< IIBLParameterSvcm_IBLParameterSvc
 
ServiceHandle< ITrackingVolumesSvcm_trackingVolumesSvc {this,"TrackingVolumesSvc","Trk::TrackingVolumesSvc/TrackingVolumesSvc"}
 
SG::ReadCondHandleKey< AtlasFieldCacheCondObjm_fieldCacheCondObjInputKey
 
ToolHandle< ITRT_ElectronPidToolm_eProbabilityTool
 tool to calculate electron probabilities More...
 
ToolHandle< IPixelToTPIDToolm_dedxtool { this, "PixelToTPIDTool", "", "" }
 tool to calculate dE/dx using pixel clusters More...
 
ToolHandle< InDet::IInDetTestPixelLayerToolm_testPixelLayerTool
 tool to calculate expected hit information in innermost layers More...
 
StringArrayProperty m_copyExtraSummaryName
 Configurable to set the eProbabilities and extra track summary types which are to be copied from the track summary. More...
 
std::vector< Trk::eProbabilityTypem_copyEProbabilities
 Enums of an eProbability which are set in the xAOD::TrackSummary. More...
 
std::vector< std::pair< SG::AuxElement::Accessor< float >, Trk::eProbabilityType > > m_decorateEProbabilities
 The pairs if enums of an eProbability which is added as a decoration to the track particle and the name of the decoration. More...
 
std::vector< std::pair< SG::AuxElement::Accessor< uint8_t >, Trk::SummaryType > > m_decorateSummaryTypes
 
bool m_doIBL
 
BooleanProperty m_doITk {this, "DoITk", false}
 if the track contains a summary, the shared, expected hit, and PID information will be recomputed. More...
 
BooleanProperty m_computeAdditionalInfo {this, "ComputeAdditionalInfo", false}
 
BooleanProperty m_doSharedSiHits {this, "DoSharedSiHits", false}
 
BooleanProperty m_doSharedTRTHits {this, "DoSharedTRTHits", false}
 
BooleanProperty m_runningTIDE_Ambi {this, "RunningTIDE_Ambi", false}
 
BooleanProperty m_updateTrackSummary {this, "UpdateTrackSummary", false}
 
BooleanProperty m_keepParameters {this, "KeepParameters", false}
 the following keep options are mutually exclusive More...
 
BooleanProperty m_keepFirstParameters {this, "KeepFirstParameters", false}
 
BooleanProperty m_keepAllPerigee {this, "KeepAllPerigee", false}
 keep all MeasuredPerigee parameters (e.g. More...
 
IntegerProperty m_badclusterID {this, "BadClusterID", 0}
 
StringProperty m_perigeeExpression {this, "PerigeeExpression", "BeamLine"}
 
std::vector< std::string > m_perigeeOptions
 
BooleanProperty m_checkConversion {this, "CheckConversion", true}
 
IntegerProperty m_minSiHits {this, "MinSiHitsForCaloExtrap", 4}
 
DoubleProperty m_minPt {this, "MinPtForCaloExtrap", 1000.}
 
SG::ReadCondHandleKey< InDet::BeamSpotDatam_beamSpotKey { this, "BeamSpotKey", "BeamSpotData", "SG key for beam spot" }
 
SG::ReadHandleKey< Trk::ClusterSplitProbabilityContainerm_clusterSplitProbContainer { this, "ClusterSplitProbabilityName", "", "" }
 
SG::ReadHandleKey< Trk::PRDtoTrackMapm_assoMapContainer { this, "AssociationMapName", ""}
 

Static Private Attributes

static const std::string s_trtdEdxUsedHitsDecorationName { "TRTdEdxUsedHits" }
 Name used for the decoration of the track particle with TRT dE/dx . More...
 
static const SG::AuxElement::Accessor< uint8_t > s_trtdEdxUsedHitsDecoration
 

Detailed Description

Definition at line 71 of file TrackParticleCreatorTool.h.

Constructor & Destructor Documentation

◆ TrackParticleCreatorTool()

Trk::TrackParticleCreatorTool::TrackParticleCreatorTool ( const std::string &  t,
const std::string &  n,
const IInterface *  p 
)

Definition at line 110 of file TrackParticleCreatorTool.cxx.

113  : base_class(t, n, p)
114  , m_detID(nullptr)
115  , m_pixelID(nullptr)
116  , m_sctID(nullptr)
117  , m_trtID(nullptr)
121  , m_doIBL(false)
122 {
123 }

◆ ~TrackParticleCreatorTool()

virtual Trk::TrackParticleCreatorTool::~TrackParticleCreatorTool ( )
virtualdefault

Member Function Documentation

◆ addDetailedHitInformation()

void Trk::TrackParticleCreatorTool::addDetailedHitInformation ( const Trk::TrackStates trackStates,
xAOD::TrackParticle tp 
) const

Add extra detailed hit summary info not computed in Trk::TrkSummary.

Definition at line 993 of file TrackParticleCreatorTool.cxx.

994 {
995 
996  Trk::DetailedHitInfo detailedInfo;
997 
998  for (const TrackStateOnSurface* tsos : *trackStates) {
999 
1000  const Trk::MeasurementBase* mesb = tsos->measurementOnTrack();
1001  if(mesb==nullptr) continue;
1002  // Check if the measurement type is RIO on Track (ROT)
1003  const RIO_OnTrack* rot = nullptr;
1005  rot = static_cast<const RIO_OnTrack*>(mesb);
1006  }
1007  if(rot==nullptr) continue;
1008 
1009  const Identifier& id = rot->identify();
1010  if(!m_pixelID->is_pixel(id)) continue;
1011 
1012  Trk::DetectorRegion region;
1013  const InDetDD::SiDetectorElement* detEl = dynamic_cast<const InDetDD::SiDetectorElement*>(rot->detectorElement());
1014  InDetDD::DetectorType type = detEl->design().type();
1016  else if(type==InDetDD::PixelBarrel) region = Trk::pixelBarrelFlat;
1017  else region = Trk::pixelEndcap;
1018 
1019  detailedInfo.addHit(region, m_pixelID->layer_disk(id), m_pixelID->eta_module(id));
1020 
1021  }
1022 
1023  uint8_t nContribPixelLayers = static_cast<uint8_t>(detailedInfo.getPixelContributions());
1024 
1025  uint8_t nContribPixelBarrelFlatLayers = static_cast<uint8_t>(detailedInfo.getContributionFromRegion(Trk::pixelBarrelFlat ));
1026  uint8_t nContribPixelBarrelInclinedLayers = static_cast<uint8_t>(detailedInfo.getContributionFromRegion(Trk::pixelBarrelInclined));
1027  uint8_t nContribPixelEndcap = static_cast<uint8_t>(detailedInfo.getContributionFromRegion(Trk::pixelEndcap ));
1028 
1029  uint8_t nPixelBarrelFlatHits = static_cast<uint8_t>(detailedInfo.getHitsFromRegion(Trk::pixelBarrelFlat ));
1030  uint8_t nPixelBarrelInclinedHits = static_cast<uint8_t>(detailedInfo.getHitsFromRegion(Trk::pixelBarrelInclined));
1031  uint8_t nPixelEndcapHits = static_cast<uint8_t>(detailedInfo.getHitsFromRegion(Trk::pixelEndcap ));
1032 
1033  uint8_t nInnermostPixelLayerEndcapHits = static_cast<uint8_t>(detailedInfo.getHits(Trk::pixelEndcap, 0));
1034  uint8_t nNextToInnermostPixelLayerEndcapHits = static_cast<uint8_t>(detailedInfo.getHits(Trk::pixelEndcap, 1)
1035  + detailedInfo.getHits(Trk::pixelEndcap, 2)); // L0.5 shorties + L1
1036 
1037  tp.setSummaryValue(nContribPixelLayers, xAOD::numberOfContribPixelLayers);
1038  tp.setSummaryValue(nContribPixelBarrelFlatLayers, xAOD::numberOfContribPixelBarrelFlatLayers);
1039  tp.setSummaryValue(nContribPixelBarrelInclinedLayers, xAOD::numberOfContribPixelBarrelInclinedLayers);
1040  tp.setSummaryValue(nContribPixelEndcap, xAOD::numberOfContribPixelEndcap);
1041  tp.setSummaryValue(nPixelBarrelFlatHits, xAOD::numberOfPixelBarrelFlatHits);
1042  tp.setSummaryValue(nPixelBarrelInclinedHits, xAOD::numberOfPixelBarrelInclinedHits);
1043  tp.setSummaryValue(nPixelEndcapHits, xAOD::numberOfPixelEndcapHits);
1044  tp.setSummaryValue(nInnermostPixelLayerEndcapHits, xAOD::numberOfInnermostPixelLayerEndcapHits);
1045  tp.setSummaryValue(nNextToInnermostPixelLayerEndcapHits, xAOD::numberOfNextToInnermostPixelLayerEndcapHits);
1046 
1047 }

◆ addDummyEndcapSharedHitInformation()

void Trk::TrackParticleCreatorTool::addDummyEndcapSharedHitInformation ( xAOD::TrackParticle tp)
static

Add dummy endcap shared hit info as AuxDyn variable in case nominal shared hit info not computed (for ITk fast tracking)

Definition at line 1283 of file TrackParticleCreatorTool.cxx.

1284 {
1285 
1286  uint8_t nInPixSharedEndcapHits = 0, nNInPixSharedEndcapHits = 0;
1287  uint8_t nInPixSplitEndcapHits = 0, nNInPixSplitEndcapHits = 0;
1288 
1289  tp.setSummaryValue(nInPixSplitEndcapHits, xAOD::numberOfInnermostPixelLayerSplitEndcapHits);
1290  tp.setSummaryValue(nNInPixSplitEndcapHits, xAOD::numberOfNextToInnermostPixelLayerSplitEndcapHits);
1291  tp.setSummaryValue(nInPixSharedEndcapHits, xAOD::numberOfInnermostPixelLayerSharedEndcapHits);
1292  tp.setSummaryValue(nNInPixSharedEndcapHits, xAOD::numberOfNextToInnermostPixelLayerSharedEndcapHits);
1293 
1294 }

◆ addExpectedHitInformation()

void Trk::TrackParticleCreatorTool::addExpectedHitInformation ( const Perigee perigee,
xAOD::TrackParticle tp 
) const

Add expected hit info for innermost pixel layers not computed in Trk::TrkSummary.

Definition at line 1050 of file TrackParticleCreatorTool.cxx.

1051 {
1052 
1053  if(m_testPixelLayerTool.empty() || perigee==nullptr) return;
1054 
1055  uint8_t zero = static_cast<uint8_t>(0);
1056  uint8_t nContribPixLayers, nInPixHits, nNextInPixHits;
1057  if(!tp.summaryValue(nContribPixLayers, xAOD::numberOfContribPixelLayers)){
1058  nContribPixLayers = zero;
1059  }
1060  if(nContribPixLayers==0){
1061  ATH_MSG_DEBUG("No pixels on track, so wo do not expect hit in inner layers");
1062  tp.setSummaryValue(zero, xAOD::expectInnermostPixelLayerHit);
1064  }
1065 
1066  else {
1067 
1068  // Innermost pixel layer
1069  if(!tp.summaryValue(nInPixHits, xAOD::numberOfInnermostPixelLayerHits)){
1070  nInPixHits = zero;
1071  }
1072  if(nInPixHits>0){
1073  ATH_MSG_DEBUG("Innermost pixel Layer hit on track, so we expect an innermost pixel layer hit");
1074  uint8_t one = static_cast<uint8_t>(1);
1075  tp.setSummaryValue(one, xAOD::expectInnermostPixelLayerHit);
1076  } else {
1077  uint8_t expectHit = static_cast<uint8_t>(m_testPixelLayerTool->expectHitInInnermostPixelLayer(perigee));
1078  tp.setSummaryValue(expectHit, xAOD::expectInnermostPixelLayerHit);
1079  }
1080 
1081  // Next-to-innermost pixel layer
1082  if(!tp.summaryValue(nNextInPixHits, xAOD::numberOfNextToInnermostPixelLayerHits)){
1083  nNextInPixHits = zero;
1084  }
1085  if(nNextInPixHits>0){
1086  ATH_MSG_DEBUG("Next-to-innermost pixel Layer hit on track, so we expect an next-to-innermost pixel layer hit");
1087  uint8_t one = static_cast<uint8_t>(1);
1089  } else {
1090  uint8_t expectHit = static_cast<uint8_t>(m_testPixelLayerTool->expectHitInNextToInnermostPixelLayer(perigee));
1091  tp.setSummaryValue(expectHit, xAOD::expectNextToInnermostPixelLayerHit);
1092  }
1093 
1094  } // end else if nContribPixLayers>0
1095 
1096 }

◆ addOutlierHitInformation()

void Trk::TrackParticleCreatorTool::addOutlierHitInformation ( const Trk::TrackStates trackStates,
xAOD::TrackParticle tp 
) const

Add outlier hit info not computed in Trk::TrkSummary anymore.

Definition at line 1099 of file TrackParticleCreatorTool.cxx.

1100 {
1101 
1102  uint8_t nPixOutliers = 0, nInPixOutliers = 0, nNInPixOutliers = 0, nSCTOutliers = 0;
1103  uint8_t nInEndcapPixOutliers = 0, nNInEndcapPixOutliers = 0;
1104 
1105  for (const TrackStateOnSurface* tsos : *trackStates) {
1106 
1107  bool isOutlier = tsos->type(Trk::TrackStateOnSurface::Outlier);
1108  if(!isOutlier) continue;
1109 
1110  const Trk::MeasurementBase* mesb = tsos->measurementOnTrack();
1111  if(mesb==nullptr) continue;
1112  // Check if the measurement type is RIO on Track (ROT)
1113  const RIO_OnTrack* rot = nullptr;
1115  rot = static_cast<const RIO_OnTrack*>(mesb);
1116  }
1117  if (rot == nullptr)
1118  continue;
1119 
1120  const Identifier& id = rot->identify();
1121 
1122  if (m_pixelID->is_pixel(id)) {
1123  nPixOutliers++;
1124  int layer = m_pixelID->layer_disk(id);
1125  if (m_pixelID->is_barrel(id)) {
1126  if (layer == 0){
1127  nInPixOutliers++;
1128  }
1129  else if (layer == 1){
1130  nNInPixOutliers++;
1131  }
1132  } else if (m_doITk) { // isITk && isEndCap -> ITk specific counters
1133  if (layer == 0){
1134  nInEndcapPixOutliers++;
1135  }
1136  else if (layer == 1 || layer == 2){
1137  nNInEndcapPixOutliers++; // L0.5 + L1 disks
1138  }
1139  }
1140  }
1141  else if (m_sctID->is_sct(id)) {
1142  nSCTOutliers++;
1143  }
1144 
1145  // TRT outliers are already filled in the InDetTrackSummaryHelperTool as
1146  // used in the ambi solver
1147  }
1148 
1149  tp.setSummaryValue(nPixOutliers, xAOD::numberOfPixelOutliers);
1150  tp.setSummaryValue(nInPixOutliers, xAOD::numberOfInnermostPixelLayerOutliers);
1151  tp.setSummaryValue(nNInPixOutliers, xAOD::numberOfNextToInnermostPixelLayerOutliers);
1152  tp.setSummaryValue(nSCTOutliers, xAOD::numberOfSCTOutliers);
1153 
1154  if(m_doITk){
1155  tp.setSummaryValue(nInEndcapPixOutliers, xAOD::numberOfInnermostPixelLayerEndcapOutliers);
1156  tp.setSummaryValue(nNInEndcapPixOutliers, xAOD::numberOfNextToInnermostPixelLayerEndcapOutliers);
1157  }
1158 
1159 }

◆ addPIDInformation()

void Trk::TrackParticleCreatorTool::addPIDInformation ( const EventContext &  ctx,
const Track track,
xAOD::TrackParticle tp 
) const

Add Pixel and TRT PID information to the track particle.

Parameters
ctxthe current event context
tracka valid track or nullptr to set all PID values to the default value.
tpthe trackparticle in which the PID values are set.

Definition at line 944 of file TrackParticleCreatorTool.cxx.

945 {
946  // TRT PID information
947  {
948  static const std::vector<float> eProbabilityDefault(numberOfeProbabilityTypes,0.5);
949  constexpr int initialValue{-1};
950  std::vector<float> eProbability_tmp;
951  const std::vector<float>& eProbability(
952  track && !m_eProbabilityTool.empty()
953  ? eProbability_tmp =
954  m_eProbabilityTool->electronProbability(ctx, *track)
955  : eProbabilityDefault);
956  int nHits = track && !m_eProbabilityTool.empty()
958  : initialValue;
960  float eProbability_value = eProbability.at(copy);
961  tp.setSummaryValue(eProbability_value, static_cast<xAOD::SummaryType>(copy + xAOD::eProbabilityComb));
962  }
963  for (const std::pair<SG::AuxElement::Accessor<float>, Trk::eProbabilityType>& decoration :
965  float fvalue = eProbability.at(decoration.second);
966  decoration.first(tp) = fvalue;
967  }
968  // now the extra summary types
969  for (const std::pair<SG::AuxElement::Accessor<uint8_t>, Trk::SummaryType>& decoration :
971  uint8_t summary_value = nHits;
972  decoration.first(tp) = summary_value;
973  }
974 
975  }
976 
977  // PixelPID
978  {
979  const int initialValue{-1};
980  float dedx = initialValue;
981  int nHitsUsed_dEdx = initialValue;
982  int nOverflowHits_dEdx = initialValue;
983  if (track && !m_dedxtool.empty() && track->info().trackFitter() != TrackInfo::Unknown) {
984  dedx = m_dedxtool->dEdx(ctx, *track, nHitsUsed_dEdx, nOverflowHits_dEdx);
985  }
986  tp.setNumberOfUsedHitsdEdx(nHitsUsed_dEdx);
987  tp.setNumberOfIBLOverflowsdEdx(nOverflowHits_dEdx);
988  tp.setSummaryValue(dedx, static_cast<xAOD::SummaryType>(51));
989  }
990 }

◆ addSharedHitInformation()

void Trk::TrackParticleCreatorTool::addSharedHitInformation ( const Track track,
xAOD::TrackParticle tp 
) const

Add shared hit info not computed in Trk::TrkSummary anymore.

Definition at line 1162 of file TrackParticleCreatorTool.cxx.

1163 {
1164 
1165  uint8_t nPixSharedHits = 0, nInPixSharedHits = 0, nNInPixSharedHits = 0, nSCTSharedHits = 0, nTRTSharedHits = 0;
1166  uint8_t nInPixSharedEndcapHits = 0, nNInPixSharedEndcapHits = 0;
1167  uint8_t nPixSplitHits = 0, nInPixSplitHits = 0, nNInPixSplitHits = 0;
1168  uint8_t nInPixSplitEndcapHits = 0, nNInPixSplitEndcapHits = 0;
1169 
1170  const DataVector<const Trk::MeasurementBase>* measurements = track->measurementsOnTrack();
1171  if(!measurements){
1172  ATH_MSG_DEBUG("No measurement on track");
1173  return;
1174  }
1175 
1176  const EventContext& ctx = Gaudi::Hive::currentContext();
1178 
1179  for (const auto* const ms : *measurements) {
1180  // check if it's a rot
1181  const Trk::RIO_OnTrack* rot = nullptr;
1183  rot = static_cast<const Trk::RIO_OnTrack*>(ms);
1184  }
1185  if (!rot) {
1186  ATH_MSG_DEBUG("Cannot cast measurement to RIO_OnTrack");
1187  continue;
1188  }
1189 
1190  const Identifier& id = rot->identify();
1191 
1192  if (m_doSharedSiHits && m_pixelID->is_pixel(id)) {
1193  // check if split, when running TIDE
1194  bool hitIsSplit(false);
1195  if (m_runningTIDE_Ambi) {
1196  const InDet::PixelClusterOnTrack* pix = nullptr;
1198  pix = static_cast<const InDet::PixelClusterOnTrack*>(rot);
1199  }
1200  if (pix) {
1201  const InDet::PixelCluster* pixPrd = pix->prepRawData();
1203  splitProb = getClusterSplittingProbability(pixPrd);
1204  int layer = m_pixelID->layer_disk(id);
1205  if (pixPrd and splitProb.isSplit()) {
1206  ATH_MSG_DEBUG("split Pixel hit found");
1207  hitIsSplit = true;
1208  nPixSplitHits++;
1209  if (m_pixelID->is_barrel(id)) {
1210  if (layer == 0)
1211  nInPixSplitHits++;
1212  else if (layer == 1)
1213  nNInPixSplitHits++;
1214  } else if (m_doITk) { // isITk && isEndCap -> ITk specific counters
1215  if (layer == 0)
1216  nInPixSplitEndcapHits++;
1217  else if (layer == 1 || layer == 2)
1218  nNInPixSplitEndcapHits++; // L0.5 + L1 disks
1219  }
1220  }
1221  }
1222  }
1223 
1224  // check if shared
1225  // if we are running the TIDE ambi don't count split hits as shared
1226  if (!hitIsSplit) {
1227  if (prd_to_track_map->isShared(*(rot->prepRawData()))) {
1228  ATH_MSG_DEBUG("shared Pixel hit found");
1229  nPixSharedHits++;
1230  int layer = m_pixelID->layer_disk(id);
1231  if (m_pixelID->is_barrel(id)) {
1232  if (layer == 0)
1233  nInPixSharedHits++;
1234  else if (layer == 1)
1235  nNInPixSharedHits++;
1236  } else if (m_doITk) { // isITk && isEndCap -> ITk specific counters
1237  if (layer == 0)
1238  nInPixSharedEndcapHits++;
1239  else if (layer == 1 || layer == 2)
1240  nNInPixSharedEndcapHits++; // L0.5 + L1 disks
1241  }
1242  }
1243  }
1244 
1245  } // end pixel
1246 
1247  else if (m_doSharedSiHits && m_sctID->is_sct(id)) {
1248  if (prd_to_track_map->isShared(*(rot->prepRawData()))) {
1249  ATH_MSG_DEBUG("shared SCT hit found");
1250  nSCTSharedHits++;
1251  }
1252  }
1253 
1254  else if (m_doSharedTRTHits && m_trtID->is_trt(id)) {
1255  if (prd_to_track_map->isShared(*(rot->prepRawData()))) {
1256  ATH_MSG_DEBUG("shared TRT hit found");
1257  nTRTSharedHits++;
1258  }
1259  }
1260  }
1261 
1262  tp.setSummaryValue(nPixSplitHits, xAOD::numberOfPixelSplitHits);
1263  tp.setSummaryValue(nInPixSplitHits, xAOD::numberOfInnermostPixelLayerSplitHits);
1264  tp.setSummaryValue(nNInPixSplitHits, xAOD::numberOfNextToInnermostPixelLayerSplitHits);
1265 
1266  tp.setSummaryValue(nPixSharedHits, xAOD::numberOfPixelSharedHits);
1267  tp.setSummaryValue(nInPixSharedHits, xAOD::numberOfInnermostPixelLayerSharedHits);
1268  tp.setSummaryValue(nNInPixSharedHits, xAOD::numberOfNextToInnermostPixelLayerSharedHits);
1269  tp.setSummaryValue(nSCTSharedHits, xAOD::numberOfSCTSharedHits);
1270  tp.setSummaryValue(nTRTSharedHits, xAOD::numberOfTRTSharedHits);
1271 
1272  if(m_doITk){
1273  tp.setSummaryValue(nInPixSplitEndcapHits, xAOD::numberOfInnermostPixelLayerSplitEndcapHits);
1274  tp.setSummaryValue(nNInPixSplitEndcapHits, xAOD::numberOfNextToInnermostPixelLayerSplitEndcapHits);
1275  tp.setSummaryValue(nInPixSharedEndcapHits, xAOD::numberOfInnermostPixelLayerSharedEndcapHits);
1276  tp.setSummaryValue(nNInPixSharedEndcapHits, xAOD::numberOfNextToInnermostPixelLayerSharedEndcapHits);
1277  }
1278 
1279 }

◆ CacheBeamSpotData()

const InDet::BeamSpotData * Trk::TrackParticleCreatorTool::CacheBeamSpotData ( const EventContext &  ctx) const
finaloverridevirtual

Definition at line 1314 of file TrackParticleCreatorTool.cxx.

1315 {
1317  return beamSpotHandle.cptr();
1318 }

◆ compare() [1/2]

void Trk::TrackParticleCreatorTool::compare ( const Rec::TrackParticle tp,
const xAOD::TrackParticle tpx 
) const
private

Definition at line 764 of file TrackParticleCreatorTool.cxx.

765 {
766  if (tp.measuredPerigee()) {
767  compare(*tp.measuredPerigee(), tpx.perigeeParameters());
768  }
769 
770  // trackParticle.info(),trackParticle.trackSummary(),
771  if (tp.trackParameters().size() != tpx.numberOfParameters()) {
772  ATH_MSG_WARNING("Number of parameters not the same " << tp.trackParameters().size() << " --- "
773  << tpx.numberOfParameters());
774  }
775 }

◆ compare() [2/2]

void Trk::TrackParticleCreatorTool::compare ( const TrackParameters tp1,
const TrackParameters tp2 
) const
private

Definition at line 745 of file TrackParticleCreatorTool.cxx.

746 {
747  int index = Amg::compare(tp1.parameters(), tp2.parameters(), 1e-6, true);
748  if (index != -1) {
749  ATH_MSG_WARNING("Bad parameters conversion " << Amg::toString(tp1.parameters(), 7) << " --- "
750  << Amg::toString(tp2.parameters(), 7));
751  }
752  if ((tp1.covariance() && !tp2.covariance()) || (!tp1.covariance() && tp2.covariance())) {
753  ATH_MSG_WARNING("Bad Covariance conversion " << tp1.covariance() << " --- " << tp2.covariance());
754  } else if (tp1.covariance() && tp2.covariance()) {
755  std::pair<int, int> indices = Amg::compare(*tp1.covariance(), *tp2.covariance(), 1e-6, true);
756  if (indices.first != -1)
757  ATH_MSG_WARNING("Bad Covariance conversion " << std::endl
758  << Amg::toString(*tp1.covariance(), 10) << std::endl
759  << Amg::toString(*tp2.covariance(), 10));
760  }
761 }

◆ createParticle() [1/5]

xAOD::TrackParticle * Trk::TrackParticleCreatorTool::createParticle ( const EventContext &  ctx,
const ElementLink< TrackCollection > &  trackLink,
xAOD::TrackParticleContainer container,
const xAOD::Vertex vxCandidate,
xAOD::ParticleHypothesis  prtOrigin 
) const
finaloverridevirtual

Method to construct a TrackParticle from a passed Track.

Will keep parameters based on m_keepParameters,m_keepFirstParameters, m_keepAllPerigee. It will use the exising summary or redo it based on m_useTrackSummaryTool

Parameters
trackelement link to a valid track (i.e. do not pass a zero!).
TrackParticleContainerneeded to have an AuxStore, if provided particle will be added to store which takes ownership
xAOD::VertexPointer to a valid vxCandidate (i.e. do not pass a zero!). Ownership is not taken (i.e. it will not be deleted)
prtOrigin

Definition at line 642 of file TrackParticleCreatorTool.cxx.

647 {
648 
649  xAOD::TrackParticle* trackparticle =
650  createParticle(ctx, **trackLink, container, vxCandidate, prtOrigin);
651 
652  if (!trackparticle) {
653  ATH_MSG_WARNING("WARNING: Problem creating TrackParticle - Returning 0");
654  return nullptr;
655  }
656 
657  trackparticle->setTrackLink(trackLink);
658 
659  return trackparticle;
660 }

◆ createParticle() [2/5]

xAOD::TrackParticle * Trk::TrackParticleCreatorTool::createParticle ( const EventContext &  ctx,
const Perigee perigee,
const FitQuality fq,
const TrackInfo trackInfo,
const TrackSummary summary,
const std::vector< const Trk::TrackParameters * > &  parameters,
const std::vector< xAOD::ParameterPosition > &  positions,
xAOD::ParticleHypothesis  prtOrigin,
xAOD::TrackParticleContainer container 
) const
inlinefinaloverridevirtual

create a xAOD::TrackParticle out of constituents

Definition at line 662 of file TrackParticleCreatorTool.cxx.

671  {
672  return createParticle(ctx,perigee, fq, trackInfo, summary, parameters, positions, prtOrigin, container, nullptr);
673 }

◆ createParticle() [3/5]

xAOD::TrackParticle * Trk::TrackParticleCreatorTool::createParticle ( const EventContext &  ctx,
const Perigee perigee,
const FitQuality fq,
const TrackInfo trackInfo,
const TrackSummary summary,
const std::vector< const Trk::TrackParameters * > &  parameters,
const std::vector< xAOD::ParameterPosition > &  positions,
xAOD::ParticleHypothesis  prtOrigin,
xAOD::TrackParticleContainer container,
const Trk::Track track 
) const
protected

create a xAOD::TrackParticle out of constituents

Definition at line 676 of file TrackParticleCreatorTool.cxx.

686 {
687 
688  xAOD::TrackParticle* trackparticle = new xAOD::TrackParticle;
689  if (!trackparticle) {
690  ATH_MSG_WARNING("WARNING: Problem creating TrackParticle - Returning 0");
691  return nullptr;
692  }
693  /*
694  * The following needs care as in one case the ownership
695  * can be passed to StoreGate i.e to the relevant container
696  * DataVector.
697  * In the other the caller has the ownership
698  */
699 
700  if (container) {
701  container->push_back(trackparticle);
702  } else {
703  trackparticle->makePrivateStore();
704  }
705 
706  // Fit quality
707  if (fq) {
708  setFitQuality(*trackparticle, *fq);
709  }
710  // Track Info
711  if (trackInfo) {
712  setTrackInfo(*trackparticle, *trackInfo, prtOrigin);
713  }
714  // track summary
715  if (summary) {
716  setTrackSummary(*trackparticle, *summary);
717  setHitPattern(*trackparticle, summary->getHitPattern());
718  addPIDInformation(ctx, track, *trackparticle);
719  if(m_doITk) addDetailedHitInformation(track->trackStateOnSurfaces(), *trackparticle);
720  }
721 
722  if (m_computeAdditionalInfo && track!=nullptr) {
723  addExpectedHitInformation(track->perigeeParameters(), *trackparticle);
724  addOutlierHitInformation(track->trackStateOnSurfaces(), *trackparticle);
726  else if(m_doITk) addDummyEndcapSharedHitInformation(*trackparticle);
727  }
728 
729  const auto* beamspot = CacheBeamSpotData(ctx);
730  if (beamspot) {
731  setTilt(*trackparticle, beamspot->beamTilt(0), beamspot->beamTilt(1));
732  }
733  // Parameters
734  if (perigee) {
735  setDefiningParameters(*trackparticle, *perigee);
736  } else {
737  ATH_MSG_WARNING("Track without perigee parameters? Not setting any defining parameters!");
738  }
739  setParameters(ctx, *trackparticle, parameters, positions);
740 
741  return trackparticle;
742 }

◆ createParticle() [4/5]

xAOD::TrackParticle * Trk::TrackParticleCreatorTool::createParticle ( const EventContext &  ctx,
const Rec::TrackParticle trackParticle,
xAOD::TrackParticleContainer container 
) const
finaloverridevirtual

Method to construct a xAOD::TrackParticle from a Rec::TrackParticle.

Parameters
trackparticle
TrackParticleContainerneeded to have an AuxStore, if provided particle will be added to store which takes ownership

Definition at line 593 of file TrackParticleCreatorTool.cxx.

596 {
597 
598  // Attempt to fill the position enums - will necessarily be a bit of a hack, since we don't have
599  // all the information.
600  std::vector<xAOD::ParameterPosition> positions;
601  bool firstMeasurement = false;
602  for (const auto* parameter : trackParticle.trackParameters()) {
603  if (!firstMeasurement && parameter && !parameter->associatedSurface().isFree()) {
604  // if the surface isn't free, it must belong to a detector element => measurement
605  firstMeasurement = true;
606  positions.push_back(xAOD::FirstMeasurement);
607  } else if (firstMeasurement && parameter && !parameter->associatedSurface().isFree()) {
608  // Making the (possibly unfounded assumption that if we have the first measurement, the next
609  // will be the last)
610  positions.push_back(xAOD::LastMeasurement);
611  } else {
612  positions.push_back(xAOD::BeamLine); // Don't have a default yet!
613  }
614  }
615 
616  xAOD::TrackParticle* trackparticle =
617  createParticle(ctx,
618  trackParticle.measuredPerigee(),
619  trackParticle.fitQuality(),
620  &trackParticle.info(),
621  trackParticle.trackSummary(),
622  trackParticle.trackParameters(),
623  positions,
624  static_cast<xAOD::ParticleHypothesis>(trackParticle.info().particleHypothesis()),
625  container,
626  nullptr);
627 
628  if (!trackparticle) {
629  ATH_MSG_WARNING("WARNING: Problem creating TrackParticle - Returning 0");
630  return nullptr;
631  }
632 
633  trackparticle->setTrackLink(*(trackParticle.trackElementLink()));
634 
635  if (m_checkConversion)
636  compare(trackParticle, *trackparticle);
637 
638  return trackparticle;
639 }

◆ createParticle() [5/5]

xAOD::TrackParticle * Trk::TrackParticleCreatorTool::createParticle ( const EventContext &  ctx,
const Trk::Track track,
xAOD::TrackParticleContainer container,
const xAOD::Vertex vxCandidate,
xAOD::ParticleHypothesis  prtOrigin 
) const
finaloverridevirtual

Method to construct a xAOD::TrackParticle from a passed Track.

Will keep parameters based on m_keepParameters,m_keepFirstParameters, m_keepAllPerigee. It will use the exising summary or redo it based on m_useTrackSummaryTool

Parameters
trackPointer to a valid track (i.e. do not pass a zero!). Ownership is not taken (i.e. it will not be deleted)
TrackParticleContainerneeded to have an AuxStore, if provided particle will be added to store which takes ownership
xAOD::VertexPointer to a valid vxCandidate (i.e. do not pass a zero!). Ownership is not taken (i.e. it will not be deleted)
prtOriginParticle type

Definition at line 259 of file TrackParticleCreatorTool.cxx.

264 {
265  const Trk::Perigee* aPer = nullptr;
266  const Trk::TrackParameters* parsToBeDeleted = nullptr;
267  // Origin
268  if (m_perigeeExpression == "Origin") {
269  aPer = track.perigeeParameters();
270  if (aPer) {
271  // aMeasPer clone will be created later if all perigee option selected
272  if (m_keepAllPerigee) {
273  aPer = nullptr;
274  }
275  } else {
276  const Amg::Vector3D persf(0, 0, 0);
277  const Trk::Perigee* result = m_trackToVertex->perigeeAtVertex(ctx, track, persf).release();
278  if (result != nullptr) {
279  aPer = result;
280  parsToBeDeleted = result;
281  } else {
282  ATH_MSG_WARNING("Could not extrapolate to 0,0,0. No TrackParticle created.");
283  return nullptr;
284  }
285  }
286  // Beamspot
287  } else if (m_perigeeExpression == "BeamSpot") {
288  const Trk::Perigee* result = m_trackToVertex->perigeeAtVertex(ctx, track, CacheBeamSpotData(ctx)->beamVtx().position()).release();
289  if (!result) {
290  ATH_MSG_WARNING("Failed to extrapolate to first Beamspot - No TrackParticle created.");
291  return nullptr;
292  }
293  parsToBeDeleted = result;
294  aPer = result;
295  }
296  // the non default way, express the perigee wrt. the vertex position
297  else if (m_perigeeExpression == "Vertex") {
298  if (vxCandidate != nullptr) {
299  const Trk::Perigee* result = m_trackToVertex->perigeeAtVertex(ctx, track, vxCandidate->position()).release();
300  if (result != nullptr) {
301  parsToBeDeleted = result;
302  aPer = result;
303  } else {
304  ATH_MSG_WARNING("Could not extrapolate track to vertex region! No TrackParticle created.");
305  return nullptr;
306  }
307  } else {
308  ATH_MSG_WARNING("Perigee expression at Vertex, but no vertex found! No TrackParticle created.");
309  }
310  //BeamLine
311  } else if (m_perigeeExpression == "BeamLine") {
312  const Trk::Perigee* result = m_trackToVertex->perigeeAtBeamline(ctx, track, CacheBeamSpotData(ctx)).release();
313  if (!result) {
314  ATH_MSG_WARNING("Failed to extrapolate to Beamline - No TrackParticle created.");
315  return nullptr;
316  }
317  parsToBeDeleted = result;
318  aPer = result;
319  }
320  /*
321  * We start from the existing summary
322  * and see what we want to add
323  */
324  std::unique_ptr<Trk::TrackSummary> updated_summary;
325  const Trk::TrackSummary* summary = track.trackSummary();
326  if (m_trackSummaryTool.get() != nullptr) {
327  if (!track.trackSummary() || m_updateTrackSummary) {
328  updated_summary = m_trackSummaryTool->summary(ctx, track);
329  summary = updated_summary.get();
330  }
331  } else {
333  "No proper TrackSummaryTool found. Creating TrackParticle with a TrackSummary on track");
334  }
335  if (!summary) {
336  ATH_MSG_WARNING("Track particle created for a track without a track summary");
337  }
338 
339  // find the first and the last hit in track
340  // we do that the same way as in the track slimming tool!
341  // that way it is also ok on not slimmed tracks!
342  std::vector<const Trk::TrackParameters*> parameters;
343  std::vector<xAOD::ParameterPosition> parameterPositions;
344 
345  int nbc_meas_A1 = 0;
346  int nbc_meas_B3 = 0;
347  int nbc_meas_A1_or_B3 = 0;
348  int nbc_meas_A1_or_B3_or_C = 0;
349 
350  int isBC_A1 = 0;
351  int isBC_B3 = 0;
352  int isBC_C = 0;
353 
354  const Trk::TrackStates* trackStates = track.trackStateOnSurfaces();
355  const Trk::TrackParameters* first(nullptr);
356  const Trk::TrackParameters* tp(nullptr);
357 
358  if (m_badclusterID != 0) {
359  for (const TrackStateOnSurface* tsos : *trackStates) {
360  if (tsos->type(TrackStateOnSurface::Measurement) && tsos->trackParameters() != nullptr &&
361  tsos->measurementOnTrack() != nullptr &&
362  !(tsos->measurementOnTrack()->type(Trk::MeasurementBaseType::PseudoMeasurementOnTrack))) {
363  tp = tsos->trackParameters();
364 
365  const InDet::SiClusterOnTrack* clus =
366  dynamic_cast<const InDet::SiClusterOnTrack*>(tsos->measurementOnTrack());
367  if (!clus) {
368  ATH_MSG_DEBUG("Failed dynamic_cast to InDet::SiClusterOnTrack ");
369  continue;
370  }
371  const Trk::PrepRawData* prdc = nullptr;
372  prdc = clus->prepRawData();
373  if (!prdc) {
374  ATH_MSG_DEBUG("No PRD for Si cluster");
375  }
376  const InDet::SiCluster* RawDataClus = dynamic_cast<const InDet::SiCluster*>(clus->prepRawData());
377  if (!RawDataClus) {
378  ATH_MSG_DEBUG("No RDC for Si cluster");
379  continue;
380  }
381  const Trk::MeasurementBase* mesb = tsos->measurementOnTrack();
382 
383  if (RawDataClus->detectorElement()->isPixel()) {
384  const InDetDD::SiDetectorElement* element = nullptr;
386  dynamic_cast<const InDet::PixelCluster*>(RawDataClus);
387  if (!pixelCluster) {
388  ATH_MSG_DEBUG("Pixel cluster null though detector element matches pixel");
389  }
390 
391  else {
392  float size = pixelCluster->rdoList().size();
393  float tot = pixelCluster->totalToT();
394  float charge = pixelCluster->totalCharge();
395  float cotthetaz = -1;
396  int zWidth = -1;
397 
398  element = pixelCluster->detectorElement();
399  if (!element)
400  ATH_MSG_DEBUG("No element for track incidence angles!");
401  float PixTrkAngle = -1000;
402  float PixTrkThetaI = -1000;
403  float theta = -1000;
404  if (element) {
405  const Amg::Vector3D& my_track = tp->momentum();
406  const Amg::Vector3D& my_normal = element->normal();
407  const Amg::Vector3D& my_phiax = element->phiAxis();
408  const Amg::Vector3D& my_etaax = element->etaAxis();
409  // track component on etaAxis:
410  float trketacomp = my_track.dot(my_etaax);
411  // track component on phiAxis:
412  float trkphicomp = my_track.dot(my_phiax);
413  // track component on the normal to the module
414  float trknormcomp = my_track.dot(my_normal);
415  // Track angle
416  PixTrkAngle = std::atan2(trkphicomp, trknormcomp);
417  PixTrkThetaI = std::atan2(trketacomp, trknormcomp);
418  float length = std::sqrt(trketacomp * trketacomp + trkphicomp * trkphicomp + trknormcomp * trknormcomp);
419  theta = std::acos(trknormcomp / length);
420  cotthetaz = 1. / std::tan(PixTrkThetaI);
421 
422  // reducing the angle in the right quadrant
423  // M_PI (pi) and M_PI_2 (pi/2.) are defined in cmath.
424  if (PixTrkThetaI > M_PI_2)
425  PixTrkThetaI -= M_PI;
426  else if (PixTrkThetaI < -M_PI_2)
427  PixTrkThetaI += M_PI;
428  PixTrkThetaI = M_PI_2 - PixTrkThetaI;
429  if (PixTrkAngle > M_PI_2)
430  PixTrkAngle -= M_PI;
431  else if (PixTrkAngle < -M_PI_2)
432  PixTrkAngle += M_PI;
433  PixTrkAngle = M_PI_2 - PixTrkAngle;
434  if (theta > M_PI_2)
435  theta = M_PI - theta;
436  }
437 
438  Identifier surfaceID;
439  surfaceID = mesb->associatedSurface().associatedDetectorElement()->identify();
440  if (m_detID->is_pixel(surfaceID)) {
441  const InDet::SiWidth& width = pixelCluster->width();
442  zWidth = static_cast<int>(width.colRow().y());
443  }
444 
445  int isIBLclus = false;
446  if (m_doIBL && m_pixelID->barrel_ec(surfaceID) == 0 &&
447  m_pixelID->layer_disk(surfaceID) == 0) {
448  isIBLclus = true;
449  }
450 
451  // count bad clusters
452  if (!isIBLclus) {
453  if ((size == 1 && tot < 8) || (size == 2 && tot < 15)) {
454  isBC_A1 = true;
455  nbc_meas_A1++;
456  }
457  // Need to replace these magic numbers with constexpr with meaning full names
458  if (charge < 13750. / std::cos(theta) - 22500.) {
459  isBC_B3 = true;
460  nbc_meas_B3++;
461  }
462  if (isBC_A1 || isBC_B3) {
463  nbc_meas_A1_or_B3++;
464  }
465  if ((zWidth == 1 && cotthetaz > 5.8) || (zWidth == 2 && cotthetaz > 5.8) ||
466  (zWidth == 3 && cotthetaz > 6.2) || (zWidth > 3 && cotthetaz < 2.5)) {
467  isBC_C = true;
468  }
469  if (isBC_A1 || isBC_B3 || isBC_C) {
470  nbc_meas_A1_or_B3_or_C++;
471  }
472  }
473  }
474  }
475  }
476  }
477  }
479  // search first valid TSOS first
480  for (const TrackStateOnSurface* tsos : *trackStates) {
481  if (tsos->type(TrackStateOnSurface::Measurement) && tsos->trackParameters() != nullptr &&
482  tsos->measurementOnTrack() != nullptr &&
483  !(tsos->measurementOnTrack()->type(Trk::MeasurementBaseType::PseudoMeasurementOnTrack))) {
484  first = tsos->trackParameters();
485  parameters.push_back(tsos->trackParameters());
486  parameterPositions.push_back(xAOD::FirstMeasurement);
487  break;
488  }
489  }
490 
491  if (!m_keepFirstParameters) {
492  // search last valid TSOS first
493  for (Trk::TrackStates::const_reverse_iterator rItTSoS = trackStates->rbegin();
494  rItTSoS != trackStates->rend();
495  ++rItTSoS) {
496  if ((*rItTSoS)->type(TrackStateOnSurface::Measurement) &&
497  (*rItTSoS)->trackParameters() != nullptr && (*rItTSoS)->measurementOnTrack() != nullptr &&
498  !((*rItTSoS)->measurementOnTrack()->type(
500  if (!(first == (*rItTSoS)->trackParameters())) {
501  parameters.push_back((*rItTSoS)->trackParameters());
502  parameterPositions.push_back(xAOD::LastMeasurement);
503  }
504  break;
505  }
506  }
507  }
508 
509  // security check:
510  if (parameters.size() > 2)
511  ATH_MSG_WARNING("More than two additional track parameters to be stored in TrackParticle!");
512  }
513 
514  // KeepAllPerigee will keep all perigee's on the track plus the parameters at the first
515  // measurement, provided this measurement precedes any second perigee. The track (initial) perigee
516  // is the 'defining parameter' for the TrackParticle, by convention this is pushed to the back of
517  // the parameter vector by the TP constructor.
518  else if (m_keepAllPerigee) {
519  bool haveFirstMeasurementParameters = false;
520  for (const TrackStateOnSurface* tsos : *(track.trackStateOnSurfaces())) {
521  if (!tsos->trackParameters())
522  continue;
523 
524  if (!haveFirstMeasurementParameters && tsos->type(TrackStateOnSurface::Measurement) &&
525  !tsos->type(TrackStateOnSurface::Outlier) && tsos->measurementOnTrack() &&
526  !(tsos->measurementOnTrack()->type(Trk::MeasurementBaseType::PseudoMeasurementOnTrack))) {
527  haveFirstMeasurementParameters = true;
528  parameters.push_back(tsos->trackParameters());
529  ATH_MSG_VERBOSE(" including first measurement parameters at R "
530  << tsos->trackParameters()->position().perp() << ", Z "
531  << tsos->trackParameters()->position().z());
532  parameterPositions.push_back(xAOD::FirstMeasurement);
533  continue;
534  }
535  if (!tsos->type(TrackStateOnSurface::Perigee) ||
536  !(tsos->trackParameters()->surfaceType() == Trk::SurfaceType::Perigee) ||
537  !(tsos->trackParameters()->type() == Trk::AtaSurface)) {
538  continue;
539  }
540  if (!aPer) {
541  aPer = static_cast<const Perigee*>(tsos->trackParameters());
542  } else {
543  parameters.push_back(tsos->trackParameters());
544  }
545 
546  ATH_MSG_VERBOSE(" including perigee at R " << tsos->trackParameters()->position().perp() << ", Z "
547  << tsos->trackParameters()->position().z());
548 
549  // we are not interested in keeping measurement parameters after any second perigee
550  if (!parameters.empty())
551  haveFirstMeasurementParameters = true;
552  }
553  }
554 
555  xAOD::TrackParticle* trackparticle = createParticle(ctx,
556  aPer,
557  track.fitQuality(),
558  &track.info(),
559  summary,
560  parameters,
561  parameterPositions,
562  prtOrigin,
563  container,
564  &track);
565 
566  static const SG::AuxElement::Accessor<int> nbCmeas("nBC_meas");
567  switch (m_badclusterID) {
568  case 1: {
569  nbCmeas(*trackparticle) = nbc_meas_A1;
570  break;
571  }
572  case 2: {
573  nbCmeas(*trackparticle) = nbc_meas_B3;
574  break;
575  }
576  case 3: {
577  nbCmeas(*trackparticle) = nbc_meas_A1_or_B3;
578  break;
579  }
580  case 4: {
581  nbCmeas(*trackparticle) = nbc_meas_A1_or_B3_or_C;
582  break;
583  }
584  default: {
585  }
586  }
587 
588  delete parsToBeDeleted;
589  return trackparticle;
590 }

◆ getClusterSplittingProbability()

const Trk::ClusterSplitProbabilityContainer::ProbabilityInfo & Trk::TrackParticleCreatorTool::getClusterSplittingProbability ( const InDet::PixelCluster pix) const
private

Definition at line 1298 of file TrackParticleCreatorTool.cxx.

1299 {
1300  const EventContext& ctx = Gaudi::Hive::currentContext();
1301  if (!pix || m_clusterSplitProbContainer.key().empty()) {
1303  }
1305  if (!splitProbContainer.isValid()) {
1306  ATH_MSG_FATAL("Failed to get cluster splitting probability container "
1308  }
1309  return splitProbContainer->splitProbability(pix);
1310 }

◆ initialize()

StatusCode Trk::TrackParticleCreatorTool::initialize ( )
overridevirtual

Definition at line 126 of file TrackParticleCreatorTool.cxx.

127 {
128 
129  ATH_MSG_DEBUG("initialize TrackParticleCreatorTool");
133  ATH_MSG_ERROR("Unknown Configuration for Perigee Expression - please use one of "
134  << m_perigeeOptions);
135  return StatusCode::FAILURE;
136  }
137 
138  /* Retrieve track summary tool */
139  if (!m_trackSummaryTool.empty()) {
140  if (m_trackSummaryTool.retrieve().isFailure()) {
141  ATH_MSG_FATAL("Failed to retrieve tool " << m_trackSummaryTool);
142  return StatusCode::FAILURE;
143  }
144  ATH_MSG_DEBUG("Retrieved tool " << m_trackSummaryTool);
145  } else {
146  m_trackSummaryTool.disable();
147  }
148 
149  if (detStore()->retrieve(m_detID, "AtlasID").isFailure()) {
150  ATH_MSG_FATAL("Could not get AtlasDetectorID ");
151  return StatusCode::FAILURE;
152  }
153 
154  if (detStore()->retrieve(m_pixelID, "PixelID").isFailure()) {
155  ATH_MSG_FATAL("Could not get PixelID ");
156  return StatusCode::FAILURE;
157  }
158 
159  if (detStore()->retrieve(m_sctID, "SCT_ID").isFailure()) {
160  ATH_MSG_FATAL("Could not get SCT_ID ");
161  return StatusCode::FAILURE;
162  }
163 
164  if (detStore()->retrieve(m_trtID, "TRT_ID").isFailure()) {
165  ATH_MSG_FATAL("Could not get TRT_ID ");
166  return StatusCode::FAILURE;
167  }
168 
169  if (!m_IBLParameterSvc.empty()) {
170  if (m_IBLParameterSvc.retrieve().isFailure()) {
171  ATH_MSG_FATAL("Could not retrieve IBLParameterSvc");
172  return StatusCode::FAILURE;
173  }
174  }
175 
176  m_doIBL = !m_IBLParameterSvc.empty() && m_IBLParameterSvc->containsIBL();
177 
178  if (m_doIBL && !m_IBLParameterSvc->contains3D()) {
179  ATH_MSG_WARNING("Assuming hybrid 2D/3D IBL module composition, but geometry is all-planar");
180  }
181 
182  /* Retrieve track to vertex from ToolService */
183  if (m_trackToVertex.retrieve().isFailure()) {
184  ATH_MSG_FATAL("Failed to retrieve tool " << m_trackToVertex);
185  return StatusCode::FAILURE;
186  }
187  ATH_MSG_DEBUG("Retrieved tool " << m_trackToVertex);
188 
189  if (!m_hitSummaryTool.empty()) {
190  /* Retrieve hit summary tool from ToolService */
191  if (m_hitSummaryTool.retrieve().isFailure()) {
192  ATH_MSG_FATAL("Failed to retrieve tool " << m_hitSummaryTool);
193  return StatusCode::FAILURE;
194  }
195  ATH_MSG_DEBUG("Retrieved tool " << m_hitSummaryTool);
196 
197  } else {
198  m_hitSummaryTool.disable();
199  }
200  ATH_CHECK(m_trackingVolumesSvc.retrieve());
201 
203 
204  StatusCode sc(StatusCode::SUCCESS);
205  m_copyEProbabilities.clear();
206  m_decorateEProbabilities.clear();
207  m_decorateSummaryTypes.clear();
208 
209  if (!m_copyExtraSummaryName.empty()) {
210  std::map<std::string, std::pair<Trk::eProbabilityType, bool>> eprob_map;
211  std::map<std::string, Trk::SummaryType> extra_summary_type_map;
212  createEProbabilityMap(eprob_map);
213  createExtraSummaryTypeMap(extra_summary_type_map);
214 
215  std::vector<std::string> errors;
216  for (const std::string& eprob_to_copy : m_copyExtraSummaryName) {
217  std::map<std::string, std::pair<Trk::eProbabilityType, bool>>::const_iterator eprob_iter =
218  eprob_map.find(eprob_to_copy);
219  if (eprob_iter == eprob_map.end()) {
220  std::map<std::string, Trk::SummaryType>::const_iterator extra_summary_type_iter =
221  extra_summary_type_map.find(eprob_to_copy);
222  if (extra_summary_type_iter == extra_summary_type_map.end()) {
223  errors.push_back(eprob_to_copy);
224  } else {
225  m_decorateSummaryTypes.emplace_back(
226  SG::AuxElement::Accessor<uint8_t>(extra_summary_type_iter->first),
227  extra_summary_type_iter->second);
228  }
229  } else {
230  if (!eprob_iter->second.second) {
231  m_copyEProbabilities.push_back(eprob_iter->second.first);
232  } else {
233  m_decorateEProbabilities.emplace_back(SG::AuxElement::Accessor<float>(eprob_iter->first),
234  eprob_iter->second.first);
235  }
236  }
237  }
238 
239  if (!errors.empty()) {
240  ATH_MSG_ERROR("Error in configuration. Unknown electron probability name: "
241  << errors << ". known are " << eprob_map << " " << extra_summary_type_map);
242  sc = StatusCode::FAILURE;
243  }
244  }
245 
246  ATH_CHECK( m_eProbabilityTool.retrieve( DisableTool{m_eProbabilityTool.empty()} ) );
247  ATH_CHECK( m_dedxtool.retrieve( DisableTool{m_dedxtool.empty()} ) );
248  ATH_CHECK( m_testPixelLayerTool.retrieve( DisableTool{m_testPixelLayerTool.empty()} ) );
249 
252  !m_clusterSplitProbContainer.key().empty()));
253 
254  ATH_MSG_VERBOSE(" initialize successful.");
255  return sc;
256 }

◆ setDefiningParameters()

void Trk::TrackParticleCreatorTool::setDefiningParameters ( xAOD::TrackParticle tp,
const Perigee perigee 
) const

Method to set Defining parameters of a xAOD::TrackParticle.

◆ setFitQuality()

void Trk::TrackParticleCreatorTool::setFitQuality ( xAOD::TrackParticle tp,
const FitQuality fq 
) const

Method to set FitQuality of a xAOD::TrackParticle.

◆ setHitPattern()

void Trk::TrackParticleCreatorTool::setHitPattern ( xAOD::TrackParticle tp,
unsigned long  hitpattern 
)
static

Definition at line 864 of file TrackParticleCreatorTool.cxx.

865 {
866  tp.setHitPattern(hitpattern);
867 }

◆ setNumberOfOverflowHits()

void Trk::TrackParticleCreatorTool::setNumberOfOverflowHits ( xAOD::TrackParticle tp,
int  overflows 
)
static

Definition at line 876 of file TrackParticleCreatorTool.cxx.

877 {
878  tp.setNumberOfIBLOverflowsdEdx(overflows);
879 }

◆ setNumberOfUsedHits()

void Trk::TrackParticleCreatorTool::setNumberOfUsedHits ( xAOD::TrackParticle tp,
int  hits 
)
static

Definition at line 870 of file TrackParticleCreatorTool.cxx.

871 {
872  tp.setNumberOfUsedHitsdEdx(hits);
873 }

◆ setParameters()

void Trk::TrackParticleCreatorTool::setParameters ( const EventContext &  ctx,
xAOD::TrackParticle tp,
const std::vector< const Trk::TrackParameters * > &  parameters,
const std::vector< xAOD::ParameterPosition > &  positions 
) const

Method to set parameters of a xAOD::TrackParticle.

Definition at line 778 of file TrackParticleCreatorTool.cxx.

782 {
783  std::vector<std::vector<float>> parametersVec;
784  parametersVec.resize(parameters.size());
785  unsigned int numParam = 0;
786 
788  const AtlasFieldCacheCondObj* fieldCondObj{ *readHandle };
789  MagField::AtlasFieldCache fieldCache;
790  fieldCondObj->getInitializedCache(fieldCache);
791 
792  for (const auto* param : parameters) {
793  std::vector<float>& values = parametersVec[numParam];
794  values.resize(6);
795  const Amg::Vector3D& pos = param->position();
796  const Amg::Vector3D& mom = param->momentum();
797  values[0] = pos[0];
798  values[1] = pos[1];
799  values[2] = pos[2];
800  values[3] = mom[0];
801  values[4] = mom[1];
802  values[5] = mom[2];
803 
804  const bool straightPars = (!fieldCache.solenoidOn() && m_trackingVolumesSvc->volume(Trk::ITrackingVolumesSvc::CalorimeterEntryLayer).inside(pos)) ||
807  AmgSymMatrix(5) covarianceMatrix;
808  covarianceMatrix.setIdentity();
809 
810  if (param->covariance()) {
811  // has covariance matrix
812  // now convert from to Curvilinear -- to be double checked for correctness
813  CurvilinearUVT curvilinearUVT(mom.unit());
814  if (!straightPars){
815  Amg::Vector3D magnFieldVect;
816  magnFieldVect.setZero();
817  fieldCache.getField(pos.data(), magnFieldVect.data());
818  const Amg::Transform3D& localToGlobalTransform = param->associatedSurface().transform();
819 
820  JacobianLocalToCurvilinear jacobian(magnFieldVect,
821  param->parameters()[Trk::qOverP],
822  std::sin(param->parameters()[Trk::theta]),
823  curvilinearUVT,
824  localToGlobalTransform.rotation().col(0),
825  localToGlobalTransform.rotation().col(1));
826 
827  covarianceMatrix = param->covariance()->similarity(jacobian);
828  } else {
829  const Amg::Vector3D loc_x {param->parameters()[Trk::locX],0,0};
830  const Amg::Vector3D loc_y {0,param->parameters()[Trk::locY],0};
831  JacobianLocalToCurvilinear jacobian(curvilinearUVT, loc_x, loc_y);
832  covarianceMatrix = param->covariance()->similarity(jacobian);
833  }
834  }
835  std::vector<float> covMatrixVec;
836  Amg::compress(covarianceMatrix, covMatrixVec);
837  tp.setTrackParameterCovarianceMatrix(numParam, covMatrixVec);
838 
839  ++numParam;
840  }
841 
842  tp.setTrackParameters(parametersVec);
843  unsigned int i = 0;
844  for (; i < positions.size(); ++i) {
845  tp.setParameterPosition(i, positions[i]);
846  if (positions[i] == xAOD::FirstMeasurement) {
847  float x_position = tp.parameterX(i);
848  float y_position = tp.parameterY(i);
849  tp.setRadiusOfFirstHit(std::sqrt(x_position * x_position + y_position * y_position));
850  tp.setIdentifierOfFirstHit(
851  parameters[i]->associatedSurface().associatedDetectorElementIdentifier().get_compact());
852  }
853  }
854 }

◆ setTilt()

void Trk::TrackParticleCreatorTool::setTilt ( xAOD::TrackParticle tp,
float  tiltx,
float  tilty 
)
static

Definition at line 857 of file TrackParticleCreatorTool.cxx.

858 {
859  tp.setBeamlineTiltX(tiltx);
860  tp.setBeamlineTiltY(tilty);
861 }

◆ setTrackInfo()

void Trk::TrackParticleCreatorTool::setTrackInfo ( xAOD::TrackParticle tp,
const TrackInfo trackInfo,
xAOD::ParticleHypothesis  prtOrigin 
) const

Method to set TrackInfo of a xAOD::TrackParticle.

◆ setTrackSummary()

void Trk::TrackParticleCreatorTool::setTrackSummary ( xAOD::TrackParticle tp,
const TrackSummary summary 
) const

Method to set TrackSummary of a xAOD::TrackParticle.

Definition at line 882 of file TrackParticleCreatorTool.cxx.

883 {
884  // ensure that xAOD TrackSummary and TrackSummary enums are in sync.
885  constexpr unsigned int xAodReferenceEnum1 = static_cast<unsigned int>(xAOD::numberOfTRTXenonHits);
886  constexpr unsigned int TrkReferenceEnum1 = static_cast<unsigned int>(Trk::numberOfTRTXenonHits);
887  static_assert(xAodReferenceEnum1 == TrkReferenceEnum1, "Trk and xAOD enums differ in their indices");
888  constexpr unsigned int xAodReferenceEnum2 = static_cast<unsigned int>(xAOD::numberOfTRTTubeHits);
889  constexpr unsigned int TrkReferenceEnum2 = static_cast<unsigned int>(Trk::numberOfTRTTubeHits);
890  static_assert(xAodReferenceEnum2 == TrkReferenceEnum2, "Trk and xAOD enums differ in their indices");
891 
892  for (unsigned int i = 0; i < Trk::numberOfTrackSummaryTypes; i++) {
893  // Only add values which are +ve (i.e., which were created)
895  continue;
896  }
898  continue;
899  }
901  continue;
902  }
903  // skip values which are floats
904  if (std::find(unusedSummaryTypes.begin(), unusedSummaryTypes.end(), i) != unusedSummaryTypes.end()) {
905  continue;
906  }
908  continue;
909  }
910  if (m_doITk && i == Trk::numberOfContribPixelLayers){ // Filled in addDetailedHitInformation for ITk
911  continue;
912  }
913 
914  int value = summary.get(static_cast<Trk::SummaryType>(i));
915  uint8_t uvalue = static_cast<uint8_t>(std::min(value,255));
916  // coverity[first_enum_type]
917  if (value > 0) {
918  tp.setSummaryValue(uvalue, static_cast<xAOD::SummaryType>(i));
919  }
920  }
921 
922  // muon hit info
923  if (!m_hitSummaryTool.empty()) {
924  ATH_MSG_DEBUG("now do muon hit info");
927  ATH_MSG_DEBUG("# of prec layers: " << static_cast<unsigned int>(numberOfPrecisionLayers));
935  tp.setSummaryValue(numberOfPhiLayers, xAOD::numberOfPhiLayers);
939  }
940 
941 }

◆ trtdEdxUsedHitsAuxName()

static const std::string& Trk::TrackParticleCreatorTool::trtdEdxUsedHitsAuxName ( )
inlinestatic

Get the name used for the decoration of the track particle with the number of used hits for TRT dE/dx computation.

Definition at line 201 of file TrackParticleCreatorTool.h.

202  {
204  }

Member Data Documentation

◆ m_assoMapContainer

SG::ReadHandleKey<Trk::PRDtoTrackMap> Trk::TrackParticleCreatorTool::m_assoMapContainer { this, "AssociationMapName", ""}
private

Definition at line 333 of file TrackParticleCreatorTool.h.

◆ m_badclusterID

IntegerProperty Trk::TrackParticleCreatorTool::m_badclusterID {this, "BadClusterID", 0}
private

Definition at line 319 of file TrackParticleCreatorTool.h.

◆ m_beamSpotKey

SG::ReadCondHandleKey<InDet::BeamSpotData> Trk::TrackParticleCreatorTool::m_beamSpotKey { this, "BeamSpotKey", "BeamSpotData", "SG key for beam spot" }
private

Definition at line 331 of file TrackParticleCreatorTool.h.

◆ m_checkConversion

BooleanProperty Trk::TrackParticleCreatorTool::m_checkConversion {this, "CheckConversion", true}
private

Definition at line 327 of file TrackParticleCreatorTool.h.

◆ m_clusterSplitProbContainer

SG::ReadHandleKey<Trk::ClusterSplitProbabilityContainer> Trk::TrackParticleCreatorTool::m_clusterSplitProbContainer { this, "ClusterSplitProbabilityName", "", "" }
private

Definition at line 332 of file TrackParticleCreatorTool.h.

◆ m_computeAdditionalInfo

BooleanProperty Trk::TrackParticleCreatorTool::m_computeAdditionalInfo {this, "ComputeAdditionalInfo", false}
private

Definition at line 302 of file TrackParticleCreatorTool.h.

◆ m_copyEProbabilities

std::vector<Trk::eProbabilityType> Trk::TrackParticleCreatorTool::m_copyEProbabilities
private

Enums of an eProbability which are set in the xAOD::TrackSummary.

Definition at line 285 of file TrackParticleCreatorTool.h.

◆ m_copyExtraSummaryName

StringArrayProperty Trk::TrackParticleCreatorTool::m_copyExtraSummaryName
private
Initial value:
{this, "ExtraSummaryTypes",
{"eProbabilityComb", "eProbabilityHT", "eProbabilityNN",
"TRTTrackOccupancy", "TRTdEdx", "TRTdEdxUsedHits"}}

Configurable to set the eProbabilities and extra track summary types which are to be copied from the track summary.

Definition at line 280 of file TrackParticleCreatorTool.h.

◆ m_decorateEProbabilities

std::vector<std::pair<SG::AuxElement::Accessor<float>, Trk::eProbabilityType> > Trk::TrackParticleCreatorTool::m_decorateEProbabilities
private

The pairs if enums of an eProbability which is added as a decoration to the track particle and the name of the decoration.

Definition at line 290 of file TrackParticleCreatorTool.h.

◆ m_decorateSummaryTypes

std::vector<std::pair<SG::AuxElement::Accessor<uint8_t>, Trk::SummaryType> > Trk::TrackParticleCreatorTool::m_decorateSummaryTypes
private

Definition at line 292 of file TrackParticleCreatorTool.h.

◆ m_dedxtool

ToolHandle<IPixelToTPIDTool> Trk::TrackParticleCreatorTool::m_dedxtool { this, "PixelToTPIDTool", "", "" }
private

tool to calculate dE/dx using pixel clusters

Definition at line 270 of file TrackParticleCreatorTool.h.

◆ m_detID

const AtlasDetectorID* Trk::TrackParticleCreatorTool::m_detID
private

atlas id helper

Definition at line 225 of file TrackParticleCreatorTool.h.

◆ m_doIBL

bool Trk::TrackParticleCreatorTool::m_doIBL
private

Definition at line 298 of file TrackParticleCreatorTool.h.

◆ m_doITk

BooleanProperty Trk::TrackParticleCreatorTool::m_doITk {this, "DoITk", false}
private

if the track contains a summary, the shared, expected hit, and PID information will be recomputed.

The summary of the track is not updated.

Definition at line 299 of file TrackParticleCreatorTool.h.

◆ m_doSharedSiHits

BooleanProperty Trk::TrackParticleCreatorTool::m_doSharedSiHits {this, "DoSharedSiHits", false}
private

Definition at line 303 of file TrackParticleCreatorTool.h.

◆ m_doSharedTRTHits

BooleanProperty Trk::TrackParticleCreatorTool::m_doSharedTRTHits {this, "DoSharedTRTHits", false}
private

Definition at line 304 of file TrackParticleCreatorTool.h.

◆ m_eProbabilityTool

ToolHandle<ITRT_ElectronPidTool> Trk::TrackParticleCreatorTool::m_eProbabilityTool
private
Initial value:
{ this,
"TRT_ElectronPidTool",
"",
"" }

tool to calculate electron probabilities

Definition at line 265 of file TrackParticleCreatorTool.h.

◆ m_fieldCacheCondObjInputKey

SG::ReadCondHandleKey<AtlasFieldCacheCondObj> Trk::TrackParticleCreatorTool::m_fieldCacheCondObjInputKey
private
Initial value:
{
this,
"AtlasFieldCacheCondObj",
"fieldCondObj",
"Name of the Magnetic Field conditions object key"
}

Definition at line 257 of file TrackParticleCreatorTool.h.

◆ m_hitSummaryTool

ToolHandle<Muon::IMuonHitSummaryTool> Trk::TrackParticleCreatorTool::m_hitSummaryTool
private
Initial value:
{
this,
"MuonSummaryTool",
""
}

Definition at line 242 of file TrackParticleCreatorTool.h.

◆ m_IBLParameterSvc

ServiceHandle<IIBLParameterSvc> Trk::TrackParticleCreatorTool::m_IBLParameterSvc
private
Initial value:
{
this,
"IBLParameterSvc",
"IBLParameterSvc"
}

Definition at line 248 of file TrackParticleCreatorTool.h.

◆ m_keepAllPerigee

BooleanProperty Trk::TrackParticleCreatorTool::m_keepAllPerigee {this, "KeepAllPerigee", false}
private

keep all MeasuredPerigee parameters (e.g.

adding those that may exist at Volume boundaries)

Definition at line 315 of file TrackParticleCreatorTool.h.

◆ m_keepFirstParameters

BooleanProperty Trk::TrackParticleCreatorTool::m_keepFirstParameters {this, "KeepFirstParameters", false}
private

Definition at line 312 of file TrackParticleCreatorTool.h.

◆ m_keepParameters

BooleanProperty Trk::TrackParticleCreatorTool::m_keepParameters {this, "KeepParameters", false}
private

the following keep options are mutually exclusive

keep all TrackParameters keep the first parameters when creating track particles.

Definition at line 310 of file TrackParticleCreatorTool.h.

◆ m_minPt

DoubleProperty Trk::TrackParticleCreatorTool::m_minPt {this, "MinPtForCaloExtrap", 1000.}
private

Definition at line 329 of file TrackParticleCreatorTool.h.

◆ m_minSiHits

IntegerProperty Trk::TrackParticleCreatorTool::m_minSiHits {this, "MinSiHitsForCaloExtrap", 4}
private

Definition at line 328 of file TrackParticleCreatorTool.h.

◆ m_perigeeExpression

StringProperty Trk::TrackParticleCreatorTool::m_perigeeExpression {this, "PerigeeExpression", "BeamLine"}
private

Definition at line 321 of file TrackParticleCreatorTool.h.

◆ m_perigeeOptions

std::vector<std::string> Trk::TrackParticleCreatorTool::m_perigeeOptions
private
Initial value:
{ "BeamLine",
"BeamSpot",
"Vertex",
"Origin" }

Definition at line 322 of file TrackParticleCreatorTool.h.

◆ m_pixelID

const PixelID* Trk::TrackParticleCreatorTool::m_pixelID
private

Definition at line 226 of file TrackParticleCreatorTool.h.

◆ m_runningTIDE_Ambi

BooleanProperty Trk::TrackParticleCreatorTool::m_runningTIDE_Ambi {this, "RunningTIDE_Ambi", false}
private

Definition at line 305 of file TrackParticleCreatorTool.h.

◆ m_sctID

const SCT_ID* Trk::TrackParticleCreatorTool::m_sctID
private

Definition at line 227 of file TrackParticleCreatorTool.h.

◆ m_testPixelLayerTool

ToolHandle<InDet::IInDetTestPixelLayerTool> Trk::TrackParticleCreatorTool::m_testPixelLayerTool
private
Initial value:
{ this,
"TestPixelLayerTool",
"",
"" }

tool to calculate expected hit information in innermost layers

Definition at line 273 of file TrackParticleCreatorTool.h.

◆ m_trackingVolumesSvc

ServiceHandle<ITrackingVolumesSvc> Trk::TrackParticleCreatorTool::m_trackingVolumesSvc {this,"TrackingVolumesSvc","Trk::TrackingVolumesSvc/TrackingVolumesSvc"}
private

Definition at line 254 of file TrackParticleCreatorTool.h.

◆ m_trackSummaryTool

PublicToolHandle<IExtendedTrackSummaryTool> Trk::TrackParticleCreatorTool::m_trackSummaryTool
private
Initial value:
{
this,
"TrackSummaryTool",
"Trk::TrackSummaryTool/AtlasTrackSummaryTool"
}

Definition at line 231 of file TrackParticleCreatorTool.h.

◆ m_trackToVertex

ToolHandle<Reco::ITrackToVertex> Trk::TrackParticleCreatorTool::m_trackToVertex
private
Initial value:
{
this,
"TrackToVertex",
"Reco::TrackToVertex/TrackToVertex"
}

Definition at line 237 of file TrackParticleCreatorTool.h.

◆ m_trtID

const TRT_ID* Trk::TrackParticleCreatorTool::m_trtID
private

Definition at line 228 of file TrackParticleCreatorTool.h.

◆ m_updateTrackSummary

BooleanProperty Trk::TrackParticleCreatorTool::m_updateTrackSummary {this, "UpdateTrackSummary", false}
private

Definition at line 306 of file TrackParticleCreatorTool.h.

◆ s_trtdEdxUsedHitsDecoration

const SG::AuxElement::Accessor< uint8_t > Trk::TrackParticleCreatorTool::s_trtdEdxUsedHitsDecoration
staticprivate

Definition at line 296 of file TrackParticleCreatorTool.h.

◆ s_trtdEdxUsedHitsDecorationName

const std::string Trk::TrackParticleCreatorTool::s_trtdEdxUsedHitsDecorationName { "TRTdEdxUsedHits" }
staticprivate

Name used for the decoration of the track particle with TRT dE/dx .

Definition at line 295 of file TrackParticleCreatorTool.h.


The documentation for this class was generated from the following files:
Muon::IMuonHitSummaryTool::CompactSummary::nphiHoleLayers
unsigned int nphiHoleLayers
number of eta trigger layer holes
Definition: IMuonHitSummaryTool.h:89
python.PyKernel.retrieve
def retrieve(aClass, aKey=None)
Definition: PyKernel.py:110
AtlasDetectorID::is_pixel
bool is_pixel(Identifier id) const
Definition: AtlasDetectorID.h:760
Trk::TrackParticleCreatorTool::m_sctID
const SCT_ID * m_sctID
Definition: TrackParticleCreatorTool.h:227
AllowedVariables::e
e
Definition: AsgElectronSelectorTool.cxx:37
Trk::numberOfContribPixelLayers
@ numberOfContribPixelLayers
number of contributing layers of the pixel detector
Definition: Tracking/TrkEvent/TrkTrackSummary/TrkTrackSummary/TrackSummary.h:49
xAOD::numberOfInnermostPixelLayerSplitHits
@ numberOfInnermostPixelLayerSplitHits
number of Pixel 0th layer barrel hits split by cluster splitting
Definition: TrackingPrimitives.h:240
xAOD::numberOfNextToInnermostPixelLayerSplitEndcapHits
@ numberOfNextToInnermostPixelLayerSplitEndcapHits
number of Pixel 1st layer endcap hits split by cluster splitting
Definition: TrackingPrimitives.h:256
Trk::TrackStateOnSurface::Perigee
@ Perigee
This represents a perigee, and so will contain a Perigee object only.
Definition: TrackStateOnSurface.h:117
Amg::compare
std::pair< int, int > compare(const AmgSymMatrix(N) &m1, const AmgSymMatrix(N) &m2, double precision=1e-9, bool relative=false)
compare two matrices, returns the indices of the first element that fails the condition,...
Definition: EventPrimitivesHelpers.h:109
Trk::TrackParticleCreatorTool::m_copyExtraSummaryName
StringArrayProperty m_copyExtraSummaryName
Configurable to set the eProbabilities and extra track summary types which are to be copied from the ...
Definition: TrackParticleCreatorTool.h:280
Trk::TrackParticleCreatorTool::m_testPixelLayerTool
ToolHandle< InDet::IInDetTestPixelLayerTool > m_testPixelLayerTool
tool to calculate expected hit information in innermost layers
Definition: TrackParticleCreatorTool.h:273
ATH_MSG_FATAL
#define ATH_MSG_FATAL(x)
Definition: AthMsgStreamMacros.h:34
Trk::TrackParticleCreatorTool::addDetailedHitInformation
void addDetailedHitInformation(const Trk::TrackStates *trackStates, xAOD::TrackParticle &tp) const
Add extra detailed hit summary info not computed in Trk::TrkSummary.
Definition: TrackParticleCreatorTool.cxx:993
Trk::TrackParticleCreatorTool::setDefiningParameters
void setDefiningParameters(xAOD::TrackParticle &tp, const Perigee &perigee) const
Method to set Defining parameters of a xAOD::TrackParticle.
TRTCalib_Extractor.hits
hits
Definition: TRTCalib_Extractor.py:35
Trk::Surface::associatedDetectorElement
const TrkDetElementBase * associatedDetectorElement() const
return associated Detector Element
get_generator_info.result
result
Definition: get_generator_info.py:21
Amg::compress
void compress(const AmgSymMatrix(N) &covMatrix, std::vector< float > &vec)
Definition: EventPrimitivesHelpers.h:56
xAOD::eProbabilityComb
@ eProbabilityComb
Electron probability from combining the below probabilities [float].
Definition: TrackingPrimitives.h:300
xAOD::numberOfPrecisionHoleLayers
@ numberOfPrecisionHoleLayers
layers with holes AND no hits [unit8_t].
Definition: TrackingPrimitives.h:289
xAOD::numberOfSCTSharedHits
@ numberOfSCTSharedHits
number of SCT hits shared by several tracks [unit8_t].
Definition: TrackingPrimitives.h:272
Muon::IMuonHitSummaryTool::CompactSummary::ntrigEtaHoleLayers
unsigned int ntrigEtaHoleLayers
number of precision holes
Definition: IMuonHitSummaryTool.h:88
Trk::TrackParticleCreatorTool::m_beamSpotKey
SG::ReadCondHandleKey< InDet::BeamSpotData > m_beamSpotKey
Definition: TrackParticleCreatorTool.h:331
SG::ReadCondHandle
Definition: ReadCondHandle.h:44
xAOD::uint8_t
uint8_t
Definition: Muon_v1.cxx:557
Trk::locX
@ locX
Definition: ParamDefs.h:37
find
std::string find(const std::string &s)
return a remapped string
Definition: hcg.cxx:135
Trk::locY
@ locY
local cartesian
Definition: ParamDefs.h:38
Trk::ClusterSplitProbabilityContainer::ProbabilityInfo::isSplit
bool isSplit() const
Definition: ClusterSplitProbabilityContainer.h:27
AtlasFieldCacheCondObj
Definition: AtlasFieldCacheCondObj.h:19
SG::Accessor
Helper class to provide type-safe access to aux data.
Definition: Control/AthContainers/AthContainers/Accessor.h:68
xAOD::numberOfContribPixelBarrelInclinedLayers
@ numberOfContribPixelBarrelInclinedLayers
number of contributing barrel inclined layers of the pixel detector [unit8_t].
Definition: TrackingPrimitives.h:309
Muon::IMuonHitSummaryTool::CompactSummary::nprecisionLayers
unsigned int nprecisionLayers
Definition: IMuonHitSummaryTool.h:84
xAOD::numberOfInnermostPixelLayerSharedEndcapHits
@ numberOfInnermostPixelLayerSharedEndcapHits
number of Pixel 0th layer endcap hits shared by several tracks.
Definition: TrackingPrimitives.h:244
Trk::TrackParticleCreatorTool::m_doSharedTRTHits
BooleanProperty m_doSharedTRTHits
Definition: TrackParticleCreatorTool.h:304
AtlasDetectorID::is_sct
bool is_sct(Identifier id) const
Definition: AtlasDetectorID.h:770
PixelID::barrel_ec
int barrel_ec(const Identifier &id) const
Values of different levels (failure returns 0)
Definition: PixelID.h:619
xAOD::BeamLine
@ BeamLine
Parameter defined at the Vertex/Beamline.
Definition: TrackingPrimitives.h:211
SG::ReadHandle< Trk::PRDtoTrackMap >
index
Definition: index.py:1
Trk::numberOfCscUnspoiltEtaHits
@ numberOfCscUnspoiltEtaHits
number of unspoilt CSC eta measurements (all CSC phi measurements are by definition spoilt).
Definition: Tracking/TrkEvent/TrkTrackSummary/TrkTrackSummary/TrackSummary.h:142
xAOD::numberOfNextToInnermostPixelLayerSplitHits
@ numberOfNextToInnermostPixelLayerSplitHits
number of Pixel 1st layer barrel hits split by cluster splitting
Definition: TrackingPrimitives.h:251
Trk::ParametersT
Dummy class used to allow special convertors to be called for surfaces owned by a detector element.
Definition: EMErrorDetail.h:25
Trk::ClusterSplitProbabilityContainer::ProbabilityInfo
Definition: ClusterSplitProbabilityContainer.h:22
Trk::TrackParticleCreatorTool::m_updateTrackSummary
BooleanProperty m_updateTrackSummary
Definition: TrackParticleCreatorTool.h:306
xAOD::numberOfTRTXenonHits
@ numberOfTRTXenonHits
number of TRT hits on track in straws with xenon [unit8_t].
Definition: TrackingPrimitives.h:284
Trk::indices
std::pair< long int, long int > indices
Definition: AlSymMatBase.h:24
InDetDD::SolidStateDetectorElementBase::etaAxis
const Amg::Vector3D & etaAxis() const
Definition: SolidStateDetectorElementBase.cxx:88
Trk::TrackParticleCreatorTool::m_computeAdditionalInfo
BooleanProperty m_computeAdditionalInfo
Definition: TrackParticleCreatorTool.h:302
Trk::numberOfCscEtaHoles
@ numberOfCscEtaHoles
number of CSC Eta measurements missing from the track
Definition: Tracking/TrkEvent/TrkTrackSummary/TrkTrackSummary/TrackSummary.h:112
PlotCalibFromCool.begin
begin
Definition: PlotCalibFromCool.py:94
Trk::numberOfTrackSummaryTypes
@ numberOfTrackSummaryTypes
Definition: Tracking/TrkEvent/TrkTrackSummary/TrkTrackSummary/TrackSummary.h:189
Trk::TrackParticleBase::trackSummary
const TrackSummary * trackSummary() const
accessor function for TrackSummary.
Definition: TrackParticleBase.h:247
xAOD::numberOfPhiHoleLayers
@ numberOfPhiHoleLayers
layers with trigger phi holes but no hits [unit8_t].
Definition: TrackingPrimitives.h:291
Muon::IMuonHitSummaryTool::CompactSummary::ntrigEtaLayers
unsigned int ntrigEtaLayers
number of phi layers
Definition: IMuonHitSummaryTool.h:86
xAOD::TrackParticle_v1::setTrackLink
void setTrackLink(const ElementLink< TrackCollection > &track)
Set the link to the original track.
Definition: TrackParticle_v1.cxx:795
Trk::ITrackingVolumesSvc::MuonSpectrometerEntryLayer
@ MuonSpectrometerEntryLayer
Tracking Volume which defines the entrance surfaces of the MS.
Definition: ITrackingVolumesSvc.h:41
Trk::TrackParticleCreatorTool::m_keepFirstParameters
BooleanProperty m_keepFirstParameters
Definition: TrackParticleCreatorTool.h:312
xAOD::numberOfContribPixelBarrelFlatLayers
@ numberOfContribPixelBarrelFlatLayers
number of contributing barrel flat layers of the pixel detector [unit8_t].
Definition: TrackingPrimitives.h:308
M_PI
#define M_PI
Definition: ActiveFraction.h:11
Muon::IMuonHitSummaryTool::CompactSummary
Definition: IMuonHitSummaryTool.h:70
Trk::TrackParticleCreatorTool::m_copyEProbabilities
std::vector< Trk::eProbabilityType > m_copyEProbabilities
Enums of an eProbability which are set in the xAOD::TrackSummary.
Definition: TrackParticleCreatorTool.h:285
Trk::one
@ one
Definition: TrkDetDescr/TrkSurfaces/TrkSurfaces/RealQuadraticEquation.h:22
ParticleTest.tp
tp
Definition: ParticleTest.py:25
Trk::TrackParticleCreatorTool::m_detID
const AtlasDetectorID * m_detID
atlas id helper
Definition: TrackParticleCreatorTool.h:225
athena.value
value
Definition: athena.py:124
Trk::RIO_OnTrack::rioType
virtual bool rioType(RIO_OnTrackType::Type type) const =0
Method checking the Rio On Track type.
Trk::TrackParticleCreatorTool::setTilt
static void setTilt(xAOD::TrackParticle &tp, float tiltx, float tilty)
Definition: TrackParticleCreatorTool.cxx:857
Trk::RIO_OnTrack
Definition: RIO_OnTrack.h:70
xAOD::expectInnermostPixelLayerHit
@ expectInnermostPixelLayerHit
Do we expect a 0th-layer barrel hit for this track?
Definition: TrackingPrimitives.h:236
xAOD::Vertex_v1::position
const Amg::Vector3D & position() const
Returns the 3-pos.
AtlasDetectorID::is_trt
bool is_trt(Identifier id) const
Definition: AtlasDetectorID.h:782
Trk::numberOfMmHoles
@ numberOfMmHoles
number of TGC Eta measurements missing from the track
Definition: Tracking/TrkEvent/TrkTrackSummary/TrkTrackSummary/TrackSummary.h:138
read_hist_ntuple.t
t
Definition: read_hist_ntuple.py:5
drawFromPickle.cos
cos
Definition: drawFromPickle.py:36
xAOD::numberOfTRTTubeHits
@ numberOfTRTTubeHits
number of TRT tube hits [unit8_t].
Definition: TrackingPrimitives.h:283
xAOD::LastMeasurement
@ LastMeasurement
Parameter defined at the position of the last measurement.
Definition: TrackingPrimitives.h:215
Trk::TrkDetElementBase::identify
virtual Identifier identify() const =0
Identifier.
ATH_MSG_VERBOSE
#define ATH_MSG_VERBOSE(x)
Definition: AthMsgStreamMacros.h:28
SG::VarHandleKey::key
const std::string & key() const
Return the StoreGate ID for the referenced object.
Definition: AthToolSupport/AsgDataHandles/Root/VarHandleKey.cxx:141
Muon::IMuonHitSummaryTool::CompactSummary::nprecisionHoleLayers
unsigned int nprecisionHoleLayers
number of eta trigger layers
Definition: IMuonHitSummaryTool.h:87
MagField::AtlasFieldCache::toroidOn
bool toroidOn() const
Trk::Perigee
ParametersT< TrackParametersDim, Charged, PerigeeSurface > Perigee
Definition: Tracking/TrkEvent/TrkParameters/TrkParameters/TrackParameters.h:33
python.SystemOfUnits.ms
int ms
Definition: SystemOfUnits.py:132
Trk::TrackParticleCreatorTool::m_runningTIDE_Ambi
BooleanProperty m_runningTIDE_Ambi
Definition: TrackParticleCreatorTool.h:305
xAOD::numberOfInnermostPixelLayerEndcapOutliers
@ numberOfInnermostPixelLayerEndcapOutliers
number of 0th layer endcap outliers
Definition: TrackingPrimitives.h:243
InDetDD::PixelInclined
@ PixelInclined
Definition: DetectorDesign.h:46
Trk::TrackParticleCreatorTool::m_decorateSummaryTypes
std::vector< std::pair< SG::AuxElement::Accessor< uint8_t >, Trk::SummaryType > > m_decorateSummaryTypes
Definition: TrackParticleCreatorTool.h:292
AthenaPoolTestRead.sc
sc
Definition: AthenaPoolTestRead.py:27
Trk::TrackParticleCreatorTool::m_checkConversion
BooleanProperty m_checkConversion
Definition: TrackParticleCreatorTool.h:327
python.Bindings.values
values
Definition: Control/AthenaPython/python/Bindings.py:805
mergePhysValFiles.end
end
Definition: DataQuality/DataQualityUtils/scripts/mergePhysValFiles.py:93
Trk::eProbabilityNumberOfTRTHitsUsedFordEdx
@ eProbabilityNumberOfTRTHitsUsedFordEdx
Number of TRT hits used for dEdx measurement.
Definition: Tracking/TrkEvent/TrkTrackSummary/TrkTrackSummary/TrackSummary.h:220
Trk::TrackParticleCreatorTool::m_trackingVolumesSvc
ServiceHandle< ITrackingVolumesSvc > m_trackingVolumesSvc
Definition: TrackParticleCreatorTool.h:254
Trk::eProbabilityType
eProbabilityType
Definition: Tracking/TrkEvent/TrkTrackSummary/TrkTrackSummary/TrackSummary.h:209
Trk::TrackStateOnSurface::Outlier
@ Outlier
This TSoS contains an outlier, that is, it contains a MeasurementBase/RIO_OnTrack which was not used ...
Definition: TrackStateOnSurface.h:122
IDTPM::nSCTSharedHits
float nSCTSharedHits(const U &p)
Definition: TrackParametersHelper.h:385
xAOD::TrackParticle
TrackParticle_v1 TrackParticle
Reference the current persistent version:
Definition: Event/xAOD/xAODTracking/xAODTracking/TrackParticle.h:13
Trk::AmgSymMatrix
AmgSymMatrix(5) &GXFTrackState
Definition: GXFTrackState.h:156
Trk::TrackParticleCreatorTool::setTrackInfo
void setTrackInfo(xAOD::TrackParticle &tp, const TrackInfo &trackInfo, xAOD::ParticleHypothesis prtOrigin) const
Method to set TrackInfo of a xAOD::TrackParticle.
xAOD::numberOfTRTSharedHits
@ numberOfTRTSharedHits
number of TRT hits used by more than one track
Definition: TrackingPrimitives.h:285
Trk::TrackParticleCreatorTool::addDummyEndcapSharedHitInformation
static void addDummyEndcapSharedHitInformation(xAOD::TrackParticle &tp)
Add dummy endcap shared hit info as AuxDyn variable in case nominal shared hit info not computed (for...
Definition: TrackParticleCreatorTool.cxx:1283
python.setupRTTAlg.size
int size
Definition: setupRTTAlg.py:39
xAOD::numberOfContribPixelEndcap
@ numberOfContribPixelEndcap
number of contributing endcap layers of the pixel detector [unit8_t].
Definition: TrackingPrimitives.h:310
Trk::TrackParticleCreatorTool::m_assoMapContainer
SG::ReadHandleKey< Trk::PRDtoTrackMap > m_assoMapContainer
Definition: TrackParticleCreatorTool.h:333
xAOD::numberOfInnermostPixelLayerOutliers
@ numberOfInnermostPixelLayerOutliers
number of 0th layer barrel outliers
Definition: TrackingPrimitives.h:238
xAOD::numberOfNextToInnermostPixelLayerSharedEndcapHits
@ numberOfNextToInnermostPixelLayerSharedEndcapHits
number of Pixel 1st layer endcap hits shared by several tracks.
Definition: TrackingPrimitives.h:255
Trk::pixelBarrelFlat
@ pixelBarrelFlat
Definition: DetailedHitInfo.h:14
PixelID::is_barrel
bool is_barrel(const Identifier &id) const
Test for barrel - WARNING: id MUST be pixel id, otherwise answer is not accurate. Use SiliconID for g...
Definition: PixelID.h:605
xAOD::TrackParticle_v1::perigeeParameters
const Trk::Perigee & perigeeParameters() const
Returns the Trk::MeasuredPerigee track parameters.
Definition: TrackParticle_v1.cxx:485
xAOD::numberOfInnermostPixelLayerEndcapHits
@ numberOfInnermostPixelLayerEndcapHits
these are the hits in the 0th pixel layer endcap [unit8_t].
Definition: TrackingPrimitives.h:242
xAOD::numberOfPixelSharedHits
@ numberOfPixelSharedHits
number of Pixel all-layer hits shared by several tracks [unit8_t].
Definition: TrackingPrimitives.h:262
Trk::TrackParticleCreatorTool::m_trackToVertex
ToolHandle< Reco::ITrackToVertex > m_trackToVertex
Definition: TrackParticleCreatorTool.h:237
Trk::DetailedHitInfo::getHits
int getHits(Trk::DetectorRegion region, int layer)
Definition: DetailedHitInfo.cxx:82
python.utils.AtlRunQueryDQUtils.p
p
Definition: AtlRunQueryDQUtils.py:210
xAOD::SummaryType
SummaryType
Enumerates the different types of information stored in Summary.
Definition: TrackingPrimitives.h:228
Trk::TrackParticleCreatorTool::m_trackSummaryTool
PublicToolHandle< IExtendedTrackSummaryTool > m_trackSummaryTool
Definition: TrackParticleCreatorTool.h:231
ParticleGun_EoverP_Config.mom
mom
Definition: ParticleGun_EoverP_Config.py:63
Trk::TrackParticleCreatorTool::addExpectedHitInformation
void addExpectedHitInformation(const Perigee *perigee, xAOD::TrackParticle &tp) const
Add expected hit info for innermost pixel layers not computed in Trk::TrkSummary.
Definition: TrackParticleCreatorTool.cxx:1050
Amg::toString
std::string toString(const Translation3D &translation, int precision=4)
GeoPrimitvesToStringConverter.
Definition: GeoPrimitivesToStringConverter.h:40
Trk::numberOfTRTTubeHits
@ numberOfTRTTubeHits
number of TRT hits on track in straws with xenon
Definition: Tracking/TrkEvent/TrkTrackSummary/TrkTrackSummary/TrackSummary.h:97
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition: AthMsgStreamMacros.h:33
xAOD::expectNextToInnermostPixelLayerHit
@ expectNextToInnermostPixelLayerHit
Do we expect a 1st-layer barrel hit for this track?
Definition: TrackingPrimitives.h:247
Muon::IMuonHitSummaryTool::CompactSummary::nphiLayers
unsigned int nphiLayers
number of precision layers
Definition: IMuonHitSummaryTool.h:85
Trk::DetailedHitInfo::getPixelContributions
int getPixelContributions()
Definition: DetailedHitInfo.cxx:116
xAOD::numberOfTriggerEtaLayers
@ numberOfTriggerEtaLayers
layers with trigger eta hits [unit8_t].
Definition: TrackingPrimitives.h:292
Trk::TrackParticleCreatorTool::m_trtID
const TRT_ID * m_trtID
Definition: TrackParticleCreatorTool.h:228
xAOD::numberOfPixelBarrelFlatHits
@ numberOfPixelBarrelFlatHits
these are the pixel hits, in the barrel flat layers [unit8_t].
Definition: TrackingPrimitives.h:311
xAOD::numberOfTriggerEtaHoleLayers
@ numberOfTriggerEtaHoleLayers
layers with trigger eta holes but no hits [unit8_t].
Definition: TrackingPrimitives.h:293
InDetDD::DetectorType
DetectorType
Definition: DetectorDesign.h:45
lumiFormat.i
int i
Definition: lumiFormat.py:85
Trk::TrackParticleCreatorTool::CacheBeamSpotData
virtual const InDet::BeamSpotData * CacheBeamSpotData(const EventContext &ctx) const override final
Definition: TrackParticleCreatorTool.cxx:1314
Trk::TrackParticleCreatorTool::m_doSharedSiHits
BooleanProperty m_doSharedSiHits
Definition: TrackParticleCreatorTool.h:303
beamspotman.n
n
Definition: beamspotman.py:731
Trk::TrackParticleBase::trackElementLink
const ElementLink< TrackCollection > * trackElementLink() const
Return the ElementLink to the Track.
Definition: TrackParticleBase.h:230
Trk::theta
@ theta
Definition: ParamDefs.h:66
xAOD::FirstMeasurement
@ FirstMeasurement
Parameter defined at the position of the 1st measurement.
Definition: TrackingPrimitives.h:213
Trk::TrackParticleCreatorTool::m_pixelID
const PixelID * m_pixelID
Definition: TrackParticleCreatorTool.h:226
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
Trk::TrackParticleCreatorTool::setTrackSummary
void setTrackSummary(xAOD::TrackParticle &tp, const TrackSummary &summary) const
Method to set TrackSummary of a xAOD::TrackParticle.
Definition: TrackParticleCreatorTool.cxx:882
TRT::Hit::layer
@ layer
Definition: HitInfo.h:79
Amg::Transform3D
Eigen::Affine3d Transform3D
Definition: GeoPrimitives.h:46
Trk::TrackParticleBase::fitQuality
const FitQuality * fitQuality() const
accessor function for FitQuality.
Definition: TrackParticleBase.h:259
Trk::TrackParticleCreatorTool::setFitQuality
void setFitQuality(xAOD::TrackParticle &tp, const FitQuality &fq) const
Method to set FitQuality of a xAOD::TrackParticle.
Trk::pixelEndcap
@ pixelEndcap
Definition: DetailedHitInfo.h:16
Trk::TrackParticleCreatorTool::m_perigeeExpression
StringProperty m_perigeeExpression
Definition: TrackParticleCreatorTool.h:321
InDetDD::DetectorDesign::type
virtual DetectorType type() const
Type of element.
Definition: DetectorDesign.cxx:101
xAOD::numberOfPixelOutliers
@ numberOfPixelOutliers
these are the pixel outliers, including the b-layer [unit8_t].
Definition: TrackingPrimitives.h:260
ATH_CHECK
#define ATH_CHECK
Definition: AthCheckMacros.h:40
Trk::MeasurementBase::type
virtual bool type(MeasurementBaseType::Type type) const =0
Interface method checking the type.
drawFromPickle.tan
tan
Definition: drawFromPickle.py:36
Trk::ParametersBase
Definition: ParametersBase.h:55
SG::VarHandleKey::initialize
StatusCode initialize(bool used=true)
If this object is used as a property, then this should be called during the initialize phase.
Definition: AthToolSupport/AsgDataHandles/Root/VarHandleKey.cxx:103
xAOD::numberOfPixelSplitHits
@ numberOfPixelSplitHits
number of Pixel all-layer hits split by cluster splitting [unit8_t].
Definition: TrackingPrimitives.h:263
Trk::DetailedHitInfo::addHit
void addHit(Trk::DetectorRegion region, int layer, int etaModule, int hit=1)
This class containes the detailed information on the contributing layers and regions to the hit count...
Definition: DetailedHitInfo.cxx:59
xAOD::numberOfInnermostPixelLayerSplitEndcapHits
@ numberOfInnermostPixelLayerSplitEndcapHits
number of Pixel 0th layer endcap hits shared by several tracks.
Definition: TrackingPrimitives.h:245
Trk::TrackParticleCreatorTool::m_fieldCacheCondObjInputKey
SG::ReadCondHandleKey< AtlasFieldCacheCondObj > m_fieldCacheCondObjInputKey
Definition: TrackParticleCreatorTool.h:257
DataVector< const Trk::MeasurementBase >
InDetDD::SolidStateDetectorElementBase::normal
virtual const Amg::Vector3D & normal() const override final
Get reconstruction local normal axes in global frame.
InDet::SiCluster::detectorElement
virtual const InDetDD::SiDetectorElement * detectorElement() const override final
return the detector element corresponding to this PRD The pointer will be zero if the det el is not d...
LB_AnalMapSplitter.tot
tot
Definition: LB_AnalMapSplitter.py:46
trackInfo
Definition: TrigInDetUtils.h:13
MagField::AtlasFieldCache::solenoidOn
bool solenoidOn() const
status of the magnets
Trk::numberOfStgcEtaHits
@ numberOfStgcEtaHits
number of TGC Eta measurements missing from the track
Definition: Tracking/TrkEvent/TrkTrackSummary/TrkTrackSummary/TrackSummary.h:128
xAOD::numberOfNextToInnermostPixelLayerEndcapHits
@ numberOfNextToInnermostPixelLayerEndcapHits
these are the hits in the 0.5th and 1st pixel layer endcap rings [unit8_t].
Definition: TrackingPrimitives.h:253
min
#define min(a, b)
Definition: cfImp.cxx:40
Trk::ITrackingVolumesSvc::CalorimeterEntryLayer
@ CalorimeterEntryLayer
Tracking Volume which defines the entrance srufaces of the calorimeter.
Definition: ITrackingVolumesSvc.h:40
Trk::numberOfTgcPhiHoles
@ numberOfTgcPhiHoles
number of TGC Phi measurements missing from the track
Definition: Tracking/TrkEvent/TrkTrackSummary/TrkTrackSummary/TrackSummary.h:124
Trk::pixelBarrelInclined
@ pixelBarrelInclined
Definition: DetailedHitInfo.h:15
mergePhysValFiles.errors
list errors
Definition: DataQuality/DataQualityUtils/scripts/mergePhysValFiles.py:43
InDetDD::SiDetectorElement::isPixel
bool isPixel() const
Trk::PrepRawData
Definition: PrepRawData.h:62
Trk::MeasurementBase
Definition: MeasurementBase.h:58
PixelID::layer_disk
int layer_disk(const Identifier &id) const
Definition: PixelID.h:626
python.PyKernel.detStore
detStore
Definition: PyKernel.py:41
PixelID::eta_module
int eta_module(const Identifier &id) const
Definition: PixelID.h:651
xAOD::numberOfNextToInnermostPixelLayerOutliers
@ numberOfNextToInnermostPixelLayerOutliers
number of 1st pixel layer barrel outliers
Definition: TrackingPrimitives.h:249
xAOD::numberOfNextToInnermostPixelLayerHits
@ numberOfNextToInnermostPixelLayerHits
these are the hits in the 1st pixel barrel layer
Definition: TrackingPrimitives.h:248
Trk::SurfaceType::Perigee
@ Perigee
Trk::TrackSummary
A summary of the information contained by a track.
Definition: Tracking/TrkEvent/TrkTrackSummary/TrkTrackSummary/TrackSummary.h:287
Trk::MeasurementBase::associatedSurface
virtual const Surface & associatedSurface() const =0
Interface method to get the associated Surface.
DataVector< const Trk::TrackStateOnSurface >::const_reverse_iterator
std::reverse_iterator< const_iterator > const_reverse_iterator
Standard const_reverse_iterator.
Definition: DataVector.h:846
Trk::TrackParticleCreatorTool::m_hitSummaryTool
ToolHandle< Muon::IMuonHitSummaryTool > m_hitSummaryTool
Definition: TrackParticleCreatorTool.h:242
Trk::TrackParticleBase::trackParameters
const std::vector< const TrackParameters * > & trackParameters() const
Returns the track parameters.
Definition: TrackParticleBase.h:243
InDetDD::PixelBarrel
@ PixelBarrel
Definition: DetectorDesign.h:46
charge
double charge(const T &p)
Definition: AtlasPID.h:538
InDetDD::SiDetectorElement
Definition: SiDetectorElement.h:109
DataVector::push_back
value_type push_back(value_type pElem)
Add an element to the end of the collection.
SG::CondHandleKey::initialize
StatusCode initialize(bool used=true)
Trk::TrackParticleCreatorTool::m_decorateEProbabilities
std::vector< std::pair< SG::AuxElement::Accessor< float >, Trk::eProbabilityType > > m_decorateEProbabilities
The pairs if enums of an eProbability which is added as a decoration to the track particle and the na...
Definition: TrackParticleCreatorTool.h:290
SG::AuxElement::makePrivateStore
void makePrivateStore()
Create a new (empty) private store for this object.
Definition: AuxElement.cxx:172
xAOD::TrackParticle_v1::numberOfParameters
size_t numberOfParameters() const
Returns the number of additional parameters stored in the TrackParticle.
Definition: TrackParticle_v1.cxx:553
xAOD::ParticleHypothesis
ParticleHypothesis
Definition: TrackingPrimitives.h:192
Amg::Vector3D
Eigen::Matrix< double, 3, 1 > Vector3D
Definition: GeoPrimitives.h:47
Trk::RIO_OnTrack::prepRawData
virtual const Trk::PrepRawData * prepRawData() const =0
returns the PrepRawData (also known as RIO) object to which this RIO_OnTrack is associated.
Trk::MeasurementBaseType::RIO_OnTrack
@ RIO_OnTrack
Definition: MeasurementBase.h:49
Trk::TrackParticleCreatorTool::addPIDInformation
void addPIDInformation(const EventContext &ctx, const Track *track, xAOD::TrackParticle &tp) const
Add Pixel and TRT PID information to the track particle.
Definition: TrackParticleCreatorTool.cxx:944
python.LumiBlobConversion.pos
pos
Definition: LumiBlobConversion.py:18
Rec::TrackParticle::measuredPerigee
const Trk::Perigee * measuredPerigee() const
Accessor method for Perigee.
Definition: Reconstruction/Particle/Particle/TrackParticle.h:180
xAOD::numberOfPixelBarrelInclinedHits
@ numberOfPixelBarrelInclinedHits
these are the pixel hits, in the barrel inclined layers [unit8_t].
Definition: TrackingPrimitives.h:312
Trk::DetectorRegion
DetectorRegion
Definition: DetailedHitInfo.h:13
Trk::DetailedHitInfo::getContributionFromRegion
int getContributionFromRegion(Trk::DetectorRegion region)
Definition: DetailedHitInfo.cxx:96
InDet::PixelCluster
Definition: InnerDetector/InDetRecEvent/InDetPrepRawData/InDetPrepRawData/PixelCluster.h:49
Trk::pixelCluster
@ pixelCluster
Definition: MeasurementType.h:22
Trk::AtaSurface
@ AtaSurface
Definition: ParametersCommon.h:29
Trk::TrackParticleCreatorTool::m_keepParameters
BooleanProperty m_keepParameters
the following keep options are mutually exclusive
Definition: TrackParticleCreatorTool.h:310
Base_Fragment.width
width
Definition: Sherpa_i/share/common/Base_Fragment.py:59
Trk::TrackParticleCreatorTool::setParameters
void setParameters(const EventContext &ctx, xAOD::TrackParticle &tp, const std::vector< const Trk::TrackParameters * > &parameters, const std::vector< xAOD::ParameterPosition > &positions) const
Method to set parameters of a xAOD::TrackParticle.
Definition: TrackParticleCreatorTool.cxx:778
InDet::PixelClusterOnTrack
Definition: PixelClusterOnTrack.h:51
xAOD::numberOfSCTOutliers
@ numberOfSCTOutliers
number of SCT outliers [unit8_t].
Definition: TrackingPrimitives.h:269
ATH_MSG_WARNING
#define ATH_MSG_WARNING(x)
Definition: AthMsgStreamMacros.h:32
InDetDD::SolidStateDetectorElementBase::phiAxis
const Amg::Vector3D & phiAxis() const
Definition: SolidStateDetectorElementBase.cxx:74
python.CaloScaleNoiseConfig.type
type
Definition: CaloScaleNoiseConfig.py:78
xAOD::numberOfNextToInnermostPixelLayerEndcapOutliers
@ numberOfNextToInnermostPixelLayerEndcapOutliers
number of 1st layer endcap disk outliers
Definition: TrackingPrimitives.h:254
DeMoScan.first
bool first
Definition: DeMoScan.py:536
Trk::RIO_OnTrack::identify
Identifier identify() const
return the identifier -extends MeasurementBase
Definition: RIO_OnTrack.h:152
MagField::AtlasFieldCache
Local cache for magnetic field (based on MagFieldServices/AtlasFieldSvcTLS.h)
Definition: AtlasFieldCache.h:43
Trk::qOverP
@ qOverP
perigee
Definition: ParamDefs.h:67
Trk::TrackParticleCreatorTool::m_perigeeOptions
std::vector< std::string > m_perigeeOptions
Definition: TrackParticleCreatorTool.h:322
if
if(febId1==febId2)
Definition: LArRodBlockPhysicsV0.cxx:567
InDet::SiWidth
Definition: SiWidth.h:25
Trk::TrackParticleCreatorTool::compare
void compare(const Rec::TrackParticle &tp, const xAOD::TrackParticle &tpx) const
Definition: TrackParticleCreatorTool.cxx:764
xAOD::numberOfInnermostPixelLayerSharedHits
@ numberOfInnermostPixelLayerSharedHits
number of Pixel 0th layer barrel hits shared by several tracks.
Definition: TrackingPrimitives.h:239
Trk::TrackParticleCreatorTool::addSharedHitInformation
void addSharedHitInformation(const Track *track, xAOD::TrackParticle &tp) const
Add shared hit info not computed in Trk::TrkSummary anymore.
Definition: TrackParticleCreatorTool.cxx:1162
MagField::AtlasFieldCache::getField
void getField(const double *ATH_RESTRICT xyz, double *ATH_RESTRICT bxyz, double *ATH_RESTRICT deriv=nullptr)
get B field value at given position xyz[3] is in mm, bxyz[3] is in kT if deriv[9] is given,...
Definition: AtlasFieldCache.cxx:42
physics_parameters.parameters
parameters
Definition: physics_parameters.py:144
xAOD::numberOfContribPixelLayers
@ numberOfContribPixelLayers
number of contributing layers of the pixel detector [unit8_t].
Definition: TrackingPrimitives.h:230
Trk::TrackParticleCreatorTool::m_keepAllPerigee
BooleanProperty m_keepAllPerigee
keep all MeasuredPerigee parameters (e.g.
Definition: TrackParticleCreatorTool.h:315
Trk::MeasurementBaseType::PseudoMeasurementOnTrack
@ PseudoMeasurementOnTrack
Definition: MeasurementBase.h:51
Trk::TrackParticleCreatorTool::m_doITk
BooleanProperty m_doITk
if the track contains a summary, the shared, expected hit, and PID information will be recomputed.
Definition: TrackParticleCreatorTool.h:299
Trk::TrackParticleCreatorTool::m_doIBL
bool m_doIBL
Definition: TrackParticleCreatorTool.h:298
Trk::DetailedHitInfo::getHitsFromRegion
int getHitsFromRegion(Trk::DetectorRegion region)
Definition: DetailedHitInfo.cxx:106
xAOD::numberOfPixelEndcapHits
@ numberOfPixelEndcapHits
these are the pixel hits, in the endcap layers [unit8_t].
Definition: TrackingPrimitives.h:313
Trk::DetailedHitInfo
Definition: DetailedHitInfo.h:24
Trk::TrackParticleCreatorTool::s_trtdEdxUsedHitsDecorationName
static const std::string s_trtdEdxUsedHitsDecorationName
Name used for the decoration of the track particle with TRT dE/dx .
Definition: TrackParticleCreatorTool.h:295
Trk::TrackParticleCreatorTool::m_badclusterID
IntegerProperty m_badclusterID
Definition: TrackParticleCreatorTool.h:319
Trk::TrackParticleCreatorTool::m_eProbabilityTool
ToolHandle< ITRT_ElectronPidTool > m_eProbabilityTool
tool to calculate electron probabilities
Definition: TrackParticleCreatorTool.h:265
Trk::SummaryType
SummaryType
enumerates the different types of information stored in Summary.
Definition: Tracking/TrkEvent/TrkTrackSummary/TrkTrackSummary/TrackSummary.h:45
xAOD::track
@ track
Definition: TrackingPrimitives.h:512
calibdata.copy
bool copy
Definition: calibdata.py:27
xAOD::TrackParticle_v1
Class describing a TrackParticle.
Definition: TrackParticle_v1.h:43
Trk::numberOfRpcEtaHits
@ numberOfRpcEtaHits
Definition: Tracking/TrkEvent/TrkTrackSummary/TrkTrackSummary/TrackSummary.h:110
drawFromPickle.sin
sin
Definition: drawFromPickle.py:36
Trk::TrackParticleCreatorTool::m_dedxtool
ToolHandle< IPixelToTPIDTool > m_dedxtool
tool to calculate dE/dx using pixel clusters
Definition: TrackParticleCreatorTool.h:270
pix
Definition: PixelMapping.cxx:16
Trk::TrackParticleCreatorTool::addOutlierHitInformation
void addOutlierHitInformation(const Trk::TrackStates *trackStates, xAOD::TrackParticle &tp) const
Add outlier hit info not computed in Trk::TrkSummary anymore.
Definition: TrackParticleCreatorTool.cxx:1099
Trk::numberOfeProbabilityTypes
@ numberOfeProbabilityTypes
Definition: Tracking/TrkEvent/TrkTrackSummary/TrkTrackSummary/TrackSummary.h:222
InDetDD::SiDetectorElement::design
virtual const SiDetectorDesign & design() const override final
access to the local description (inline):
xAOD::numberOfNextToInnermostPixelLayerSharedHits
@ numberOfNextToInnermostPixelLayerSharedHits
number of Pixel 1st layer barrel hits shared by several tracks.
Definition: TrackingPrimitives.h:250
Trk::TrackParticleCreatorTool::m_clusterSplitProbContainer
SG::ReadHandleKey< Trk::ClusterSplitProbabilityContainer > m_clusterSplitProbContainer
Definition: TrackParticleCreatorTool.h:332
xAOD::numberOfPhiLayers
@ numberOfPhiLayers
layers with a trigger phi hit [unit8_t].
Definition: TrackingPrimitives.h:290
Trk::ITrackingVolumesSvc::MuonSpectrometerExitLayer
@ MuonSpectrometerExitLayer
Tracking Volume which defines the outer surfaces of the MS.
Definition: ITrackingVolumesSvc.h:42
Trk::RIO_OnTrackType::PixelCluster
@ PixelCluster
Definition: RIO_OnTrack.h:57
Trk::numberOfTRTXenonHits
@ numberOfTRTXenonHits
Definition: Tracking/TrkEvent/TrkTrackSummary/TrkTrackSummary/TrackSummary.h:99
Trk::ClusterSplitProbabilityContainer::getNoSplitProbability
static const ProbabilityInfo & getNoSplitProbability()
Definition: ClusterSplitProbabilityContainer.h:33
length
double length(const pvec &v)
Definition: FPGATrackSimLLPDoubletHoughTransformTool.cxx:26
Trk::TrackParticleCreatorTool::createParticle
virtual xAOD::TrackParticle * createParticle(const EventContext &ctx, const Rec::TrackParticle &trackParticle, xAOD::TrackParticleContainer *container) const override final
Method to construct a xAOD::TrackParticle from a Rec::TrackParticle.
Definition: TrackParticleCreatorTool.cxx:593
InDet::SiCluster
Definition: InnerDetector/InDetRecEvent/InDetPrepRawData/InDetPrepRawData/SiCluster.h:40
zero
void zero(TH2 *h)
zero the contents of a 2d histogram
Definition: comparitor.cxx:435
Trk::TrackParticleCreatorTool::getClusterSplittingProbability
const Trk::ClusterSplitProbabilityContainer::ProbabilityInfo & getClusterSplittingProbability(const InDet::PixelCluster *pix) const
Definition: TrackParticleCreatorTool.cxx:1298
Trk::TrackStateOnSurface::Measurement
@ Measurement
This is a measurement, and will at least contain a Trk::MeasurementBase.
Definition: TrackStateOnSurface.h:101
Trk::TrackInfo::particleHypothesis
ParticleHypothesis particleHypothesis() const
Returns the particle hypothesis used for Track fitting.
Trk::numberOfMdtHits
@ numberOfMdtHits
number of mdt hits
Definition: Tracking/TrkEvent/TrkTrackSummary/TrkTrackSummary/TrackSummary.h:103
xAOD::numberOfInnermostPixelLayerHits
@ numberOfInnermostPixelLayerHits
these are the hits in the 0th pixel barrel layer
Definition: TrackingPrimitives.h:237
InDet::SiClusterOnTrack
Definition: SiClusterOnTrack.h:39
Trk::TrackParticleBase::info
const TrackInfo & info() const
returns the info of the track.
Definition: TrackParticleBase.h:276
Trk::TrackParticleCreatorTool::setHitPattern
static void setHitPattern(xAOD::TrackParticle &tp, unsigned long hitpattern)
Definition: TrackParticleCreatorTool.cxx:864
xAOD::numberOfPrecisionLayers
@ numberOfPrecisionLayers
layers with at least 3 hits [unit8_t].
Definition: TrackingPrimitives.h:288
Trk::TrackInfo::Unknown
@ Unknown
Track fitter not defined.
Definition: Tracking/TrkEvent/TrkTrack/TrkTrack/TrackInfo.h:41
Identifier
Definition: IdentifierFieldParser.cxx:14
SCT_Monitoring::summary
@ summary
Definition: SCT_MonitoringNumbers.h:65
Trk::TrackParticleCreatorTool::m_IBLParameterSvc
ServiceHandle< IIBLParameterSvc > m_IBLParameterSvc
Definition: TrackParticleCreatorTool.h:248