|
ATLAS Offline Software
|
#include <TrackParticleCreatorTool.h>
|
| TrackParticleCreatorTool (const std::string &, const std::string &, const IInterface *) |
|
virtual | ~TrackParticleCreatorTool ()=default |
|
virtual StatusCode | initialize () override |
|
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. More...
|
|
virtual xAOD::TrackParticle * | createParticle (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::TrackParticle * | createParticle (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::TrackParticle * | createParticle (const EventContext &ctx, const Perigee *perigee, const FitQuality *fq, const TrackInfo *trackInfo, const TrackSummary *summary, const std::vector< const Trk::TrackParameters * > ¶meters, 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::BeamSpotData * | CacheBeamSpotData (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 * > ¶meters, const std::vector< xAOD::ParameterPosition > &positions) const |
| Method to set parameters of a xAOD::TrackParticle. More...
|
|
|
const AtlasDetectorID * | m_detID |
| atlas id helper More...
|
|
const PixelID * | m_pixelID |
|
const SCT_ID * | m_sctID |
|
const TRT_ID * | m_trtID |
|
PublicToolHandle< IExtendedTrackSummaryTool > | m_trackSummaryTool |
|
ToolHandle< Reco::ITrackToVertex > | m_trackToVertex |
|
ToolHandle< Muon::IMuonHitSummaryTool > | m_hitSummaryTool |
|
ServiceHandle< IIBLParameterSvc > | m_IBLParameterSvc |
|
ServiceHandle< ITrackingVolumesSvc > | m_trackingVolumesSvc {this,"TrackingVolumesSvc","Trk::TrackingVolumesSvc/TrackingVolumesSvc"} |
|
SG::ReadCondHandleKey< AtlasFieldCacheCondObj > | m_fieldCacheCondObjInputKey |
|
ToolHandle< ITRT_ElectronPidTool > | m_eProbabilityTool |
| tool to calculate electron probabilities More...
|
|
ToolHandle< IPixelToTPIDTool > | m_dedxtool { this, "PixelToTPIDTool", "", "" } |
| tool to calculate dE/dx using pixel clusters More...
|
|
ToolHandle< InDet::IInDetTestPixelLayerTool > | m_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::eProbabilityType > | m_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::BeamSpotData > | m_beamSpotKey { this, "BeamSpotKey", "BeamSpotData", "SG key for beam spot" } |
|
SG::ReadHandleKey< Trk::ClusterSplitProbabilityContainer > | m_clusterSplitProbContainer { this, "ClusterSplitProbabilityName", "", "" } |
|
SG::ReadHandleKey< Trk::PRDtoTrackMap > | m_assoMapContainer { this, "AssociationMapName", ""} |
|
Definition at line 71 of file TrackParticleCreatorTool.h.
◆ TrackParticleCreatorTool()
Trk::TrackParticleCreatorTool::TrackParticleCreatorTool |
( |
const std::string & |
t, |
|
|
const std::string & |
n, |
|
|
const IInterface * |
p |
|
) |
| |
◆ ~TrackParticleCreatorTool()
virtual Trk::TrackParticleCreatorTool::~TrackParticleCreatorTool |
( |
| ) |
|
|
virtualdefault |
◆ addDetailedHitInformation()
Add extra detailed hit summary info not computed in Trk::TrkSummary.
Definition at line 993 of file TrackParticleCreatorTool.cxx.
998 for (
const TrackStateOnSurface* tsos : *trackStates) {
1001 if(mesb==
nullptr)
continue;
1007 if(rot==
nullptr)
continue;
◆ 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.
1286 uint8_t nInPixSharedEndcapHits = 0, nNInPixSharedEndcapHits = 0;
1287 uint8_t nInPixSplitEndcapHits = 0, nNInPixSplitEndcapHits = 0;
◆ addExpectedHitInformation()
Add expected hit info for innermost pixel layers not computed in Trk::TrkSummary.
Definition at line 1050 of file TrackParticleCreatorTool.cxx.
1056 uint8_t nContribPixLayers, nInPixHits, nNextInPixHits;
1058 nContribPixLayers =
zero;
1060 if(nContribPixLayers==0){
1061 ATH_MSG_DEBUG(
"No pixels on track, so wo do not expect hit in inner layers");
1073 ATH_MSG_DEBUG(
"Innermost pixel Layer hit on track, so we expect an innermost pixel layer hit");
1083 nNextInPixHits =
zero;
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");
◆ addOutlierHitInformation()
Add outlier hit info not computed in Trk::TrkSummary anymore.
Definition at line 1099 of file TrackParticleCreatorTool.cxx.
1102 uint8_t nPixOutliers = 0, nInPixOutliers = 0, nNInPixOutliers = 0, nSCTOutliers = 0;
1103 uint8_t nInEndcapPixOutliers = 0, nNInEndcapPixOutliers = 0;
1105 for (
const TrackStateOnSurface* tsos : *trackStates) {
1108 if(!isOutlier)
continue;
1111 if(mesb==
nullptr)
continue;
1129 else if (
layer == 1){
1134 nInEndcapPixOutliers++;
1137 nNInEndcapPixOutliers++;
◆ addPIDInformation()
Add Pixel and TRT PID information to the track particle.
- Parameters
-
ctx | the current event context |
track | a valid track or nullptr to set all PID values to the default value. |
tp | the trackparticle in which the PID values are set. |
Definition at line 944 of file TrackParticleCreatorTool.cxx.
949 constexpr
int initialValue{-1};
950 std::vector<float> eProbability_tmp;
951 const std::vector<float>& eProbability(
955 : eProbabilityDefault);
960 float eProbability_value = eProbability.at(
copy);
965 float fvalue = eProbability.at(decoration.second);
966 decoration.first(
tp) = fvalue;
972 decoration.first(
tp) = summary_value;
979 const int initialValue{-1};
980 float dedx = initialValue;
981 int nHitsUsed_dEdx = initialValue;
982 int nOverflowHits_dEdx = initialValue;
984 dedx =
m_dedxtool->dEdx(ctx, *
track, nHitsUsed_dEdx, nOverflowHits_dEdx);
986 tp.setNumberOfUsedHitsdEdx(nHitsUsed_dEdx);
987 tp.setNumberOfIBLOverflowsdEdx(nOverflowHits_dEdx);
◆ addSharedHitInformation()
Add shared hit info not computed in Trk::TrkSummary anymore.
Definition at line 1162 of file TrackParticleCreatorTool.cxx.
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;
1176 const EventContext& ctx = Gaudi::Hive::currentContext();
1179 for (
const auto*
const ms : *measurements) {
1194 bool hitIsSplit(
false);
1205 if (pixPrd and splitProb.
isSplit()) {
1212 else if (
layer == 1)
1216 nInPixSplitEndcapHits++;
1218 nNInPixSplitEndcapHits++;
1227 if (prd_to_track_map->isShared(*(rot->
prepRawData()))) {
1234 else if (
layer == 1)
1235 nNInPixSharedHits++;
1238 nInPixSharedEndcapHits++;
1240 nNInPixSharedEndcapHits++;
1248 if (prd_to_track_map->isShared(*(rot->
prepRawData()))) {
1255 if (prd_to_track_map->isShared(*(rot->
prepRawData()))) {
◆ CacheBeamSpotData()
◆ compare() [1/2]
◆ compare() [2/2]
Definition at line 745 of file TrackParticleCreatorTool.cxx.
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()) {
◆ createParticle() [1/5]
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
-
track | element link to a valid track (i.e. do not pass a zero!). |
TrackParticleContainer | needed to have an AuxStore, if provided particle will be added to store which takes ownership |
xAOD::Vertex | Pointer 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.
650 createParticle(ctx, **trackLink, container, vxCandidate, prtOrigin);
652 if (!trackparticle) {
653 ATH_MSG_WARNING(
"WARNING: Problem creating TrackParticle - Returning 0");
659 return trackparticle;
◆ createParticle() [2/5]
|
inlinefinaloverridevirtual |
◆ createParticle() [3/5]
◆ createParticle() [4/5]
Method to construct a xAOD::TrackParticle from a Rec::TrackParticle.
- Parameters
-
track | particle |
TrackParticleContainer | needed to have an AuxStore, if provided particle will be added to store which takes ownership |
Definition at line 593 of file TrackParticleCreatorTool.cxx.
600 std::vector<xAOD::ParameterPosition> positions;
601 bool firstMeasurement =
false;
603 if (!firstMeasurement && parameter && !parameter->associatedSurface().isFree()) {
605 firstMeasurement =
true;
607 }
else if (firstMeasurement && parameter && !parameter->associatedSurface().isFree()) {
620 &trackParticle.
info(),
628 if (!trackparticle) {
629 ATH_MSG_WARNING(
"WARNING: Problem creating TrackParticle - Returning 0");
636 compare(trackParticle, *trackparticle);
638 return trackparticle;
◆ createParticle() [5/5]
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
-
track | Pointer to a valid track (i.e. do not pass a zero!). Ownership is not taken (i.e. it will not be deleted) |
TrackParticleContainer | needed to have an AuxStore, if provided particle will be added to store which takes ownership |
xAOD::Vertex | Pointer to a valid vxCandidate (i.e. do not pass a zero!). Ownership is not taken (i.e. it will not be deleted) |
prtOrigin | Particle type |
Definition at line 259 of file TrackParticleCreatorTool.cxx.
269 aPer =
track.perigeeParameters();
282 ATH_MSG_WARNING(
"Could not extrapolate to 0,0,0. No TrackParticle created.");
290 ATH_MSG_WARNING(
"Failed to extrapolate to first Beamspot - No TrackParticle created.");
298 if (vxCandidate !=
nullptr) {
304 ATH_MSG_WARNING(
"Could not extrapolate track to vertex region! No TrackParticle created.");
308 ATH_MSG_WARNING(
"Perigee expression at Vertex, but no vertex found! No TrackParticle created.");
314 ATH_MSG_WARNING(
"Failed to extrapolate to Beamline - No TrackParticle created.");
324 std::unique_ptr<Trk::TrackSummary> updated_summary;
329 summary = updated_summary.get();
333 "No proper TrackSummaryTool found. Creating TrackParticle with a TrackSummary on track");
336 ATH_MSG_WARNING(
"Track particle created for a track without a track summary");
342 std::vector<const Trk::TrackParameters*>
parameters;
343 std::vector<xAOD::ParameterPosition> parameterPositions;
347 int nbc_meas_A1_or_B3 = 0;
348 int nbc_meas_A1_or_B3_or_C = 0;
359 for (
const TrackStateOnSurface* tsos : *trackStates) {
361 tsos->measurementOnTrack() !=
nullptr &&
363 tp = tsos->trackParameters();
368 ATH_MSG_DEBUG(
"Failed dynamic_cast to InDet::SiClusterOnTrack ");
388 ATH_MSG_DEBUG(
"Pixel cluster null though detector element matches pixel");
395 float cotthetaz = -1;
401 float PixTrkAngle = -1000;
402 float PixTrkThetaI = -1000;
410 float trketacomp = my_track.dot(my_etaax);
412 float trkphicomp = my_track.dot(my_phiax);
414 float trknormcomp = my_track.dot(my_normal);
416 PixTrkAngle = std::atan2(trkphicomp, trknormcomp);
417 PixTrkThetaI = std::atan2(trketacomp, trknormcomp);
418 float length = std::sqrt(trketacomp * trketacomp + trkphicomp * trkphicomp + trknormcomp * trknormcomp);
420 cotthetaz = 1. /
std::tan(PixTrkThetaI);
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)
431 else if (PixTrkAngle < -M_PI_2)
433 PixTrkAngle = M_PI_2 - PixTrkAngle;
442 zWidth =
static_cast<int>(
width.colRow().y());
445 int isIBLclus =
false;
462 if (isBC_A1 || isBC_B3) {
465 if ((zWidth == 1 && cotthetaz > 5.8) || (zWidth == 2 && cotthetaz > 5.8) ||
466 (zWidth == 3 && cotthetaz > 6.2) || (zWidth > 3 && cotthetaz < 2.5)) {
469 if (isBC_A1 || isBC_B3 || isBC_C) {
470 nbc_meas_A1_or_B3_or_C++;
480 for (
const TrackStateOnSurface* tsos : *trackStates) {
482 tsos->measurementOnTrack() !=
nullptr &&
484 first = tsos->trackParameters();
485 parameters.push_back(tsos->trackParameters());
494 rItTSoS != trackStates->rend();
497 (*rItTSoS)->trackParameters() !=
nullptr && (*rItTSoS)->measurementOnTrack() !=
nullptr &&
498 !((*rItTSoS)->measurementOnTrack()->type(
500 if (!(
first == (*rItTSoS)->trackParameters())) {
501 parameters.push_back((*rItTSoS)->trackParameters());
511 ATH_MSG_WARNING(
"More than two additional track parameters to be stored in TrackParticle!");
519 bool haveFirstMeasurementParameters =
false;
520 for (
const TrackStateOnSurface* tsos : *(
track.trackStateOnSurfaces())) {
521 if (!tsos->trackParameters())
527 haveFirstMeasurementParameters =
true;
528 parameters.push_back(tsos->trackParameters());
530 << tsos->trackParameters()->position().perp() <<
", Z "
531 << tsos->trackParameters()->position().z());
541 aPer =
static_cast<const Perigee*
>(tsos->trackParameters());
543 parameters.push_back(tsos->trackParameters());
546 ATH_MSG_VERBOSE(
" including perigee at R " << tsos->trackParameters()->position().perp() <<
", Z "
547 << tsos->trackParameters()->position().z());
551 haveFirstMeasurementParameters =
true;
569 nbCmeas(*trackparticle) = nbc_meas_A1;
573 nbCmeas(*trackparticle) = nbc_meas_B3;
577 nbCmeas(*trackparticle) = nbc_meas_A1_or_B3;
581 nbCmeas(*trackparticle) = nbc_meas_A1_or_B3_or_C;
588 delete parsToBeDeleted;
589 return trackparticle;
◆ getClusterSplittingProbability()
Definition at line 1298 of file TrackParticleCreatorTool.cxx.
1300 const EventContext& ctx = Gaudi::Hive::currentContext();
1305 if (!splitProbContainer.isValid()) {
1306 ATH_MSG_FATAL(
"Failed to get cluster splitting probability container "
1309 return splitProbContainer->splitProbability(
pix);
◆ initialize()
StatusCode Trk::TrackParticleCreatorTool::initialize |
( |
| ) |
|
|
overridevirtual |
Definition at line 126 of file TrackParticleCreatorTool.cxx.
133 ATH_MSG_ERROR(
"Unknown Configuration for Perigee Expression - please use one of "
135 return StatusCode::FAILURE;
142 return StatusCode::FAILURE;
151 return StatusCode::FAILURE;
156 return StatusCode::FAILURE;
161 return StatusCode::FAILURE;
166 return StatusCode::FAILURE;
172 return StatusCode::FAILURE;
179 ATH_MSG_WARNING(
"Assuming hybrid 2D/3D IBL module composition, but geometry is all-planar");
185 return StatusCode::FAILURE;
193 return StatusCode::FAILURE;
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);
215 std::vector<std::string>
errors;
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);
227 extra_summary_type_iter->second);
230 if (!eprob_iter->second.second) {
234 eprob_iter->second.first);
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;
◆ setDefiningParameters()
◆ setFitQuality()
◆ setHitPattern()
void Trk::TrackParticleCreatorTool::setHitPattern |
( |
xAOD::TrackParticle & |
tp, |
|
|
unsigned long |
hitpattern |
|
) |
| |
|
static |
◆ setNumberOfOverflowHits()
void Trk::TrackParticleCreatorTool::setNumberOfOverflowHits |
( |
xAOD::TrackParticle & |
tp, |
|
|
int |
overflows |
|
) |
| |
|
static |
◆ setNumberOfUsedHits()
◆ setParameters()
Method to set parameters of a xAOD::TrackParticle.
Definition at line 778 of file TrackParticleCreatorTool.cxx.
783 std::vector<std::vector<float>> parametersVec;
785 unsigned int numParam = 0;
790 fieldCondObj->getInitializedCache(fieldCache);
793 std::vector<float>&
values = parametersVec[numParam];
808 covarianceMatrix.setIdentity();
810 if (param->covariance()) {
813 CurvilinearUVT curvilinearUVT(
mom.unit());
816 magnFieldVect.setZero();
817 fieldCache.
getField(
pos.data(), magnFieldVect.data());
818 const Amg::Transform3D& localToGlobalTransform = param->associatedSurface().transform();
820 JacobianLocalToCurvilinear jacobian(magnFieldVect,
824 localToGlobalTransform.rotation().col(0),
825 localToGlobalTransform.rotation().col(1));
827 covarianceMatrix = param->covariance()->similarity(jacobian);
831 JacobianLocalToCurvilinear jacobian(curvilinearUVT, loc_x, loc_y);
832 covarianceMatrix = param->covariance()->similarity(jacobian);
835 std::vector<float> covMatrixVec;
837 tp.setTrackParameterCovarianceMatrix(numParam, covMatrixVec);
842 tp.setTrackParameters(parametersVec);
844 for (;
i < positions.size(); ++
i) {
845 tp.setParameterPosition(
i, positions[
i]);
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());
◆ setTilt()
void Trk::TrackParticleCreatorTool::setTilt |
( |
xAOD::TrackParticle & |
tp, |
|
|
float |
tiltx, |
|
|
float |
tilty |
|
) |
| |
|
static |
◆ setTrackInfo()
◆ setTrackSummary()
Method to set TrackSummary of a xAOD::TrackParticle.
Definition at line 882 of file TrackParticleCreatorTool.cxx.
887 static_assert(xAodReferenceEnum1 == TrkReferenceEnum1,
"Trk and xAOD enums differ in their indices");
890 static_assert(xAodReferenceEnum2 == TrkReferenceEnum2,
"Trk and xAOD enums differ in their indices");
904 if (
std::find(unusedSummaryTypes.begin(), unusedSummaryTypes.end(),
i) != unusedSummaryTypes.end()) {
◆ 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.
◆ m_assoMapContainer
◆ m_badclusterID
IntegerProperty Trk::TrackParticleCreatorTool::m_badclusterID {this, "BadClusterID", 0} |
|
private |
◆ m_beamSpotKey
◆ m_checkConversion
BooleanProperty Trk::TrackParticleCreatorTool::m_checkConversion {this, "CheckConversion", true} |
|
private |
◆ m_clusterSplitProbContainer
◆ m_computeAdditionalInfo
BooleanProperty Trk::TrackParticleCreatorTool::m_computeAdditionalInfo {this, "ComputeAdditionalInfo", false} |
|
private |
◆ m_copyEProbabilities
◆ 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
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
◆ m_dedxtool
ToolHandle<IPixelToTPIDTool> Trk::TrackParticleCreatorTool::m_dedxtool { this, "PixelToTPIDTool", "", "" } |
|
private |
◆ m_detID
◆ m_doIBL
bool Trk::TrackParticleCreatorTool::m_doIBL |
|
private |
◆ 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 |
◆ m_doSharedTRTHits
BooleanProperty Trk::TrackParticleCreatorTool::m_doSharedTRTHits {this, "DoSharedTRTHits", false} |
|
private |
◆ m_eProbabilityTool
Initial value:{ this,
"TRT_ElectronPidTool",
"",
"" }
tool to calculate electron probabilities
Definition at line 265 of file TrackParticleCreatorTool.h.
◆ m_fieldCacheCondObjInputKey
Initial value:{
this,
"AtlasFieldCacheCondObj",
"fieldCondObj",
"Name of the Magnetic Field conditions object key"
}
Definition at line 257 of file TrackParticleCreatorTool.h.
◆ m_hitSummaryTool
◆ m_IBLParameterSvc
◆ m_keepAllPerigee
BooleanProperty Trk::TrackParticleCreatorTool::m_keepAllPerigee {this, "KeepAllPerigee", false} |
|
private |
◆ m_keepFirstParameters
BooleanProperty Trk::TrackParticleCreatorTool::m_keepFirstParameters {this, "KeepFirstParameters", false} |
|
private |
◆ 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 |
◆ m_minSiHits
IntegerProperty Trk::TrackParticleCreatorTool::m_minSiHits {this, "MinSiHitsForCaloExtrap", 4} |
|
private |
◆ m_perigeeExpression
StringProperty Trk::TrackParticleCreatorTool::m_perigeeExpression {this, "PerigeeExpression", "BeamLine"} |
|
private |
◆ m_perigeeOptions
std::vector<std::string> Trk::TrackParticleCreatorTool::m_perigeeOptions |
|
private |
◆ m_pixelID
◆ m_runningTIDE_Ambi
BooleanProperty Trk::TrackParticleCreatorTool::m_runningTIDE_Ambi {this, "RunningTIDE_Ambi", false} |
|
private |
◆ m_sctID
◆ m_testPixelLayerTool
Initial value:{ this,
"TestPixelLayerTool",
"",
"" }
tool to calculate expected hit information in innermost layers
Definition at line 273 of file TrackParticleCreatorTool.h.
◆ m_trackingVolumesSvc
◆ m_trackSummaryTool
Initial value:{
this,
"TrackSummaryTool",
"Trk::TrackSummaryTool/AtlasTrackSummaryTool"
}
Definition at line 231 of file TrackParticleCreatorTool.h.
◆ m_trackToVertex
◆ m_trtID
◆ m_updateTrackSummary
BooleanProperty Trk::TrackParticleCreatorTool::m_updateTrackSummary {this, "UpdateTrackSummary", false} |
|
private |
◆ s_trtdEdxUsedHitsDecoration
◆ s_trtdEdxUsedHitsDecorationName
const std::string Trk::TrackParticleCreatorTool::s_trtdEdxUsedHitsDecorationName { "TRTdEdxUsedHits" } |
|
staticprivate |
The documentation for this class was generated from the following files:
def retrieve(aClass, aKey=None)
bool is_pixel(Identifier id) const
@ numberOfContribPixelLayers
number of contributing layers of the pixel detector
@ numberOfInnermostPixelLayerSplitHits
number of Pixel 0th layer barrel hits split by cluster splitting
@ numberOfNextToInnermostPixelLayerSplitEndcapHits
number of Pixel 1st layer endcap hits split by cluster splitting
@ Perigee
This represents a perigee, and so will contain a Perigee object only.
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,...
StringArrayProperty m_copyExtraSummaryName
Configurable to set the eProbabilities and extra track summary types which are to be copied from the ...
ToolHandle< InDet::IInDetTestPixelLayerTool > m_testPixelLayerTool
tool to calculate expected hit information in innermost layers
void addDetailedHitInformation(const Trk::TrackStates *trackStates, xAOD::TrackParticle &tp) const
Add extra detailed hit summary info not computed in Trk::TrkSummary.
void setDefiningParameters(xAOD::TrackParticle &tp, const Perigee &perigee) const
Method to set Defining parameters of a xAOD::TrackParticle.
const TrkDetElementBase * associatedDetectorElement() const
return associated Detector Element
void compress(const AmgSymMatrix(N) &covMatrix, std::vector< float > &vec)
@ eProbabilityComb
Electron probability from combining the below probabilities [float].
@ numberOfPrecisionHoleLayers
layers with holes AND no hits [unit8_t].
@ numberOfSCTSharedHits
number of SCT hits shared by several tracks [unit8_t].
SG::ReadCondHandleKey< InDet::BeamSpotData > m_beamSpotKey
std::string find(const std::string &s)
return a remapped string
Helper class to provide type-safe access to aux data.
@ numberOfContribPixelBarrelInclinedLayers
number of contributing barrel inclined layers of the pixel detector [unit8_t].
@ numberOfInnermostPixelLayerSharedEndcapHits
number of Pixel 0th layer endcap hits shared by several tracks.
BooleanProperty m_doSharedTRTHits
bool is_sct(Identifier id) const
int barrel_ec(const Identifier &id) const
Values of different levels (failure returns 0)
@ BeamLine
Parameter defined at the Vertex/Beamline.
@ numberOfCscUnspoiltEtaHits
number of unspoilt CSC eta measurements (all CSC phi measurements are by definition spoilt).
@ numberOfNextToInnermostPixelLayerSplitHits
number of Pixel 1st layer barrel hits split by cluster splitting
Dummy class used to allow special convertors to be called for surfaces owned by a detector element.
BooleanProperty m_updateTrackSummary
@ numberOfTRTXenonHits
number of TRT hits on track in straws with xenon [unit8_t].
std::pair< long int, long int > indices
const Amg::Vector3D & etaAxis() const
BooleanProperty m_computeAdditionalInfo
@ numberOfCscEtaHoles
number of CSC Eta measurements missing from the track
@ numberOfTrackSummaryTypes
const TrackSummary * trackSummary() const
accessor function for TrackSummary.
@ numberOfPhiHoleLayers
layers with trigger phi holes but no hits [unit8_t].
void setTrackLink(const ElementLink< TrackCollection > &track)
Set the link to the original track.
@ MuonSpectrometerEntryLayer
Tracking Volume which defines the entrance surfaces of the MS.
BooleanProperty m_keepFirstParameters
@ numberOfContribPixelBarrelFlatLayers
number of contributing barrel flat layers of the pixel detector [unit8_t].
std::vector< Trk::eProbabilityType > m_copyEProbabilities
Enums of an eProbability which are set in the xAOD::TrackSummary.
const AtlasDetectorID * m_detID
atlas id helper
virtual bool rioType(RIO_OnTrackType::Type type) const =0
Method checking the Rio On Track type.
static void setTilt(xAOD::TrackParticle &tp, float tiltx, float tilty)
@ expectInnermostPixelLayerHit
Do we expect a 0th-layer barrel hit for this track?
const Amg::Vector3D & position() const
Returns the 3-pos.
bool is_trt(Identifier id) const
@ numberOfMmHoles
number of TGC Eta measurements missing from the track
@ numberOfTRTTubeHits
number of TRT tube hits [unit8_t].
@ LastMeasurement
Parameter defined at the position of the last measurement.
virtual Identifier identify() const =0
Identifier.
#define ATH_MSG_VERBOSE(x)
const std::string & key() const
Return the StoreGate ID for the referenced object.
ParametersT< TrackParametersDim, Charged, PerigeeSurface > Perigee
BooleanProperty m_runningTIDE_Ambi
@ numberOfInnermostPixelLayerEndcapOutliers
number of 0th layer endcap outliers
std::vector< std::pair< SG::AuxElement::Accessor< uint8_t >, Trk::SummaryType > > m_decorateSummaryTypes
BooleanProperty m_checkConversion
@ eProbabilityNumberOfTRTHitsUsedFordEdx
Number of TRT hits used for dEdx measurement.
ServiceHandle< ITrackingVolumesSvc > m_trackingVolumesSvc
@ Outlier
This TSoS contains an outlier, that is, it contains a MeasurementBase/RIO_OnTrack which was not used ...
float nSCTSharedHits(const U &p)
TrackParticle_v1 TrackParticle
Reference the current persistent version:
AmgSymMatrix(5) &GXFTrackState
void setTrackInfo(xAOD::TrackParticle &tp, const TrackInfo &trackInfo, xAOD::ParticleHypothesis prtOrigin) const
Method to set TrackInfo of a xAOD::TrackParticle.
@ numberOfTRTSharedHits
number of TRT hits used by more than one track
static void addDummyEndcapSharedHitInformation(xAOD::TrackParticle &tp)
Add dummy endcap shared hit info as AuxDyn variable in case nominal shared hit info not computed (for...
@ numberOfContribPixelEndcap
number of contributing endcap layers of the pixel detector [unit8_t].
SG::ReadHandleKey< Trk::PRDtoTrackMap > m_assoMapContainer
@ numberOfInnermostPixelLayerOutliers
number of 0th layer barrel outliers
@ numberOfNextToInnermostPixelLayerSharedEndcapHits
number of Pixel 1st layer endcap hits shared by several tracks.
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...
const Trk::Perigee & perigeeParameters() const
Returns the Trk::MeasuredPerigee track parameters.
@ numberOfInnermostPixelLayerEndcapHits
these are the hits in the 0th pixel layer endcap [unit8_t].
@ numberOfPixelSharedHits
number of Pixel all-layer hits shared by several tracks [unit8_t].
ToolHandle< Reco::ITrackToVertex > m_trackToVertex
int getHits(Trk::DetectorRegion region, int layer)
SummaryType
Enumerates the different types of information stored in Summary.
PublicToolHandle< IExtendedTrackSummaryTool > m_trackSummaryTool
void addExpectedHitInformation(const Perigee *perigee, xAOD::TrackParticle &tp) const
Add expected hit info for innermost pixel layers not computed in Trk::TrkSummary.
std::string toString(const Translation3D &translation, int precision=4)
GeoPrimitvesToStringConverter.
@ numberOfTRTTubeHits
number of TRT hits on track in straws with xenon
@ expectNextToInnermostPixelLayerHit
Do we expect a 1st-layer barrel hit for this track?
int getPixelContributions()
@ numberOfTriggerEtaLayers
layers with trigger eta hits [unit8_t].
@ numberOfPixelBarrelFlatHits
these are the pixel hits, in the barrel flat layers [unit8_t].
@ numberOfTriggerEtaHoleLayers
layers with trigger eta holes but no hits [unit8_t].
virtual const InDet::BeamSpotData * CacheBeamSpotData(const EventContext &ctx) const override final
BooleanProperty m_doSharedSiHits
const ElementLink< TrackCollection > * trackElementLink() const
Return the ElementLink to the Track.
@ FirstMeasurement
Parameter defined at the position of the 1st measurement.
const PixelID * m_pixelID
::StatusCode StatusCode
StatusCode definition for legacy code.
void setTrackSummary(xAOD::TrackParticle &tp, const TrackSummary &summary) const
Method to set TrackSummary of a xAOD::TrackParticle.
Eigen::Affine3d Transform3D
const FitQuality * fitQuality() const
accessor function for FitQuality.
void setFitQuality(xAOD::TrackParticle &tp, const FitQuality &fq) const
Method to set FitQuality of a xAOD::TrackParticle.
StringProperty m_perigeeExpression
virtual DetectorType type() const
Type of element.
@ numberOfPixelOutliers
these are the pixel outliers, including the b-layer [unit8_t].
virtual bool type(MeasurementBaseType::Type type) const =0
Interface method checking the type.
StatusCode initialize(bool used=true)
If this object is used as a property, then this should be called during the initialize phase.
@ numberOfPixelSplitHits
number of Pixel all-layer hits split by cluster splitting [unit8_t].
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...
@ numberOfInnermostPixelLayerSplitEndcapHits
number of Pixel 0th layer endcap hits shared by several tracks.
SG::ReadCondHandleKey< AtlasFieldCacheCondObj > m_fieldCacheCondObjInputKey
virtual const Amg::Vector3D & normal() const override final
Get reconstruction local normal axes in global frame.
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...
bool solenoidOn() const
status of the magnets
@ numberOfStgcEtaHits
number of TGC Eta measurements missing from the track
@ numberOfNextToInnermostPixelLayerEndcapHits
these are the hits in the 0.5th and 1st pixel layer endcap rings [unit8_t].
@ CalorimeterEntryLayer
Tracking Volume which defines the entrance srufaces of the calorimeter.
@ numberOfTgcPhiHoles
number of TGC Phi measurements missing from the track
int layer_disk(const Identifier &id) const
int eta_module(const Identifier &id) const
@ numberOfNextToInnermostPixelLayerOutliers
number of 1st pixel layer barrel outliers
@ numberOfNextToInnermostPixelLayerHits
these are the hits in the 1st pixel barrel layer
A summary of the information contained by a track.
virtual const Surface & associatedSurface() const =0
Interface method to get the associated Surface.
std::reverse_iterator< const_iterator > const_reverse_iterator
Standard const_reverse_iterator.
ToolHandle< Muon::IMuonHitSummaryTool > m_hitSummaryTool
const std::vector< const TrackParameters * > & trackParameters() const
Returns the track parameters.
double charge(const T &p)
value_type push_back(value_type pElem)
Add an element to the end of the collection.
StatusCode initialize(bool used=true)
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...
void makePrivateStore()
Create a new (empty) private store for this object.
size_t numberOfParameters() const
Returns the number of additional parameters stored in the TrackParticle.
Eigen::Matrix< double, 3, 1 > Vector3D
virtual const Trk::PrepRawData * prepRawData() const =0
returns the PrepRawData (also known as RIO) object to which this RIO_OnTrack is associated.
void addPIDInformation(const EventContext &ctx, const Track *track, xAOD::TrackParticle &tp) const
Add Pixel and TRT PID information to the track particle.
const Trk::Perigee * measuredPerigee() const
Accessor method for Perigee.
@ numberOfPixelBarrelInclinedHits
these are the pixel hits, in the barrel inclined layers [unit8_t].
int getContributionFromRegion(Trk::DetectorRegion region)
BooleanProperty m_keepParameters
the following keep options are mutually exclusive
void setParameters(const EventContext &ctx, xAOD::TrackParticle &tp, const std::vector< const Trk::TrackParameters * > ¶meters, const std::vector< xAOD::ParameterPosition > &positions) const
Method to set parameters of a xAOD::TrackParticle.
@ numberOfSCTOutliers
number of SCT outliers [unit8_t].
#define ATH_MSG_WARNING(x)
const Amg::Vector3D & phiAxis() const
@ numberOfNextToInnermostPixelLayerEndcapOutliers
number of 1st layer endcap disk outliers
Identifier identify() const
return the identifier -extends MeasurementBase
Local cache for magnetic field (based on MagFieldServices/AtlasFieldSvcTLS.h)
std::vector< std::string > m_perigeeOptions
void compare(const Rec::TrackParticle &tp, const xAOD::TrackParticle &tpx) const
@ numberOfInnermostPixelLayerSharedHits
number of Pixel 0th layer barrel hits shared by several tracks.
void addSharedHitInformation(const Track *track, xAOD::TrackParticle &tp) const
Add shared hit info not computed in Trk::TrkSummary anymore.
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,...
@ numberOfContribPixelLayers
number of contributing layers of the pixel detector [unit8_t].
BooleanProperty m_keepAllPerigee
keep all MeasuredPerigee parameters (e.g.
@ PseudoMeasurementOnTrack
BooleanProperty m_doITk
if the track contains a summary, the shared, expected hit, and PID information will be recomputed.
int getHitsFromRegion(Trk::DetectorRegion region)
@ numberOfPixelEndcapHits
these are the pixel hits, in the endcap layers [unit8_t].
static const std::string s_trtdEdxUsedHitsDecorationName
Name used for the decoration of the track particle with TRT dE/dx .
IntegerProperty m_badclusterID
ToolHandle< ITRT_ElectronPidTool > m_eProbabilityTool
tool to calculate electron probabilities
SummaryType
enumerates the different types of information stored in Summary.
Class describing a TrackParticle.
ToolHandle< IPixelToTPIDTool > m_dedxtool
tool to calculate dE/dx using pixel clusters
void addOutlierHitInformation(const Trk::TrackStates *trackStates, xAOD::TrackParticle &tp) const
Add outlier hit info not computed in Trk::TrkSummary anymore.
@ numberOfeProbabilityTypes
virtual const SiDetectorDesign & design() const override final
access to the local description (inline):
@ numberOfNextToInnermostPixelLayerSharedHits
number of Pixel 1st layer barrel hits shared by several tracks.
SG::ReadHandleKey< Trk::ClusterSplitProbabilityContainer > m_clusterSplitProbContainer
@ numberOfPhiLayers
layers with a trigger phi hit [unit8_t].
@ MuonSpectrometerExitLayer
Tracking Volume which defines the outer surfaces of the MS.
static const ProbabilityInfo & getNoSplitProbability()
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.
void zero(TH2 *h)
zero the contents of a 2d histogram
const Trk::ClusterSplitProbabilityContainer::ProbabilityInfo & getClusterSplittingProbability(const InDet::PixelCluster *pix) const
@ Measurement
This is a measurement, and will at least contain a Trk::MeasurementBase.
ParticleHypothesis particleHypothesis() const
Returns the particle hypothesis used for Track fitting.
@ numberOfMdtHits
number of mdt hits
@ numberOfInnermostPixelLayerHits
these are the hits in the 0th pixel barrel layer
const TrackInfo & info() const
returns the info of the track.
static void setHitPattern(xAOD::TrackParticle &tp, unsigned long hitpattern)
@ numberOfPrecisionLayers
layers with at least 3 hits [unit8_t].
@ Unknown
Track fitter not defined.
ServiceHandle< IIBLParameterSvc > m_IBLParameterSvc