ATLAS Offline Software
Public Member Functions | Static Public Member Functions | Protected Member Functions | Private Types | Private Member Functions | Private Attributes | List of all members
DerivationFramework::TrackStateOnSurfaceDecorator Class Reference

#include <TrackStateOnSurfaceDecorator.h>

Inheritance diagram for DerivationFramework::TrackStateOnSurfaceDecorator:
Collaboration diagram for DerivationFramework::TrackStateOnSurfaceDecorator:

Public Member Functions

 TrackStateOnSurfaceDecorator (const std::string &t, const std::string &n, const IInterface *p)
 
StatusCode initialize ()
 
StatusCode finalize ()
 
virtual StatusCode addBranches () const
 Pass the thinning service
More...
 
ServiceHandle< StoreGateSvc > & evtStore ()
 The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc. More...
 
const ServiceHandle< StoreGateSvc > & evtStore () const
 The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc. More...
 
const ServiceHandle< StoreGateSvc > & detStore () const
 The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc. More...
 
virtual StatusCode sysInitialize () override
 Perform system initialization for an algorithm. More...
 
virtual StatusCode sysStart () override
 Handle START transition. More...
 
virtual std::vector< Gaudi::DataHandle * > inputHandles () const override
 Return this algorithm's input handles. More...
 
virtual std::vector< Gaudi::DataHandle * > outputHandles () const override
 Return this algorithm's output handles. More...
 
Gaudi::Details::PropertyBase & declareProperty (Gaudi::Property< T > &t)
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleKey &hndl, const std::string &doc, const SG::VarHandleKeyType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleBase &hndl, const std::string &doc, const SG::VarHandleType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleKeyArray &hndArr, const std::string &doc, const SG::VarHandleKeyArrayType &)
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, T &property, const std::string &doc, const SG::NotHandleType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, T &property, const std::string &doc="none")
 Declare a new Gaudi property. More...
 
void updateVHKA (Gaudi::Details::PropertyBase &)
 
MsgStream & msg () const
 
MsgStream & msg (const MSG::Level lvl) const
 
bool msgLvl (const MSG::Level lvl) const
 

Static Public Member Functions

static const InterfaceID & interfaceID ()
 AlgTool interface methods. More...
 

Protected Member Functions

void renounceArray (SG::VarHandleKeyArray &handlesArray)
 remove all handles from I/O resolution More...
 
std::enable_if_t< std::is_void_v< std::result_of_t< decltype(&T::renounce)(T)> > &&!std::is_base_of_v< SG::VarHandleKeyArray, T > &&std::is_base_of_v< Gaudi::DataHandle, T >, void > renounce (T &h)
 
void extraDeps_update_handler (Gaudi::Details::PropertyBase &ExtraDeps)
 Add StoreName to extra input/output deps as needed. More...
 

Private Types

enum  ETRTFloatDecor {
  kTRTdEdxDecor, kTRTusedHitsDecor, kTRTdEdx_noHT_divByLDecor, kTRTusedHits_noHT_divByLDecor,
  kNTRTFloatDecor
}
 
enum  EPixFloatDecorKeys {
  kTrkIBLXDecor, kTrkIBLYDecor, kTrkIBLZDecor, kTrkBLXDecor,
  kTrkBLYDecor, kTrkBLZDecor, kTrkL1XDecor, kTrkL1YDecor,
  kTrkL1ZDecor, kTrkL2XDecor, kTrkL2YDecor, kTrkL2ZDecor,
  kNPixFloatDecor
}
 
typedef ServiceHandle< StoreGateSvcStoreGateSvc_t
 

Private Member Functions

ElementLink< xAOD::TrackMeasurementValidationContainerbuildElementLink (const Trk::PrepRawData *, const std::vector< unsigned int > *, const xAOD::TrackMeasurementValidationContainer *) const
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
 specialization for handling Gaudi::Property<SG::VarHandleKey> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleKeyArrayType &)
 specialization for handling Gaudi::Property<SG::VarHandleKeyArray> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleType &)
 specialization for handling Gaudi::Property<SG::VarHandleBase> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &t, const SG::NotHandleType &)
 specialization for handling everything that's not a Gaudi::Property<SG::VarHandleKey> or a <SG::VarHandleKeyArray> More...
 

Private Attributes

bool m_isSimulation
 
bool m_storeHoles
 
bool m_storeOutliers
 
bool m_storeTRT
 
bool m_storeSCT
 
bool m_storePixel
 
bool m_addPulls
 
bool m_addSurfaceInfo
 
bool m_addPRD
 
bool m_addExtraEventInfo
 
SG::ReadHandleKey< xAOD::EventInfom_eventInfoKey { this, "EventInfoKey", "EventInfo", "" }
 
Gaudi::Property< std::string > m_sgName { this, "DecorationPrefix", "IDDET1_",""}
 
SG::ReadHandleKey< xAOD::TrackParticleContainerm_containerName { this, "ContainerName", "InDetTrackParticles", "" }
 
SG::ReadHandleKey< ComTimem_trtPhaseKey { this,"TRTPhaseKey","TRT_Phase", ""}
 
SG::ReadHandleKey< std::vector< unsigned int > > m_pixelMapName { this, "PixelMapName", "PixelClustersOffsets" , ""}
 
SG::ReadHandleKey< std::vector< unsigned int > > m_sctMapName { this, "SctMapName", "SCT_ClustersOffsets" , ""}
 
SG::ReadHandleKey< std::vector< unsigned int > > m_trtMapName { this, "TrtMapName", "TRT_DriftCirclesOffsets" , ""}
 
SG::ReadHandleKey< xAOD::TrackMeasurementValidationContainerm_pixelClustersName {this, "PixelClustersName", "PixelClusters" ,"" }
 
SG::ReadHandleKey< xAOD::TrackMeasurementValidationContainerm_sctClustersName {this, "SctClustersName", "SCT_Clusters" ,"" }
 
SG::ReadHandleKey< xAOD::TrackMeasurementValidationContainerm_trtDCName {this, "TrtDriftCirclesName", "TRT_DriftCircles" ,"" }
 
SG::ReadHandleKey< Trk::PRDtoTrackMapm_prdToTrackMap { this,"PRDtoTrackMap","","option PRD-to-track association"}
 
SG::WriteHandleKey< xAOD::TrackStateValidationContainerm_pixelMsosName { this, "PixelMsosName", "PixelMSOSs", "" }
 
SG::WriteHandleKey< xAOD::TrackStateValidationContainerm_sctMsosName { this, "SctMsosName", "SCT_MSOSs", "" }
 
SG::WriteHandleKey< xAOD::TrackStateValidationContainerm_trtMsosName { this, "TrtMsosName", "TRT_MSOSs", ""}
 
SG::ReadCondHandleKey< InDetDD::SiDetectorElementCollectionm_SCTDetEleCollKey {this, "SCTDetEleCollKey", "SCT_DetectorElementCollection", "Key of SiDetectorElementCollection for SCT"}
 
const AtlasDetectorIDm_idHelper
 
const PixelIDm_pixId
 
const SCT_IDm_sctId
 
const TRT_IDm_trtId
 
ToolHandle< Trk::IUpdatorm_updator
 
ToolHandle< Trk::IResidualPullCalculatorm_residualPullCalculator
 
ToolHandle< Trk::ITrackHoleSearchToolm_holeSearchTool
 
ToolHandle< Trk::IExtrapolatorm_extrapolator
 
ToolHandle< ITRT_CalDbToolm_trtcaldbTool
 
ToolHandle< ITRT_ToT_dEdxm_TRTdEdxTool
 
std::vector< SG::WriteDecorHandleKey< xAOD::EventInfo > > m_trtPhaseDecorKey
 
std::vector< SG::WriteDecorHandleKey< xAOD::TrackParticleContainer > > m_trackTRTFloatDecorKeys
 
std::vector< SG::WriteDecorHandleKey< xAOD::TrackParticleContainer > > m_trackPixFloatDecorKeys
 
SG::WriteDecorHandleKey< xAOD::TrackParticleContainerm_trackTSOSMOSLinkDecorKey
 
Gaudi::Property< std::vector< float > > m_pixelLayerRadii {this, "PixelLayerRadii", {29.5,50.5,88.5,122.5}, "Radii to extrapolate to for estimating track position on layers" }
 
StoreGateSvc_t m_evtStore
 Pointer to StoreGate (event store by default) More...
 
StoreGateSvc_t m_detStore
 Pointer to StoreGate (detector store by default) More...
 
std::vector< SG::VarHandleKeyArray * > m_vhka
 
bool m_varHandleArraysDeclared
 

Detailed Description

Definition at line 51 of file TrackStateOnSurfaceDecorator.h.

Member Typedef Documentation

◆ StoreGateSvc_t

typedef ServiceHandle<StoreGateSvc> AthCommonDataStore< AthCommonMsg< AlgTool > >::StoreGateSvc_t
privateinherited

Definition at line 388 of file AthCommonDataStore.h.

Member Enumeration Documentation

◆ EPixFloatDecorKeys

Enumerator
kTrkIBLXDecor 
kTrkIBLYDecor 
kTrkIBLZDecor 
kTrkBLXDecor 
kTrkBLYDecor 
kTrkBLZDecor 
kTrkL1XDecor 
kTrkL1YDecor 
kTrkL1ZDecor 
kTrkL2XDecor 
kTrkL2YDecor 
kTrkL2ZDecor 
kNPixFloatDecor 

Definition at line 139 of file TrackStateOnSurfaceDecorator.h.

◆ ETRTFloatDecor

Enumerator
kTRTdEdxDecor 
kTRTusedHitsDecor 
kTRTdEdx_noHT_divByLDecor 
kTRTusedHits_noHT_divByLDecor 
kNTRTFloatDecor 

Definition at line 133 of file TrackStateOnSurfaceDecorator.h.

Constructor & Destructor Documentation

◆ TrackStateOnSurfaceDecorator()

DerivationFramework::TrackStateOnSurfaceDecorator::TrackStateOnSurfaceDecorator ( const std::string &  t,
const std::string &  n,
const IInterface *  p 
)

Definition at line 64 of file TrackStateOnSurfaceDecorator.cxx.

66  :
67  AthAlgTool(t,n,p),
68  m_idHelper(nullptr),
69  m_pixId(nullptr),
70  m_sctId(nullptr),
71  m_trtId(nullptr),
72  m_updator("Trk::KalmanUpdator"),
73  m_residualPullCalculator("Trk::ResidualPullCalculator/ResidualPullCalculator"),
74  m_holeSearchTool("InDet::InDetTrackHoleSearchTool/InDetHoleSearchTool"),
75  m_extrapolator("Trk::Extrapolator/AtlasExtrapolator"),
76  m_trtcaldbTool("TRT_CalDbTool",this),
77  m_TRTdEdxTool("InDet::TRT_ElectronPidTools/TRT_ToT_dEdx")
78  {
79  declareInterface<DerivationFramework::IAugmentationTool>(this);
80  // --- Steering and configuration flags
81  declareProperty("IsSimulation", m_isSimulation=true);
82 
83  declareProperty("StoreHoles", m_storeHoles =true);
84  declareProperty("StoreOutliers", m_storeOutliers = true);
85  declareProperty("StoreTRT", m_storeTRT =false);
86  declareProperty("StoreSCT", m_storeSCT = true);
87  declareProperty("StorePixel", m_storePixel =true);
88  declareProperty("AddPulls", m_addPulls =true);
89  declareProperty("AddSurfaceInfo", m_addSurfaceInfo =true);
90  declareProperty("AddPRD", m_addPRD =true);
91  declareProperty("AddExtraEventInfo", m_addExtraEventInfo=true);
92 
93  // -- Tools
94  declareProperty("Updator", m_updator);
95  declareProperty("ResidualPullCalculator", m_residualPullCalculator);
96  declareProperty("HoleSearch", m_holeSearchTool);
97  declareProperty("TRT_CalDbTool", m_trtcaldbTool);
98  declareProperty("TRT_ToT_dEdx", m_TRTdEdxTool);
99  declareProperty("TrackExtrapolator", m_extrapolator);
100  }

Member Function Documentation

◆ addBranches()

StatusCode DerivationFramework::TrackStateOnSurfaceDecorator::addBranches ( ) const
virtual

Pass the thinning service

Implements DerivationFramework::IAugmentationTool.

Definition at line 216 of file TrackStateOnSurfaceDecorator.cxx.

217  {
218  const EventContext& ctx = Gaudi::Hive::currentContext();
219  ATH_MSG_DEBUG("Adding TSOS decorations the track particles");
220 
222 
223  // --- Retrieve track container (absolutely needed for decoration)
225  if( ! tracks.isValid() ) {
226  ATH_MSG_ERROR ("Couldn't retrieve TrackParticles with key: " << m_containerName.key() );
227  return StatusCode::FAILURE;
228  }
229 
230 
231  SG::ReadHandle<std::vector<unsigned int> > pixelClusterOffsets;
232  SG::ReadHandle<std::vector<unsigned int> > sctClusterOffsets;
234 
238 
239 
240  // Create the xAOD container and its auxiliary store
244 
245  int nPixelMSOS(0);
246  int nSCT_MSOS(0);
247  int nTRT_MSOS(0);
248 
249  // --- Add event-level information
250  if (m_addExtraEventInfo) {
251  ATH_MSG_DEBUG("Adding EventInfo decorations");
253  if (!eventInfo.isValid()) {
254  ATH_MSG_ERROR(" Cannot access to event info.");
255  return StatusCode::FAILURE;
256  }
257 
258  //Add TRT event phase
259  SG::ReadHandle<ComTime> trtPhase(m_trtPhaseKey, ctx);
260  float trtPhase_time=0.;
261  if (!trtPhase.isValid()) {
262  ATH_MSG_DEBUG("Failed to retrieve TRT phase information.");
263  } else {
264  trtPhase_time = trtPhase->getTime();
265  } //TRT phase
267  decorTRTPhase(*eventInfo) = trtPhase_time;
268  } //extra event info
269 
270  // --- Add track states containers
271  if(m_addPRD){
272  // Get clusters and the mapping between xAOD::PRD and Trk::PRD
273  // Store the MSOS's in a conatiner based on the type of the detector
274  if(m_storePixel){
275  ATH_MSG_DEBUG("Creating Pixel track state container");
276  pixelClusterOffsets=SG::ReadHandle<std::vector<unsigned int> >(m_pixelMapName,ctx);
278 
280  if (msosPixel.record(std::make_unique<xAOD::TrackStateValidationContainer>(),
281  std::make_unique<xAOD::TrackStateValidationAuxContainer>()).isFailure()) {
282  ATH_MSG_ERROR("Failed to record " << m_pixelMsosName.key() );
283  return StatusCode::FAILURE;
284  }
285  }
286  if(m_storeSCT){
287  ATH_MSG_DEBUG("Creating SCT track state container");
290 
292  if (msosSCT.record(std::make_unique<xAOD::TrackStateValidationContainer>(),
293  std::make_unique<xAOD::TrackStateValidationAuxContainer>()).isFailure()) {
294  ATH_MSG_ERROR("Failed to record " << m_sctMsosName.key() );
295  return StatusCode::FAILURE;
296  }
297  }
298  if(m_storeTRT){
299  ATH_MSG_DEBUG("Creating TRT track state container");
302 
304  if (msosTRT.record(std::make_unique<xAOD::TrackStateValidationContainer>(),
305  std::make_unique<xAOD::TrackStateValidationAuxContainer>()).isFailure()) {
306  ATH_MSG_ERROR("Failed to record " << m_trtMsosName.key() );
307  return StatusCode::FAILURE;
308  }
309  }
310  }
311 
312  SG::ReadHandle<Trk::PRDtoTrackMap> prd_to_track_map;
313  const Trk::PRDtoTrackMap *prd_to_track_map_cptr = nullptr;
314  if (!m_prdToTrackMap.key().empty()) {
316  if (!prd_to_track_map.isValid()) {
317  ATH_MSG_ERROR("Failed to read PRD to track association map: " << m_prdToTrackMap.key());
318  }
319  prd_to_track_map_cptr = prd_to_track_map.cptr();
320  }
321 
322  std::vector<SG::WriteDecorHandle<xAOD::TrackParticleContainer,float> > trackTRTFloatDecorators;
323  if (m_storeTRT && m_TRTdEdxTool.isEnabled()) {
324  trackTRTFloatDecorators = createDecorators<xAOD::TrackParticleContainer,float>(m_trackTRTFloatDecorKeys,ctx);
325  }
326  std::vector<SG::WriteDecorHandle<xAOD::TrackParticleContainer,float> >
327  trackPixFloatDecorators = createDecorators<xAOD::TrackParticleContainer,float>(m_trackPixFloatDecorKeys,ctx);
328  // -- Run over each track and decorate it
329  for (const auto *const track : *tracks) {
330  //-- Start with things that do not need a Trk::Track object
331 
332  // -- Now things that require a Trk::Track object
333  if( !track->trackLink().isValid() || track->track() == nullptr ) {
334  ATH_MSG_WARNING("Track particle without Trk::Track");
335  continue;
336  }
337  ATH_MSG_DEBUG("We have a Trk::Track");
338 
339  // We now have a valid Trk::Track
340  const Trk::Track* trkTrack = track->track();
341 
342  // This is the vector in which we will store the element links to the MSOS's
343  std::vector< ElementLink< xAOD::TrackStateValidationContainer > > msosLink;
344 
345  if ( m_storeTRT && m_TRTdEdxTool.isEnabled() ) {
346  // for dEdx studies
347  trackTRTFloatDecorators[kTRTdEdxDecor] (*track) = m_TRTdEdxTool->dEdx(trkTrack,true);
348  trackTRTFloatDecorators[kTRTusedHitsDecor] (*track) = m_TRTdEdxTool->usedHits(trkTrack);
349  trackTRTFloatDecorators[kTRTdEdx_noHT_divByLDecor] (*track) = m_TRTdEdxTool->dEdx(trkTrack, false);
350  trackTRTFloatDecorators[kTRTusedHits_noHT_divByLDecor] (*track) = m_TRTdEdxTool->usedHits(trkTrack, false);
351  }
352 
353  if(m_storePixel){
354  if ( trkTrack->perigeeParameters() ){
355 
356  if(m_pixelLayerRadii.size() < 4) ATH_MSG_WARNING("Too few layer radii set! Should be at least 4!");
357 
358  Trk::CylinderSurface cylSurfIBL(m_pixelLayerRadii[0], 3000.0);
359  Trk::CylinderSurface cylSurfBL(m_pixelLayerRadii[1], 3000.0);
360  Trk::CylinderSurface cylSurfL1(m_pixelLayerRadii[2], 3000.0);
361  Trk::CylinderSurface cylSurfL2(m_pixelLayerRadii[3], 3000.0);
362 
363  bool allExtrapolationsSucceded = true;
366  //check the radius of the start parameters, to see which direction we need to go to the target surface
367  float startRadius = trkTrack->perigeeParameters()->associatedSurface().center().perp();
368  ATH_MSG_VERBOSE("Start radius for extrapolating to layers: "<<startRadius);
369  //see if we go along or opposite momentum
370  if(startRadius>m_pixelLayerRadii[0]) {whichDir = Trk::oppositeMomentum; whichMode = Trk::addNoise;}
371  std::unique_ptr<const Trk::TrackParameters> outputParamsIBL
372  (m_extrapolator->extrapolate(ctx,
373  *(trkTrack->perigeeParameters()),
374  cylSurfIBL,
375  whichDir,
376  true,
377  Trk::pion,
378  whichMode));
379  if(startRadius>m_pixelLayerRadii[1]){
380  whichDir = Trk::oppositeMomentum;
381  whichMode = Trk::addNoise;
382  }
383  std::unique_ptr<const Trk::TrackParameters> outputParamsBL
384  (m_extrapolator->extrapolate(ctx,
385  *(trkTrack->perigeeParameters()),
386  cylSurfBL,
387  whichDir,
388  true,
389  Trk::pion,
390  whichMode));
391  if(startRadius>m_pixelLayerRadii[2]){
392  whichDir = Trk::oppositeMomentum;
393  whichMode = Trk::addNoise;
394  }
395  std::unique_ptr<const Trk::TrackParameters> outputParamsL1
396  (m_extrapolator->extrapolate(ctx,
397  *(trkTrack->perigeeParameters()),
398  cylSurfL1,
399  whichDir,
400  true,
401  Trk::pion,
402  whichMode));
403  if(startRadius>m_pixelLayerRadii[2]){
404  whichDir = Trk::oppositeMomentum;
405  whichMode = Trk::addNoise;
406  }
407  std::unique_ptr<const Trk::TrackParameters> outputParamsL2
408  (m_extrapolator->extrapolate(ctx,
409  *(trkTrack->perigeeParameters()),
410  cylSurfL2,
411  whichDir,
412  true,
413  Trk::pion,
414  whichMode));
415 
416  if (outputParamsIBL.get()) {
417  trackPixFloatDecorators[kTrkIBLXDecor](*track) = outputParamsIBL->position().x();
418  trackPixFloatDecorators[kTrkIBLYDecor](*track) = outputParamsIBL->position().y();
419  trackPixFloatDecorators[kTrkIBLZDecor](*track) = outputParamsIBL->position().z();
420  }
421  else {
422  allExtrapolationsSucceded = false;
423  ATH_MSG_VERBOSE("Extrapolation to IBL failed...");
424  trackPixFloatDecorators[kTrkIBLXDecor](*track) = 0.0;
425  trackPixFloatDecorators[kTrkIBLYDecor](*track) = 0.0;
426  trackPixFloatDecorators[kTrkIBLZDecor](*track) = 0.0;
427  }
428 
429  if (outputParamsBL.get()) {
430  trackPixFloatDecorators[kTrkBLXDecor](*track) = outputParamsBL->position().x();
431  trackPixFloatDecorators[kTrkBLYDecor](*track) = outputParamsBL->position().y();
432  trackPixFloatDecorators[kTrkBLZDecor](*track) = outputParamsBL->position().z();
433  }
434  else {
435  allExtrapolationsSucceded = false;
436  ATH_MSG_VERBOSE("Extrapolation to BLayer failed...");
437  trackPixFloatDecorators[kTrkBLXDecor](*track) = 0.0;
438  trackPixFloatDecorators[kTrkBLYDecor](*track) = 0.0;
439  trackPixFloatDecorators[kTrkBLZDecor](*track) = 0.0;
440  }
441 
442  if (outputParamsL1.get()) {
443  trackPixFloatDecorators[kTrkL1XDecor](*track) = outputParamsL1->position().x();
444  trackPixFloatDecorators[kTrkL1YDecor](*track) = outputParamsL1->position().y();
445  trackPixFloatDecorators[kTrkL1ZDecor](*track) = outputParamsL1->position().z();
446  }
447  else {
448  allExtrapolationsSucceded = false;
449  ATH_MSG_VERBOSE("Extrapolation to L1 failed...");
450  trackPixFloatDecorators[kTrkL1XDecor](*track) = 0.0;
451  trackPixFloatDecorators[kTrkL1YDecor](*track) = 0.0;
452  trackPixFloatDecorators[kTrkL1ZDecor](*track) = 0.0;
453  }
454 
455  if (outputParamsL2.get()) {
456  trackPixFloatDecorators[kTrkL2XDecor](*track) = outputParamsL2->position().x();
457  trackPixFloatDecorators[kTrkL2YDecor](*track) = outputParamsL2->position().y();
458  trackPixFloatDecorators[kTrkL2ZDecor](*track) = outputParamsL2->position().z();
459  }
460  else {
461  allExtrapolationsSucceded = false;
462  ATH_MSG_VERBOSE("Extrapolation to L2 failed...");
463  trackPixFloatDecorators[kTrkL2XDecor](*track) = 0.0;
464  trackPixFloatDecorators[kTrkL2YDecor](*track) = 0.0;
465  trackPixFloatDecorators[kTrkL2ZDecor](*track) = 0.0;
466  }
467  if(!allExtrapolationsSucceded) ATH_MSG_WARNING("At least one extrapolation to a Pixel layer failed!");
468  }
469  else{
470  ATH_MSG_WARNING("No perigee TrackParameters found - filling positions on layers to (0,0,0)!");
471  //should decorate nonetheless, to make sure decorations are consistent across events
472  trackPixFloatDecorators[kTrkIBLXDecor](*track) = 0.0;
473  trackPixFloatDecorators[kTrkIBLYDecor](*track) = 0.0;
474  trackPixFloatDecorators[kTrkIBLZDecor](*track) = 0.0;
475  trackPixFloatDecorators[kTrkBLXDecor](*track) = 0.0;
476  trackPixFloatDecorators[kTrkBLYDecor](*track) = 0.0;
477  trackPixFloatDecorators[kTrkBLZDecor](*track) = 0.0;
478  trackPixFloatDecorators[kTrkL1XDecor](*track) = 0.0;
479  trackPixFloatDecorators[kTrkL1YDecor](*track) = 0.0;
480  trackPixFloatDecorators[kTrkL1ZDecor](*track) = 0.0;
481  trackPixFloatDecorators[kTrkL2XDecor](*track) = 0.0;
482  trackPixFloatDecorators[kTrkL2YDecor](*track) = 0.0;
483  trackPixFloatDecorators[kTrkL2ZDecor](*track) = 0.0;
484  }
485  }
486 
487  // -- Add Track states to the current track, filtering on their type
488  std::vector<const Trk::TrackStateOnSurface*> tsoss;
489  for (const auto *const trackState: *(trkTrack->trackStateOnSurfaces())){
490  //Get rid of any holes that already exist -- we are doing the search again
491  if( trackState->types()[Trk::TrackStateOnSurface::Hole] )
492  continue;
493  tsoss.push_back(trackState);
494  }
495 
496  std::unique_ptr<const Trk::TrackStates> holes;
497  if(m_storeHoles){
498  holes = std::unique_ptr<const Trk::TrackStates>( m_holeSearchTool->getHolesOnTrack(*trkTrack, trkTrack->info().particleHypothesis()) );
499  for (const auto *hole: *holes){
500  tsoss.push_back(hole);
501  }
502  if(trkTrack->perigeeParameters()){
503  Trk::TrackStateOnSurfaceComparisonFunction CompFunc( trkTrack->perigeeParameters()->momentum() );
504  stable_sort( tsoss.begin(), tsoss.end(), CompFunc );
505  } else {
506  ATH_MSG_ERROR("Track has no perigee parameters");
507  }
508  }
509 
510  //Loop over the TrkStateOnSurfaces
511  for (const auto& trackState: tsoss){
512 
513  //Only store Holes, Measurement & Outliers
514  if( !trackState->types()[Trk::TrackStateOnSurface::Hole] &&
515  !trackState->types()[Trk::TrackStateOnSurface::Measurement] &&
516  !trackState->types()[Trk::TrackStateOnSurface::Outlier] ) {
517  continue;
518  }
519 
520  // Check if we want to store this types of TSOS
521  if(!m_storeOutliers && trackState->types()[Trk::TrackStateOnSurface::Outlier] )
522  continue;
523 
524 
525  if(!m_storeHoles && trackState->types()[Trk::TrackStateOnSurface::Hole] )
526  continue;
527 
528  // Check that the surface has detector element
529  if(!trackState->surface().associatedDetectorElement()){
530  continue;
531  }
532 
533  // Check that the surface ID is valid
534  Identifier surfaceID = trackState->surface().associatedDetectorElement()->identify();
535  if( !surfaceID.is_valid() ){
536  ATH_MSG_WARNING("Invalid surface ID");
537  continue;
538  }
539 
540  //Determine what detector the hit is in
541  bool isPixel(false);
542  bool isSCT(false);
543  bool isTRT(false);
544 
545  if( m_idHelper->is_trt(surfaceID) ){
546  isTRT = true;
547  if(!m_storeTRT)
548  continue;
549  }else if( m_idHelper->is_sct(surfaceID) ){
550  isSCT = true;
551  if(!m_storeSCT)
552  continue;
553  }else if( m_idHelper->is_pixel(surfaceID) ){
554  isPixel = true;
555  if(!m_storePixel)
556  continue;
557  }
558 
559  if( !isPixel && !isSCT && !isTRT ){
560  continue;
561  }
562 
563  //Create new MSOS to fill with information
565 
566  //Put it in the obeject in the correct conatiner - one for each detector type.
567  if(isTRT){
568  //Add the msos to the container
569  msosTRT->push_back( msos );
570  //Set the det id
572  //Build the element link to the MSOS
573  ElementLink< xAOD::TrackStateValidationContainer > elink( *msosTRT, nTRT_MSOS );
574  elink.toPersistent();
575  msosLink.push_back(elink);
576  ++nTRT_MSOS;
577  }else if(isSCT){
578  //Add the msos to the container
579  msosSCT->push_back( msos );
580  //Set the det id
582  //Build the element link to the MSOS
583  ElementLink< xAOD::TrackStateValidationContainer > elink( *msosSCT, nSCT_MSOS );
584  elink.toPersistent();
585  msosLink.push_back(elink);
586  ++nSCT_MSOS;
587  }else if(isPixel){
588  //Add the msos to the container
589  msosPixel->push_back( msos );
590  //Set the det id
592  //Build the element link to the MSOS
593  ElementLink< xAOD::TrackStateValidationContainer > elink( *msosPixel, nPixelMSOS );
594  elink.toPersistent();
595  msosLink.push_back(elink);
596  ++nPixelMSOS;
597  }
598  else {
599  ATH_MSG_WARNING("NOT a pixel, SCT or TRT track state on surface.");
600  delete msos;
601  continue;
602  }
603 
604  //fill type
605  if( trackState->types()[Trk::TrackStateOnSurface::Hole] ){
607  } else if (trackState->types()[Trk::TrackStateOnSurface::Measurement]){
609  } else if ( trackState->types()[Trk::TrackStateOnSurface::Outlier] ) {
611  }
612 
613  //Fill surface id
614  msos->setDetElementId( surfaceID.get_compact() );
615 
616 
617  const Trk::TrackParameters* tp = trackState->trackParameters();
618 
619  // some more detailed hit info
620  double lTheta=-1000., lPhi=-1000.;
621  //Get the measurement base object
622  const Trk::MeasurementBase* measurement=trackState->measurementOnTrack();
623  static const SG::Accessor<float> errDCAcc("errDC");
624  errDCAcc(*msos) = -1 ;
625  const Trk::RIO_OnTrack* rotp = dynamic_cast<const Trk::RIO_OnTrack*>(measurement) ;
626  if (rotp) errDCAcc(*msos) = sqrt(rotp->localCovariance()(Trk::driftRadius, Trk::driftRadius)) ;
627 
628  if (m_storeTRT) {
629  const InDet::TRT_DriftCircleOnTrack *driftcircle = dynamic_cast<const InDet::TRT_DriftCircleOnTrack*>(measurement);
630  static const SG::Accessor<float> HitZAcc("HitZ");
631  static const SG::Accessor<float> HitRAcc("HitR");
632  static const SG::Accessor<float> rTrkWireAcc("rTrkWire");
633  if (!measurement) {
634  HitZAcc(*msos)=-3000;
635  HitRAcc(*msos)=-1;
636  rTrkWireAcc(*msos)=-1;
637  }
638  else {
639  if (!driftcircle) {
640  HitZAcc(*msos)=-3000;
641  HitRAcc(*msos)=-1;
642  rTrkWireAcc(*msos)=-1;
643  }
644  else {
645  if (tp) {
646  const Amg::Vector3D& gp = driftcircle->globalPosition();
647  HitZAcc(*msos)=gp.z();
648  HitRAcc(*msos)=gp.perp();
649  rTrkWireAcc(*msos)= fabs(trackState->trackParameters()->parameters()[Trk::driftRadius]);
650  lTheta = trackState->trackParameters()->parameters()[Trk::theta];
651  lPhi = trackState->trackParameters()->parameters()[Trk::phi];
652  }
653  else {
654  HitZAcc(*msos) =driftcircle->associatedSurface().center().z();
655  HitRAcc(*msos) =driftcircle->associatedSurface().center().perp();
656  rTrkWireAcc(*msos)=0;
657  }
658  }
659  }
660  msos->setLocalAngles(lTheta, lPhi);
661 
662  bool isShared=false;
663  if (prd_to_track_map_cptr) {
664  const Trk::RIO_OnTrack* hit_trt = measurement ? dynamic_cast<const Trk::RIO_OnTrack*>(measurement) : nullptr;
665  if (hit_trt) {
666  if (prd_to_track_map_cptr->isShared(*(hit_trt->prepRawData())) ) isShared=true;
667  static const SG::Accessor<bool> isSharedAcc("isShared");
668  isSharedAcc(*msos) = isShared;
669  }
670  }
671  }
672 
673 
674  // Track extrapolation
675  std::unique_ptr<const Trk::TrackParameters> extrap( m_extrapolator->extrapolateTrack(ctx,*trkTrack,trackState->surface()) );
676 
677  // Set local positions on the surface
678  if (tp) {
679  msos->setLocalPosition( tp->parameters()[0], tp->parameters()[1] );
680 
681  if (extrap.get()) {
682  ATH_MSG_DEBUG(" Original position " << tp->parameters()[0] << " " << tp->parameters()[1]);
683  ATH_MSG_DEBUG("Extrapolated position " << extrap->parameters()[0] << " " << extrap->parameters()[1]);
684  }
685 
686  }
687  else {
688  if (extrap.get()) {
689  msos->setLocalPosition( extrap->parameters()[0], extrap->parameters()[1] );
690  }
691  else {
692  ATH_MSG_DEBUG("Track extrapolation failed.");
693  }
694  }
695 
696  // Set calculate local incident angles
697  const Trk::TrkDetElementBase *de = trackState->surface().associatedDetectorElement();
698  const InDetDD::SiDetectorElement *side = dynamic_cast<const InDetDD::SiDetectorElement *>(de);
699  if (side && (isSCT || isPixel)) {
700  const Amg::Vector3D& mynormal = side->normal();
701  const Amg::Vector3D& myphiax = side->phiAxis();
702  const Amg::Vector3D& myetaax = side->etaAxis();
703  if (tp) {
704  Amg::Vector3D mytrack = tp->momentum();
705  float trketacomp = mytrack.dot(myetaax);
706  float trkphicomp = mytrack.dot(myphiax);
707  float trknormcomp = mytrack.dot(mynormal);
708 
709  ATH_MSG_DEBUG(" Original incident angle " << trketacomp << " " << trkphicomp << " " << trknormcomp);
710  if (extrap.get()) {
711  Amg::Vector3D metrack = extrap->momentum();
712  float trketacompX = metrack.dot(myetaax);
713  float trkphicompX = metrack.dot(myphiax);
714  float trknormcompX = metrack.dot(mynormal);
715  ATH_MSG_DEBUG("Extrapolated incident angle " << trketacompX << " " << trkphicompX << " " << trknormcompX);
716  }
717  msos->setLocalAngles( atan2(trketacomp,trknormcomp), atan2(trkphicomp,trknormcomp) );
718  }
719  else {
720  if (extrap.get()) {
721  Amg::Vector3D metrack = extrap->momentum();
722  float trketacompX = metrack.dot(myetaax);
723  float trkphicompX = metrack.dot(myphiax);
724  float trknormcompX = metrack.dot(mynormal);
725  msos->setLocalAngles( atan2(trketacompX,trknormcompX), atan2(trkphicompX,trknormcompX) );
726  }
727  }
728  }
729 
730  if(!measurement) { continue; }
731 
732  if (isTRT && !trtDCOffsets.isValid() && !trtDCs.isValid()) { continue; }
733  if (isSCT && !sctClusterOffsets.isValid() && !sctClusters.isValid()) { continue; }
734  if (isPixel && !pixelClusterOffsets.isValid() && !pixelClusters.isValid()) { continue; }
735 
736  const Trk::RIO_OnTrack* hit = measurement ? dynamic_cast<const Trk::RIO_OnTrack*>(measurement) : nullptr;
737 
738  if(!hit){
739  const Trk::CompetingRIOsOnTrack *crot = dynamic_cast<const Trk::CompetingRIOsOnTrack*>(measurement);
740  if(crot){
741  hit = &crot->rioOnTrack( crot->indexOfMaxAssignProb() );
742  }
743  }
744 
745  if(m_addPRD && hit){
746  // Build an element link to the xAOD PRD
747  const Trk::PrepRawData* prd = hit->prepRawData();
748  if(prd && prd->getHashAndIndex().isValid() ){
749  if(isTRT){
750  msos->setTrackMeasurementValidationLink( buildElementLink( prd, trtDCOffsets.cptr(), trtDCs.cptr()) );
751  }else if(isSCT){
752  msos->setTrackMeasurementValidationLink( buildElementLink( prd, sctClusterOffsets.cptr(), sctClusters.cptr()) );
753  }else if(isPixel){
754  msos->setTrackMeasurementValidationLink( buildElementLink( prd, pixelClusterOffsets.cptr(), pixelClusters.cptr()) );
755  }
756  }
757  }
758 
759  // Add the drift time for the tracks position -- note the position is biased
760  if (isTRT) {
761  TRTCond::RtRelation const *rtr = m_trtcaldbTool->getRtRelation(surfaceID);
762  if(rtr) {
763  static const SG::Accessor<float> driftTimeAcc("driftTime");
764  if (tp){
765  driftTimeAcc(*msos) = rtr->drifttime(fabs(tp->parameters()[0]));
766  }
767  else {
768  if (extrap.get()) {
769  driftTimeAcc(*msos) = rtr->drifttime(fabs(extrap->parameters()[0]));
770  }
771  }
772  }
773  }
774 
775  static const SG::Accessor<float> TrackError_biasedAcc("TrackError_biased");
776  static const SG::Accessor<float> TrackError_unbiasedAcc("TrackError_unbiased");
777  if (m_addPulls) {
778 
779  std::optional<Trk::ResidualPull> biased;
780  std::optional<Trk::ResidualPull> unbiased;
781  if (tp) {
782  biased= m_residualPullCalculator->residualPull(measurement, tp, Trk::ResidualPull::Biased);
783  if (m_storeTRT) TrackError_biasedAcc(*msos) = sqrt(fabs((*tp->covariance())(Trk::locX,Trk::locX)));
784 
785  if (m_storeTRT) TrackError_biasedAcc(*msos) = sqrt(fabs((*tp->covariance())(Trk::locX,Trk::locX)));
786  std::unique_ptr<const Trk::TrackParameters> unbiasedTp( m_updator->removeFromState(*tp, measurement->localParameters(), measurement->localCovariance()) );
787  if(unbiasedTp.get()) {
788  if (m_storeTRT) TrackError_unbiasedAcc(*msos) = sqrt(fabs((*unbiasedTp.get()->covariance())(Trk::locX,Trk::locX)));
789  unbiased = m_residualPullCalculator->residualPull(measurement, unbiasedTp.get(), Trk::ResidualPull::Unbiased);
790  }
791  }
792  else {
793  if (extrap.get()) {
794  if (m_storeTRT) TrackError_unbiasedAcc(*msos) = sqrt(fabs((*extrap.get()->covariance())(Trk::locX,Trk::locX)));
795  biased = m_residualPullCalculator->residualPull(measurement, extrap.get(), Trk::ResidualPull::Biased);
796  unbiased = m_residualPullCalculator->residualPull(measurement, extrap.get(), Trk::ResidualPull::Unbiased);
797  }
798  }
799 
800  if (biased) {
801  if(biased->dimension()>Trk::locY){
802  msos->setBiasedResidual( biased->residual()[Trk::locX], biased->residual()[Trk::locY] );
803  msos->setBiasedPull( biased->pull()[Trk::locX], biased->pull()[Trk::locY] );
804  } else {
805  msos->setBiasedResidual( biased->residual()[Trk::locX], 0 );
806  msos->setBiasedPull( biased->pull()[Trk::locX], 0 );
807  }
808  }
809 
810  if (unbiased) {
811  if(unbiased->dimension()>Trk::locY){
812  msos->setUnbiasedResidual( unbiased->residual()[Trk::locX], unbiased->residual()[Trk::locY] );
813  msos->setUnbiasedPull( unbiased->pull()[Trk::locX], unbiased->pull()[Trk::locY] );
814  } else {
815  msos->setUnbiasedResidual( unbiased->residual()[Trk::locX], 0 );
816  msos->setUnbiasedPull( unbiased->pull()[Trk::locX], 0 );
817  }
818  }
819 
820  }
821 
822  } //end loop over TSOS's
823 
824  ATH_MSG_DEBUG("The number of TSOS's " << msosLink.size() );
825 
826  dectsos_msosLink( *track ) = msosLink;
827 
828  ATH_MSG_DEBUG("Finished dressing TrackParticle");
829 
830 
831  } // end of loop over tracks
832  return StatusCode::SUCCESS;
833  }

◆ buildElementLink()

ElementLink< xAOD::TrackMeasurementValidationContainer > DerivationFramework::TrackStateOnSurfaceDecorator::buildElementLink ( const Trk::PrepRawData prd,
const std::vector< unsigned int > *  offsets,
const xAOD::TrackMeasurementValidationContainer xaodPrdCont 
) const
private

Definition at line 836 of file TrackStateOnSurfaceDecorator.cxx.

839  {
840 
841  const IdentContIndex& contIndex = prd->getHashAndIndex();
842  if( contIndex.collHash() >= offsets->size() ){
843  ATH_MSG_ERROR(" Offsets are incorrect " << contIndex.collHash() << " " << offsets->size() <<" "<< contIndex.objIndex());
844  return {0,0};
845  }
846 
847  unsigned int xaodIndex = offsets->at( contIndex.collHash() ) + contIndex.objIndex();
849  el.toPersistent();
850 
851  return el;
852 
853  }

◆ declareGaudiProperty() [1/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  hndl,
const SG::VarHandleKeyArrayType  
)
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleKeyArray>

Definition at line 170 of file AthCommonDataStore.h.

172  {
173  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
174  hndl.value(),
175  hndl.documentation());
176 
177  }

◆ declareGaudiProperty() [2/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  hndl,
const SG::VarHandleKeyType  
)
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleKey>

Definition at line 156 of file AthCommonDataStore.h.

158  {
159  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
160  hndl.value(),
161  hndl.documentation());
162 
163  }

◆ declareGaudiProperty() [3/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  hndl,
const SG::VarHandleType  
)
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleBase>

Definition at line 184 of file AthCommonDataStore.h.

186  {
187  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
188  hndl.value(),
189  hndl.documentation());
190  }

◆ declareGaudiProperty() [4/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  t,
const SG::NotHandleType  
)
inlineprivateinherited

specialization for handling everything that's not a Gaudi::Property<SG::VarHandleKey> or a <SG::VarHandleKeyArray>

Definition at line 199 of file AthCommonDataStore.h.

200  {
201  return PBASE::declareProperty(t);
202  }

◆ declareProperty() [1/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
SG::VarHandleBase hndl,
const std::string &  doc,
const SG::VarHandleType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
hndlObject holding the property value.
docDocumentation string for the property.

This is the version for types that derive from SG::VarHandleBase. The property value object is put on the input and output lists as appropriate; then we forward to the base class.

Definition at line 245 of file AthCommonDataStore.h.

249  {
250  this->declare(hndl.vhKey());
251  hndl.vhKey().setOwner(this);
252 
253  return PBASE::declareProperty(name,hndl,doc);
254  }

◆ declareProperty() [2/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
SG::VarHandleKey hndl,
const std::string &  doc,
const SG::VarHandleKeyType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
hndlObject holding the property value.
docDocumentation string for the property.

This is the version for types that derive from SG::VarHandleKey. The property value object is put on the input and output lists as appropriate; then we forward to the base class.

Definition at line 221 of file AthCommonDataStore.h.

225  {
226  this->declare(hndl);
227  hndl.setOwner(this);
228 
229  return PBASE::declareProperty(name,hndl,doc);
230  }

◆ declareProperty() [3/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
SG::VarHandleKeyArray hndArr,
const std::string &  doc,
const SG::VarHandleKeyArrayType  
)
inlineinherited

Definition at line 259 of file AthCommonDataStore.h.

263  {
264 
265  // std::ostringstream ost;
266  // ost << Algorithm::name() << " VHKA declareProp: " << name
267  // << " size: " << hndArr.keys().size()
268  // << " mode: " << hndArr.mode()
269  // << " vhka size: " << m_vhka.size()
270  // << "\n";
271  // debug() << ost.str() << endmsg;
272 
273  hndArr.setOwner(this);
274  m_vhka.push_back(&hndArr);
275 
276  Gaudi::Details::PropertyBase* p = PBASE::declareProperty(name, hndArr, doc);
277  if (p != 0) {
278  p->declareUpdateHandler(&AthCommonDataStore<PBASE>::updateVHKA, this);
279  } else {
280  ATH_MSG_ERROR("unable to call declareProperty on VarHandleKeyArray "
281  << name);
282  }
283 
284  return p;
285 
286  }

◆ declareProperty() [4/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
T &  property,
const std::string &  doc,
const SG::NotHandleType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
propertyObject holding the property value.
docDocumentation string for the property.

This is the generic version, for types that do not derive from SG::VarHandleKey. It just forwards to the base class version of declareProperty.

Definition at line 333 of file AthCommonDataStore.h.

337  {
338  return PBASE::declareProperty(name, property, doc);
339  }

◆ declareProperty() [5/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
T &  property,
const std::string &  doc = "none" 
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
propertyObject holding the property value.
docDocumentation string for the property.

This dispatches to either the generic declareProperty or the one for VarHandle/Key/KeyArray.

Definition at line 352 of file AthCommonDataStore.h.

355  {
356  typedef typename SG::HandleClassifier<T>::type htype;
357  return declareProperty (name, property, doc, htype());
358  }

◆ declareProperty() [6/6]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( Gaudi::Property< T > &  t)
inlineinherited

Definition at line 145 of file AthCommonDataStore.h.

145  {
146  typedef typename SG::HandleClassifier<T>::type htype;
148  }

◆ detStore()

const ServiceHandle<StoreGateSvc>& AthCommonDataStore< AthCommonMsg< AlgTool > >::detStore ( ) const
inlineinherited

The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 95 of file AthCommonDataStore.h.

95 { return m_detStore; }

◆ evtStore() [1/2]

ServiceHandle<StoreGateSvc>& AthCommonDataStore< AthCommonMsg< AlgTool > >::evtStore ( )
inlineinherited

The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 85 of file AthCommonDataStore.h.

85 { return m_evtStore; }

◆ evtStore() [2/2]

const ServiceHandle<StoreGateSvc>& AthCommonDataStore< AthCommonMsg< AlgTool > >::evtStore ( ) const
inlineinherited

The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 90 of file AthCommonDataStore.h.

90 { return m_evtStore; }

◆ extraDeps_update_handler()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::extraDeps_update_handler ( Gaudi::Details::PropertyBase &  ExtraDeps)
protectedinherited

Add StoreName to extra input/output deps as needed.

use the logic of the VarHandleKey to parse the DataObjID keys supplied via the ExtraInputs and ExtraOuputs Properties to add the StoreName if it's not explicitly given

◆ finalize()

StatusCode DerivationFramework::TrackStateOnSurfaceDecorator::finalize ( )

Definition at line 210 of file TrackStateOnSurfaceDecorator.cxx.

211  {
212  ATH_MSG_DEBUG("Finalize");
213  return StatusCode::SUCCESS;
214  }

◆ initialize()

StatusCode DerivationFramework::TrackStateOnSurfaceDecorator::initialize ( )

Definition at line 102 of file TrackStateOnSurfaceDecorator.cxx.

103  {
104  ATH_MSG_DEBUG("Initialize");
105 
106  if (m_sgName.value() == "notSet") {
107  ATH_MSG_ERROR("No decoration prefix name provided for the output of TrackStateOnSurfaceDecorator! Use the variable DecorationPrefix to properly set a prefix.");
108  return StatusCode::FAILURE;
109  }
110  ATH_MSG_DEBUG("Prefix for decoration: " << m_sgName);
111 
113  if (m_containerName.key().empty()) {
114  ATH_MSG_ERROR("No TrackParticle collection provided for TrackStateOnSurfaceDecorator!");
115  return StatusCode::FAILURE;
116  }
117  ATH_MSG_DEBUG("Input TrackParticle container: " << m_containerName.key());
119 
120  // need Atlas id-helpers to identify sub-detectors, take them from detStore
121  if (detStore()->retrieve(m_idHelper, "AtlasID").isFailure()) {
122  ATH_MSG_ERROR("Could not get AtlasDetectorID helper");
123  return StatusCode::FAILURE;
124  }
125 
126  if( m_storePixel && detStore()->retrieve(m_pixId,"PixelID").isFailure() ){
127  ATH_MSG_ERROR("Unable to retrieve pixel ID helper");
128  return StatusCode::FAILURE;
129  }
130 
131  if( m_storeSCT && detStore()->retrieve(m_sctId,"SCT_ID").isFailure() ){
132  ATH_MSG_ERROR("Could not retrieve SCT helper");
133  return StatusCode::FAILURE;
134  }
135 
136  if( m_storeTRT && detStore()->retrieve(m_trtId,"TRT_ID").isFailure() ){
137  ATH_MSG_ERROR("Could not retrieve TRT helper");
138  return StatusCode::FAILURE;
139  }
140 
141  ATH_CHECK( m_trtcaldbTool.retrieve(DisableTool{ !m_storeTRT }));
143 
144  ATH_CHECK( m_updator.retrieve(DisableTool{ !m_addPulls }));
145  ATH_CHECK( m_residualPullCalculator.retrieve(DisableTool{ !m_addPulls }));
146 
147  ATH_CHECK( m_holeSearchTool.retrieve( DisableTool{ !m_storeHoles}) );
148 
149  ATH_CHECK( m_TRTdEdxTool.retrieve( DisableTool{!m_storeTRT || m_TRTdEdxTool.empty()}) );
150 
151  ATH_CHECK(m_extrapolator.retrieve());
152 
153 
155 
156  if (m_addExtraEventInfo) {
157  std::vector<std::string> decor_names{"TrtPhaseTime"};
158  std::vector<SG::WriteDecorHandleKey<xAOD::EventInfo> > decor_key_out;
160  assert(m_trtPhaseDecorKey.size() == 1);
161  }
162  if (m_storeTRT && m_TRTdEdxTool.isEnabled()) {
163  std::vector<std::string> names;
164  names.resize(kNTRTFloatDecor);
165  names[kTRTdEdxDecor]="ToT_dEdx";
166  names[kTRTusedHitsDecor]="ToT_usedHits";
167  names[kTRTdEdx_noHT_divByLDecor]="ToT_dEdx_noHT_divByL";
168  names[kTRTusedHits_noHT_divByLDecor]="ToT_usedHits_noHT_divByL";
170  }
175 
178  ATH_CHECK( m_trtDCName.initialize(m_storeTRT && m_addPRD) );
179 
181  ATH_CHECK( m_sctMsosName.initialize(m_storeSCT && m_addPRD) );
182  ATH_CHECK( m_trtMsosName.initialize(m_storeTRT && m_addPRD) );
183 
184  if (m_storePixel){
185  std::vector<std::string> names;
186  names.resize(kNPixFloatDecor);
187  names[kTrkIBLXDecor]="TrkIBLX";
188  names[kTrkIBLYDecor]="TrkIBLY";
189  names[kTrkIBLZDecor]="TrkIBLZ";
190  names[kTrkBLXDecor]="TrkBLX";
191  names[kTrkBLYDecor]="TrkBLY";
192  names[kTrkBLZDecor]="TrkBLZ";
193  names[kTrkL1XDecor]="TrkL1X";
194  names[kTrkL1YDecor]="TrkL1Y";
195  names[kTrkL1ZDecor]="TrkL1Z";
196  names[kTrkL2XDecor]="TrkL2X";
197  names[kTrkL2YDecor]="TrkL2Y";
198  names[kTrkL2ZDecor]="TrkL2Z";
200  }
201 
202  m_trackTSOSMOSLinkDecorKey = m_containerName.key() + "." + m_sgName + "msosLink";
204 
205  ATH_MSG_DEBUG("Initialization finished.");
206 
207  return StatusCode::SUCCESS;
208  }

◆ inputHandles()

virtual std::vector<Gaudi::DataHandle*> AthCommonDataStore< AthCommonMsg< AlgTool > >::inputHandles ( ) const
overridevirtualinherited

Return this algorithm's input handles.

We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.

◆ interfaceID()

static const InterfaceID& DerivationFramework::IAugmentationTool::interfaceID ( )
inlinestaticinherited

AlgTool interface methods.

Definition at line 31 of file IAugmentationTool.h.

31 { return IID_IAugmentationTool; }

◆ msg() [1/2]

MsgStream& AthCommonMsg< AlgTool >::msg ( ) const
inlineinherited

Definition at line 24 of file AthCommonMsg.h.

24  {
25  return this->msgStream();
26  }

◆ msg() [2/2]

MsgStream& AthCommonMsg< AlgTool >::msg ( const MSG::Level  lvl) const
inlineinherited

Definition at line 27 of file AthCommonMsg.h.

27  {
28  return this->msgStream(lvl);
29  }

◆ msgLvl()

bool AthCommonMsg< AlgTool >::msgLvl ( const MSG::Level  lvl) const
inlineinherited

Definition at line 30 of file AthCommonMsg.h.

30  {
31  return this->msgLevel(lvl);
32  }

◆ outputHandles()

virtual std::vector<Gaudi::DataHandle*> AthCommonDataStore< AthCommonMsg< AlgTool > >::outputHandles ( ) const
overridevirtualinherited

Return this algorithm's output handles.

We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.

◆ renounce()

std::enable_if_t<std::is_void_v<std::result_of_t<decltype(&T::renounce)(T)> > && !std::is_base_of_v<SG::VarHandleKeyArray, T> && std::is_base_of_v<Gaudi::DataHandle, T>, void> AthCommonDataStore< AthCommonMsg< AlgTool > >::renounce ( T &  h)
inlineprotectedinherited

Definition at line 380 of file AthCommonDataStore.h.

381  {
382  h.renounce();
383  PBASE::renounce (h);
384  }

◆ renounceArray()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::renounceArray ( SG::VarHandleKeyArray handlesArray)
inlineprotectedinherited

remove all handles from I/O resolution

Definition at line 364 of file AthCommonDataStore.h.

364  {
365  handlesArray.renounce();
366  }

◆ sysInitialize()

virtual StatusCode AthCommonDataStore< AthCommonMsg< AlgTool > >::sysInitialize ( )
overridevirtualinherited

Perform system initialization for an algorithm.

We override this to declare all the elements of handle key arrays at the end of initialization. See comments on updateVHKA.

Reimplemented in DerivationFramework::CfAthAlgTool, AthCheckedComponent< AthAlgTool >, AthCheckedComponent<::AthAlgTool >, and asg::AsgMetadataTool.

◆ sysStart()

virtual StatusCode AthCommonDataStore< AthCommonMsg< AlgTool > >::sysStart ( )
overridevirtualinherited

Handle START transition.

We override this in order to make sure that conditions handle keys can cache a pointer to the conditions container.

◆ updateVHKA()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::updateVHKA ( Gaudi::Details::PropertyBase &  )
inlineinherited

Definition at line 308 of file AthCommonDataStore.h.

308  {
309  // debug() << "updateVHKA for property " << p.name() << " " << p.toString()
310  // << " size: " << m_vhka.size() << endmsg;
311  for (auto &a : m_vhka) {
312  std::vector<SG::VarHandleKey*> keys = a->keys();
313  for (auto k : keys) {
314  k->setOwner(this);
315  }
316  }
317  }

Member Data Documentation

◆ m_addExtraEventInfo

bool DerivationFramework::TrackStateOnSurfaceDecorator::m_addExtraEventInfo
private

Definition at line 77 of file TrackStateOnSurfaceDecorator.h.

◆ m_addPRD

bool DerivationFramework::TrackStateOnSurfaceDecorator::m_addPRD
private

Definition at line 76 of file TrackStateOnSurfaceDecorator.h.

◆ m_addPulls

bool DerivationFramework::TrackStateOnSurfaceDecorator::m_addPulls
private

Definition at line 74 of file TrackStateOnSurfaceDecorator.h.

◆ m_addSurfaceInfo

bool DerivationFramework::TrackStateOnSurfaceDecorator::m_addSurfaceInfo
private

Definition at line 75 of file TrackStateOnSurfaceDecorator.h.

◆ m_containerName

SG::ReadHandleKey<xAOD::TrackParticleContainer> DerivationFramework::TrackStateOnSurfaceDecorator::m_containerName { this, "ContainerName", "InDetTrackParticles", "" }
private

Definition at line 84 of file TrackStateOnSurfaceDecorator.h.

◆ m_detStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< AlgTool > >::m_detStore
privateinherited

Pointer to StoreGate (detector store by default)

Definition at line 393 of file AthCommonDataStore.h.

◆ m_eventInfoKey

SG::ReadHandleKey<xAOD::EventInfo> DerivationFramework::TrackStateOnSurfaceDecorator::m_eventInfoKey { this, "EventInfoKey", "EventInfo", "" }
private

Definition at line 80 of file TrackStateOnSurfaceDecorator.h.

◆ m_evtStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< AlgTool > >::m_evtStore
privateinherited

Pointer to StoreGate (event store by default)

Definition at line 390 of file AthCommonDataStore.h.

◆ m_extrapolator

ToolHandle<Trk::IExtrapolator> DerivationFramework::TrackStateOnSurfaceDecorator::m_extrapolator
private

Definition at line 127 of file TrackStateOnSurfaceDecorator.h.

◆ m_holeSearchTool

ToolHandle<Trk::ITrackHoleSearchTool> DerivationFramework::TrackStateOnSurfaceDecorator::m_holeSearchTool
private

Definition at line 126 of file TrackStateOnSurfaceDecorator.h.

◆ m_idHelper

const AtlasDetectorID* DerivationFramework::TrackStateOnSurfaceDecorator::m_idHelper
private

Definition at line 119 of file TrackStateOnSurfaceDecorator.h.

◆ m_isSimulation

bool DerivationFramework::TrackStateOnSurfaceDecorator::m_isSimulation
private

Definition at line 67 of file TrackStateOnSurfaceDecorator.h.

◆ m_pixelClustersName

SG::ReadHandleKey<xAOD::TrackMeasurementValidationContainer > DerivationFramework::TrackStateOnSurfaceDecorator::m_pixelClustersName {this, "PixelClustersName", "PixelClusters" ,"" }
private

Definition at line 96 of file TrackStateOnSurfaceDecorator.h.

◆ m_pixelLayerRadii

Gaudi::Property< std::vector<float> > DerivationFramework::TrackStateOnSurfaceDecorator::m_pixelLayerRadii {this, "PixelLayerRadii", {29.5,50.5,88.5,122.5}, "Radii to extrapolate to for estimating track position on layers" }
private

Definition at line 146 of file TrackStateOnSurfaceDecorator.h.

◆ m_pixelMapName

SG::ReadHandleKey<std::vector<unsigned int> > DerivationFramework::TrackStateOnSurfaceDecorator::m_pixelMapName { this, "PixelMapName", "PixelClustersOffsets" , ""}
private

Definition at line 89 of file TrackStateOnSurfaceDecorator.h.

◆ m_pixelMsosName

SG::WriteHandleKey<xAOD::TrackStateValidationContainer> DerivationFramework::TrackStateOnSurfaceDecorator::m_pixelMsosName { this, "PixelMsosName", "PixelMSOSs", "" }
private

Definition at line 106 of file TrackStateOnSurfaceDecorator.h.

◆ m_pixId

const PixelID* DerivationFramework::TrackStateOnSurfaceDecorator::m_pixId
private

Definition at line 120 of file TrackStateOnSurfaceDecorator.h.

◆ m_prdToTrackMap

SG::ReadHandleKey<Trk::PRDtoTrackMap> DerivationFramework::TrackStateOnSurfaceDecorator::m_prdToTrackMap { this,"PRDtoTrackMap","","option PRD-to-track association"}
private

Definition at line 103 of file TrackStateOnSurfaceDecorator.h.

◆ m_residualPullCalculator

ToolHandle<Trk::IResidualPullCalculator> DerivationFramework::TrackStateOnSurfaceDecorator::m_residualPullCalculator
private

Definition at line 125 of file TrackStateOnSurfaceDecorator.h.

◆ m_sctClustersName

SG::ReadHandleKey<xAOD::TrackMeasurementValidationContainer > DerivationFramework::TrackStateOnSurfaceDecorator::m_sctClustersName {this, "SctClustersName", "SCT_Clusters" ,"" }
private

Definition at line 98 of file TrackStateOnSurfaceDecorator.h.

◆ m_SCTDetEleCollKey

SG::ReadCondHandleKey<InDetDD::SiDetectorElementCollection> DerivationFramework::TrackStateOnSurfaceDecorator::m_SCTDetEleCollKey {this, "SCTDetEleCollKey", "SCT_DetectorElementCollection", "Key of SiDetectorElementCollection for SCT"}
private

Definition at line 115 of file TrackStateOnSurfaceDecorator.h.

◆ m_sctId

const SCT_ID* DerivationFramework::TrackStateOnSurfaceDecorator::m_sctId
private

Definition at line 121 of file TrackStateOnSurfaceDecorator.h.

◆ m_sctMapName

SG::ReadHandleKey<std::vector<unsigned int> > DerivationFramework::TrackStateOnSurfaceDecorator::m_sctMapName { this, "SctMapName", "SCT_ClustersOffsets" , ""}
private

Definition at line 91 of file TrackStateOnSurfaceDecorator.h.

◆ m_sctMsosName

SG::WriteHandleKey<xAOD::TrackStateValidationContainer> DerivationFramework::TrackStateOnSurfaceDecorator::m_sctMsosName { this, "SctMsosName", "SCT_MSOSs", "" }
private

Definition at line 108 of file TrackStateOnSurfaceDecorator.h.

◆ m_sgName

Gaudi::Property<std::string> DerivationFramework::TrackStateOnSurfaceDecorator::m_sgName { this, "DecorationPrefix", "IDDET1_",""}
private

Definition at line 82 of file TrackStateOnSurfaceDecorator.h.

◆ m_storeHoles

bool DerivationFramework::TrackStateOnSurfaceDecorator::m_storeHoles
private

Definition at line 69 of file TrackStateOnSurfaceDecorator.h.

◆ m_storeOutliers

bool DerivationFramework::TrackStateOnSurfaceDecorator::m_storeOutliers
private

Definition at line 70 of file TrackStateOnSurfaceDecorator.h.

◆ m_storePixel

bool DerivationFramework::TrackStateOnSurfaceDecorator::m_storePixel
private

Definition at line 73 of file TrackStateOnSurfaceDecorator.h.

◆ m_storeSCT

bool DerivationFramework::TrackStateOnSurfaceDecorator::m_storeSCT
private

Definition at line 72 of file TrackStateOnSurfaceDecorator.h.

◆ m_storeTRT

bool DerivationFramework::TrackStateOnSurfaceDecorator::m_storeTRT
private

Definition at line 71 of file TrackStateOnSurfaceDecorator.h.

◆ m_trackPixFloatDecorKeys

std::vector<SG::WriteDecorHandleKey<xAOD::TrackParticleContainer> > DerivationFramework::TrackStateOnSurfaceDecorator::m_trackPixFloatDecorKeys
private

Definition at line 144 of file TrackStateOnSurfaceDecorator.h.

◆ m_trackTRTFloatDecorKeys

std::vector<SG::WriteDecorHandleKey<xAOD::TrackParticleContainer> > DerivationFramework::TrackStateOnSurfaceDecorator::m_trackTRTFloatDecorKeys
private

Definition at line 138 of file TrackStateOnSurfaceDecorator.h.

◆ m_trackTSOSMOSLinkDecorKey

SG::WriteDecorHandleKey<xAOD::TrackParticleContainer> DerivationFramework::TrackStateOnSurfaceDecorator::m_trackTSOSMOSLinkDecorKey
private

Definition at line 145 of file TrackStateOnSurfaceDecorator.h.

◆ m_trtcaldbTool

ToolHandle<ITRT_CalDbTool> DerivationFramework::TrackStateOnSurfaceDecorator::m_trtcaldbTool
private

Definition at line 128 of file TrackStateOnSurfaceDecorator.h.

◆ m_trtDCName

SG::ReadHandleKey<xAOD::TrackMeasurementValidationContainer> DerivationFramework::TrackStateOnSurfaceDecorator::m_trtDCName {this, "TrtDriftCirclesName", "TRT_DriftCircles" ,"" }
private

Definition at line 100 of file TrackStateOnSurfaceDecorator.h.

◆ m_TRTdEdxTool

ToolHandle<ITRT_ToT_dEdx> DerivationFramework::TrackStateOnSurfaceDecorator::m_TRTdEdxTool
private

Definition at line 130 of file TrackStateOnSurfaceDecorator.h.

◆ m_trtId

const TRT_ID* DerivationFramework::TrackStateOnSurfaceDecorator::m_trtId
private

Definition at line 122 of file TrackStateOnSurfaceDecorator.h.

◆ m_trtMapName

SG::ReadHandleKey<std::vector<unsigned int> > DerivationFramework::TrackStateOnSurfaceDecorator::m_trtMapName { this, "TrtMapName", "TRT_DriftCirclesOffsets" , ""}
private

Definition at line 93 of file TrackStateOnSurfaceDecorator.h.

◆ m_trtMsosName

SG::WriteHandleKey<xAOD::TrackStateValidationContainer> DerivationFramework::TrackStateOnSurfaceDecorator::m_trtMsosName { this, "TrtMsosName", "TRT_MSOSs", ""}
private

Definition at line 110 of file TrackStateOnSurfaceDecorator.h.

◆ m_trtPhaseDecorKey

std::vector<SG::WriteDecorHandleKey<xAOD::EventInfo> > DerivationFramework::TrackStateOnSurfaceDecorator::m_trtPhaseDecorKey
private

Definition at line 132 of file TrackStateOnSurfaceDecorator.h.

◆ m_trtPhaseKey

SG::ReadHandleKey<ComTime> DerivationFramework::TrackStateOnSurfaceDecorator::m_trtPhaseKey { this,"TRTPhaseKey","TRT_Phase", ""}
private

Definition at line 86 of file TrackStateOnSurfaceDecorator.h.

◆ m_updator

ToolHandle<Trk::IUpdator> DerivationFramework::TrackStateOnSurfaceDecorator::m_updator
private

Definition at line 124 of file TrackStateOnSurfaceDecorator.h.

◆ m_varHandleArraysDeclared

bool AthCommonDataStore< AthCommonMsg< AlgTool > >::m_varHandleArraysDeclared
privateinherited

Definition at line 399 of file AthCommonDataStore.h.

◆ m_vhka

std::vector<SG::VarHandleKeyArray*> AthCommonDataStore< AthCommonMsg< AlgTool > >::m_vhka
privateinherited

Definition at line 398 of file AthCommonDataStore.h.


The documentation for this class was generated from the following files:
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
DerivationFramework::TrackStateOnSurfaceDecorator::m_residualPullCalculator
ToolHandle< Trk::IResidualPullCalculator > m_residualPullCalculator
Definition: TrackStateOnSurfaceDecorator.h:125
DerivationFramework::TrackStateOnSurfaceDecorator::kNPixFloatDecor
@ kNPixFloatDecor
Definition: TrackStateOnSurfaceDecorator.h:143
DerivationFramework::TrackStateOnSurfaceDecorator::kTrkIBLYDecor
@ kTrkIBLYDecor
Definition: TrackStateOnSurfaceDecorator.h:139
Trk::TrackState::Pixel
@ Pixel
Definition: TrackStateDefs.h:28
DerivationFramework::TrackStateOnSurfaceDecorator::m_pixelMapName
SG::ReadHandleKey< std::vector< unsigned int > > m_pixelMapName
Definition: TrackStateOnSurfaceDecorator.h:90
DerivationFramework::TrackStateOnSurfaceDecorator::kTRTusedHitsDecor
@ kTRTusedHitsDecor
Definition: TrackStateOnSurfaceDecorator.h:134
xAOD::TrackStateValidation_v1::setUnbiasedResidual
void setUnbiasedResidual(float unbiasedResidualX, float unbiasedResidualY)
Sets the unbiased residual.
Definition: TrackStateValidation_v1.cxx:47
Trk::Surface::associatedDetectorElement
const TrkDetElementBase * associatedDetectorElement() const
return associated Detector Element
python.PerfMonSerializer.p
def p
Definition: PerfMonSerializer.py:743
DerivationFramework::createDecoratorKeys
void createDecoratorKeys(T_Parent &parent, const SG::ReadHandleKey< T_Cont > &container_key, const std::string &prefix, const std::vector< std::string > &decor_names, std::vector< SG::WriteDecorHandleKey< T_Cont > > &decor_out)
Definition: DecoratorUtils.h:20
DerivationFramework::TrackStateOnSurfaceDecorator::kTRTdEdx_noHT_divByLDecor
@ kTRTdEdx_noHT_divByLDecor
Definition: TrackStateOnSurfaceDecorator.h:135
Trk::TrackState::TRT
@ TRT
Definition: TrackStateDefs.h:30
Trk::locX
@ locX
Definition: ParamDefs.h:43
Trk::locY
@ locY
local cartesian
Definition: ParamDefs.h:44
SG::ReadHandle::cptr
const_pointer_type cptr()
Dereference the pointer.
Trk::Track
The ATLAS Track class.
Definition: Tracking/TrkEvent/TrkTrack/TrkTrack/Track.h:73
SG::Accessor< float >
xAOD::TrackStateValidation_v1::setDetType
void setDetType(char detType)
Sets the detector type.
AtlasDetectorID::is_sct
bool is_sct(Identifier id) const
Definition: AtlasDetectorID.h:770
Trk::PRDtoTrackMap
Definition: PRDtoTrackMap.h:17
Trk::oppositeMomentum
@ oppositeMomentum
Definition: PropDirection.h:21
SG::ReadHandle
Definition: StoreGate/StoreGate/ReadHandle.h:70
AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
Definition: AthCommonDataStore.h:145
InDetDD::holes
@ holes
Definition: InDetDD_Defs.h:17
Trk::Track::trackStateOnSurfaces
const Trk::TrackStates * trackStateOnSurfaces() const
return a pointer to a const DataVector of const TrackStateOnSurfaces.
DerivationFramework::TrackStateOnSurfaceDecorator::m_trtPhaseKey
SG::ReadHandleKey< ComTime > m_trtPhaseKey
Definition: TrackStateOnSurfaceDecorator.h:87
Trk::Track::info
const TrackInfo & info() const
Returns a const ref to info of a const tracks.
DerivationFramework::TrackStateOnSurfaceDecorator::m_trtMapName
SG::ReadHandleKey< std::vector< unsigned int > > m_trtMapName
Definition: TrackStateOnSurfaceDecorator.h:94
xAOD::TrackStateValidation
TrackStateValidation_v1 TrackStateValidation
Reference the current persistent version:
Definition: TrackStateValidation.h:13
Trk::ResidualPull::Unbiased
@ Unbiased
RP with track state that has measurement not included.
Definition: ResidualPull.h:57
InDet::TRT_DriftCircleOnTrack::associatedSurface
virtual const Trk::Surface & associatedSurface() const override final
returns the surface for the local to global transformation
Definition: TRT_DriftCircleOnTrack.cxx:154
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_evtStore
StoreGateSvc_t m_evtStore
Pointer to StoreGate (event store by default)
Definition: AthCommonDataStore.h:390
DerivationFramework::TrackStateOnSurfaceDecorator::kTrkL2XDecor
@ kTrkL2XDecor
Definition: TrackStateOnSurfaceDecorator.h:142
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_vhka
std::vector< SG::VarHandleKeyArray * > m_vhka
Definition: AthCommonDataStore.h:398
ParticleTest.tp
tp
Definition: ParticleTest.py:25
xAOD::TrackStateValidation_v1
Class describing a TrackStateValidation.
Definition: TrackStateValidation_v1.h:28
DerivationFramework::TrackStateOnSurfaceDecorator::m_isSimulation
bool m_isSimulation
Definition: TrackStateOnSurfaceDecorator.h:67
IdentContIndex
Identifiable container index to a contained object.
Definition: IdentContIndex.h:23
Trk::RIO_OnTrack
Definition: RIO_OnTrack.h:70
Trk::MaterialUpdateMode
MaterialUpdateMode
This is a steering enum to force the material update it can be: (1) addNoise (-1) removeNoise Second ...
Definition: MaterialUpdateMode.h:18
DerivationFramework::TrackStateOnSurfaceDecorator::m_trtcaldbTool
ToolHandle< ITRT_CalDbTool > m_trtcaldbTool
Definition: TrackStateOnSurfaceDecorator.h:128
Trk::alongMomentum
@ alongMomentum
Definition: PropDirection.h:20
Trk::TrkDetElementBase
Definition: TrkDetElementBase.h:52
xAOD::TrackStateValidation_v1::setUnbiasedPull
void setUnbiasedPull(float unbiasedPullX, float unbiasedPullY)
Sets the unbiased pull.
Definition: TrackStateValidation_v1.cxx:57
DerivationFramework::TrackStateOnSurfaceDecorator::m_extrapolator
ToolHandle< Trk::IExtrapolator > m_extrapolator
Definition: TrackStateOnSurfaceDecorator.h:127
AtlasDetectorID::is_trt
bool is_trt(Identifier id) const
Definition: AtlasDetectorID.h:782
DerivationFramework::TrackStateOnSurfaceDecorator::m_sctClustersName
SG::ReadHandleKey< xAOD::TrackMeasurementValidationContainer > m_sctClustersName
Definition: TrackStateOnSurfaceDecorator.h:99
DerivationFramework::TrackStateOnSurfaceDecorator::buildElementLink
ElementLink< xAOD::TrackMeasurementValidationContainer > buildElementLink(const Trk::PrepRawData *, const std::vector< unsigned int > *, const xAOD::TrackMeasurementValidationContainer *) const
Definition: TrackStateOnSurfaceDecorator.cxx:836
read_hist_ntuple.t
t
Definition: read_hist_ntuple.py:5
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
Trk::Surface::center
const Amg::Vector3D & center() const
Returns the center position of the Surface.
DerivationFramework::TrackStateOnSurfaceDecorator::m_trtId
const TRT_ID * m_trtId
Definition: TrackStateOnSurfaceDecorator.h:122
InDet::TRT_DriftCircleOnTrack
Definition: TRT_DriftCircleOnTrack.h:53
Identifier::is_valid
bool is_valid() const
Check if id is in a valid state.
DerivationFramework::TrackStateOnSurfaceDecorator::kTrkL1XDecor
@ kTrkL1XDecor
Definition: TrackStateOnSurfaceDecorator.h:141
DerivationFramework::TrackStateOnSurfaceDecorator::m_sctMapName
SG::ReadHandleKey< std::vector< unsigned int > > m_sctMapName
Definition: TrackStateOnSurfaceDecorator.h:92
DerivationFramework::TrackStateOnSurfaceDecorator::kTrkL2ZDecor
@ kTrkL2ZDecor
Definition: TrackStateOnSurfaceDecorator.h:142
AthCommonDataStore< AthCommonMsg< AlgTool > >::detStore
const ServiceHandle< StoreGateSvc > & detStore() const
The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.
Definition: AthCommonDataStore.h:95
SG::VarHandleKeyArray::setOwner
virtual void setOwner(IDataHandleHolder *o)=0
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
TRT::Hit::side
@ side
Definition: HitInfo.h:83
DerivationFramework::TrackStateOnSurfaceDecorator::m_idHelper
const AtlasDetectorID * m_idHelper
Definition: TrackStateOnSurfaceDecorator.h:119
DerivationFramework::TrackStateOnSurfaceDecorator::m_sctMsosName
SG::WriteHandleKey< xAOD::TrackStateValidationContainer > m_sctMsosName
Definition: TrackStateOnSurfaceDecorator.h:109
Trk::ParametersT::associatedSurface
virtual const S & associatedSurface() const override final
Access to the Surface method.
TRTCond::RtRelation
Definition: RtRelation.h:27
DerivationFramework::TrackStateOnSurfaceDecorator::kNTRTFloatDecor
@ kNTRTFloatDecor
Definition: TrackStateOnSurfaceDecorator.h:137
Trk::CompetingRIOsOnTrack::rioOnTrack
virtual const RIO_OnTrack & rioOnTrack(unsigned int) const =0
returns the RIO_OnTrack (also known as ROT) objects depending on the integer.
Trk::TrackStateOnSurfaceComparisonFunction
Class providing comparison function, or relational definition, for sorting MeasurementBase objects.
Definition: TrackStateOnSurfaceComparisonFunction.h:37
DerivationFramework::TrackStateOnSurfaceDecorator::m_addExtraEventInfo
bool m_addExtraEventInfo
Definition: TrackStateOnSurfaceDecorator.h:77
Trk::PropDirection
PropDirection
Definition: PropDirection.h:19
DerivationFramework::TrackStateOnSurfaceDecorator::m_prdToTrackMap
SG::ReadHandleKey< Trk::PRDtoTrackMap > m_prdToTrackMap
Definition: TrackStateOnSurfaceDecorator.h:104
DerivationFramework::TrackStateOnSurfaceDecorator::kTRTusedHits_noHT_divByLDecor
@ kTRTusedHits_noHT_divByLDecor
Definition: TrackStateOnSurfaceDecorator.h:136
AthCommonDataStore
Definition: AthCommonDataStore.h:52
DerivationFramework::TrackStateOnSurfaceDecorator::kTrkBLYDecor
@ kTrkBLYDecor
Definition: TrackStateOnSurfaceDecorator.h:140
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition: AthMsgStreamMacros.h:33
Trk::TrackStateOnSurface::Hole
@ Hole
A hole on the track - this is defined in the following way.
Definition: TrackStateOnSurface.h:128
DerivationFramework::TrackStateOnSurfaceDecorator::kTrkBLZDecor
@ kTrkBLZDecor
Definition: TrackStateOnSurfaceDecorator.h:140
Identifier
Definition: DetectorDescription/Identifier/Identifier/Identifier.h:32
beamspotman.n
n
Definition: beamspotman.py:731
TRTCond::RtRelation::drifttime
virtual float drifttime(float radius) const =0
drifttime for given radius
Trk::theta
@ theta
Definition: ParamDefs.h:72
DerivationFramework::TrackStateOnSurfaceDecorator::kTrkL1ZDecor
@ kTrkL1ZDecor
Definition: TrackStateOnSurfaceDecorator.h:141
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
python.subdetectors.mmg.names
names
Definition: mmg.py:8
Trk::CylinderSurface
Definition: CylinderSurface.h:55
Trk::driftRadius
@ driftRadius
trt, straws
Definition: ParamDefs.h:59
SG::WriteDecorHandle
Handle class for adding a decoration to an object.
Definition: StoreGate/StoreGate/WriteDecorHandle.h:99
Trk::pion
@ pion
Definition: ParticleHypothesis.h:29
DerivationFramework::TrackStateOnSurfaceDecorator::m_storeOutliers
bool m_storeOutliers
Definition: TrackStateOnSurfaceDecorator.h:70
DerivationFramework::TrackStateOnSurfaceDecorator::kTrkBLXDecor
@ kTrkBLXDecor
Definition: TrackStateOnSurfaceDecorator.h:140
Trk::CompetingRIOsOnTrack
Base class for all CompetingRIOsOnTack implementations, extends the common MeasurementBase.
Definition: CompetingRIOsOnTrack.h:64
Trk::TrkDetElementBase::surface
virtual const Surface & surface() const =0
Return surface associated with this detector element.
plotIsoValidation.el
el
Definition: plotIsoValidation.py:197
ATH_CHECK
#define ATH_CHECK
Definition: AthCheckMacros.h:40
DerivationFramework::TrackStateOnSurfaceDecorator::m_pixelLayerRadii
Gaudi::Property< std::vector< float > > m_pixelLayerRadii
Definition: TrackStateOnSurfaceDecorator.h:146
DerivationFramework::TrackStateOnSurfaceDecorator::m_TRTdEdxTool
ToolHandle< ITRT_ToT_dEdx > m_TRTdEdxTool
Definition: TrackStateOnSurfaceDecorator.h:130
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_detStore
StoreGateSvc_t m_detStore
Pointer to StoreGate (detector store by default)
Definition: AthCommonDataStore.h:393
Trk::ParametersBase
Definition: ParametersBase.h:55
DerivationFramework::TrackStateOnSurfaceDecorator::kTrkIBLXDecor
@ kTrkIBLXDecor
Definition: TrackStateOnSurfaceDecorator.h:139
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
DerivationFramework::TrackStateOnSurfaceDecorator::kTRTdEdxDecor
@ kTRTdEdxDecor
Definition: TrackStateOnSurfaceDecorator.h:133
DerivationFramework::TrackStateOnSurfaceDecorator::m_trackTRTFloatDecorKeys
std::vector< SG::WriteDecorHandleKey< xAOD::TrackParticleContainer > > m_trackTRTFloatDecorKeys
Definition: TrackStateOnSurfaceDecorator.h:138
DerivationFramework::TrackStateOnSurfaceDecorator::m_storeHoles
bool m_storeHoles
Definition: TrackStateOnSurfaceDecorator.h:69
DerivationFramework::TrackStateOnSurfaceDecorator::m_updator
ToolHandle< Trk::IUpdator > m_updator
Definition: TrackStateOnSurfaceDecorator.h:124
SG::ReadHandle::isValid
virtual bool isValid() override final
Can the handle be successfully dereferenced?
AthAlgTool::AthAlgTool
AthAlgTool()
Default constructor:
DerivationFramework::TrackStateOnSurfaceDecorator::m_SCTDetEleCollKey
SG::ReadCondHandleKey< InDetDD::SiDetectorElementCollection > m_SCTDetEleCollKey
Definition: TrackStateOnSurfaceDecorator.h:115
Trk::MeasurementBase::localCovariance
const Amg::MatrixX & localCovariance() const
Interface method to get the localError.
Definition: MeasurementBase.h:138
SG::VarHandleKeyArray::renounce
virtual void renounce()=0
SG::HandleClassifier::type
std::conditional< std::is_base_of< SG::VarHandleKeyArray, T >::value, VarHandleKeyArrayType, type2 >::type type
Definition: HandleClassifier.h:54
DerivationFramework::TrackStateOnSurfaceDecorator::m_addPRD
bool m_addPRD
Definition: TrackStateOnSurfaceDecorator.h:76
Trk::PrepRawData
Definition: PrepRawData.h:62
DerivationFramework::TrackStateOnSurfaceDecorator::m_trackTSOSMOSLinkDecorKey
SG::WriteDecorHandleKey< xAOD::TrackParticleContainer > m_trackTSOSMOSLinkDecorKey
Definition: TrackStateOnSurfaceDecorator.h:145
Trk::MeasurementBase
Definition: MeasurementBase.h:58
IdentContIndex::objIndex
unsigned short objIndex() const
object index in collection
Definition: IdentContIndex.h:92
DerivationFramework::TrackStateOnSurfaceDecorator::m_addSurfaceInfo
bool m_addSurfaceInfo
Definition: TrackStateOnSurfaceDecorator.h:75
Trk::Track::perigeeParameters
const Perigee * perigeeParameters() const
return Perigee.
Definition: Tracking/TrkEvent/TrkTrack/src/Track.cxx:163
merge_scale_histograms.doc
string doc
Definition: merge_scale_histograms.py:9
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:192
xAOD::TrackStateValidation_v1::setBiasedPull
void setBiasedPull(float biasedPullX, float biasedPullY)
Sets the biased pull.
Definition: TrackStateValidation_v1.cxx:77
DerivationFramework::TrackStateOnSurfaceDecorator::m_storeSCT
bool m_storeSCT
Definition: TrackStateOnSurfaceDecorator.h:72
DerivationFramework::TrackStateOnSurfaceDecorator::m_storeTRT
bool m_storeTRT
Definition: TrackStateOnSurfaceDecorator.h:71
xAOD::TrackStateValidation_v1::setBiasedResidual
void setBiasedResidual(float biasedResidualX, float biasedResidualY)
Sets the biased residual.
Definition: TrackStateValidation_v1.cxx:67
DerivationFramework::TrackStateOnSurfaceDecorator::m_holeSearchTool
ToolHandle< Trk::ITrackHoleSearchTool > m_holeSearchTool
Definition: TrackStateOnSurfaceDecorator.h:126
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)
IdentContIndex::isValid
bool isValid() const
check that both fields are set
Definition: IdentContIndex.h:108
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.
std::stable_sort
void stable_sort(DataModel_detail::iterator< DVL > beg, DataModel_detail::iterator< DVL > end)
Specialization of stable_sort for DataVector/List.
Definition: DVL_algorithms.h:644
DerivationFramework::TrackStateOnSurfaceDecorator::m_sctId
const SCT_ID * m_sctId
Definition: TrackStateOnSurfaceDecorator.h:121
Trk::MeasurementBase::localParameters
const LocalParameters & localParameters() const
Interface method to get the LocalParameters.
Definition: MeasurementBase.h:132
DerivationFramework::TrackStateOnSurfaceDecorator::m_addPulls
bool m_addPulls
Definition: TrackStateOnSurfaceDecorator.h:74
Trk::PrepRawData::getHashAndIndex
const IdentContIndex & getHashAndIndex() const
xAOD::TrackStateValidation_v1::setLocalAngles
void setLocalAngles(float localTheta, float localPhi)
Sets the local angles.
Definition: TrackStateValidation_v1.cxx:37
xAOD::TrackStateValidation_v1::setLocalPosition
void setLocalPosition(float localX, float localY)
Sets the local position.
Definition: TrackStateValidation_v1.cxx:27
SG::WriteHandle
Definition: StoreGate/StoreGate/WriteHandle.h:76
DerivationFramework::TrackStateOnSurfaceDecorator::m_sgName
Gaudi::Property< std::string > m_sgName
Definition: TrackStateOnSurfaceDecorator.h:83
DerivationFramework::TrackStateOnSurfaceDecorator::m_trtMsosName
SG::WriteHandleKey< xAOD::TrackStateValidationContainer > m_trtMsosName
Definition: TrackStateOnSurfaceDecorator.h:111
DerivationFramework::TrackStateOnSurfaceDecorator::m_eventInfoKey
SG::ReadHandleKey< xAOD::EventInfo > m_eventInfoKey
Definition: TrackStateOnSurfaceDecorator.h:81
Trk::ResidualPull::Biased
@ Biased
RP with track state including the hit.
Definition: ResidualPull.h:55
a
TList * a
Definition: liststreamerinfos.cxx:10
SG::WriteDecorHandleKey::initialize
StatusCode initialize(bool used=true)
If this object is used as a property, then this should be called during the initialize phase.
h
Identifier::get_compact
value_type get_compact(void) const
Get the compact id.
SG::WriteHandle::record
StatusCode record(std::unique_ptr< T > data)
Record a const object to the store.
ATH_MSG_WARNING
#define ATH_MSG_WARNING(x)
Definition: AthMsgStreamMacros.h:32
Trk::addNoise
@ addNoise
Definition: MaterialUpdateMode.h:19
xAOD::TrackStateValidation_v1::setDetElementId
void setDetElementId(uint64_t detElementId)
Sets the detector element identifier.
DerivationFramework::TrackStateOnSurfaceDecorator::m_trackPixFloatDecorKeys
std::vector< SG::WriteDecorHandleKey< xAOD::TrackParticleContainer > > m_trackPixFloatDecorKeys
Definition: TrackStateOnSurfaceDecorator.h:144
SG::VarHandleBase::vhKey
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
Definition: StoreGate/src/VarHandleBase.cxx:616
DerivationFramework::TrackStateOnSurfaceDecorator::m_pixelMsosName
SG::WriteHandleKey< xAOD::TrackStateValidationContainer > m_pixelMsosName
Definition: TrackStateOnSurfaceDecorator.h:107
DerivationFramework::TrackStateOnSurfaceDecorator::m_pixelClustersName
SG::ReadHandleKey< xAOD::TrackMeasurementValidationContainer > m_pixelClustersName
Definition: TrackStateOnSurfaceDecorator.h:97
declareProperty
#define declareProperty(n, p, h)
Definition: BaseFakeBkgTool.cxx:15
Trk::hole
@ hole
Definition: MeasurementType.h:36
xAOD::TrackStateValidation_v1::setType
void setType(int type)
Sets the type (measurement, outlier, hole)
Trk::phi
@ phi
Definition: ParamDefs.h:81
python.Bindings.keys
keys
Definition: Control/AthenaPython/python/Bindings.py:790
DerivationFramework::TrackStateOnSurfaceDecorator::m_trtPhaseDecorKey
std::vector< SG::WriteDecorHandleKey< xAOD::EventInfo > > m_trtPhaseDecorKey
Definition: TrackStateOnSurfaceDecorator.h:132
xAOD::TrackStateValidation_v1::setTrackMeasurementValidationLink
void setTrackMeasurementValidationLink(ElementLink< xAOD::TrackMeasurementValidationContainer > trackMeasurementValidationLink)
sets the link to the TrackMeasurementValidationContainer
xAOD::track
@ track
Definition: TrackingPrimitives.h:512
Trk::TrackState::SCT
@ SCT
Definition: TrackStateDefs.h:29
InDet::TRT_DriftCircleOnTrack::globalPosition
virtual const Amg::Vector3D & globalPosition() const override final
return the global position of this RIO_OnTrack
Definition: TRT_DriftCircleOnTrack.cxx:160
Trk::CompetingRIOsOnTrack::indexOfMaxAssignProb
unsigned int indexOfMaxAssignProb() const
Index of the ROT with the highest assignment probability.
Definition: CompetingRIOsOnTrack.cxx:101
Trk::removeNoise
@ removeNoise
Definition: MaterialUpdateMode.h:20
DerivationFramework::TrackStateOnSurfaceDecorator::kTrkIBLZDecor
@ kTrkIBLZDecor
Definition: TrackStateOnSurfaceDecorator.h:139
DerivationFramework::TrackStateOnSurfaceDecorator::kTrkL2YDecor
@ kTrkL2YDecor
Definition: TrackStateOnSurfaceDecorator.h:142
DerivationFramework::TrackStateOnSurfaceDecorator::m_storePixel
bool m_storePixel
Definition: TrackStateOnSurfaceDecorator.h:73
DerivationFramework::TrackStateOnSurfaceDecorator::m_trtDCName
SG::ReadHandleKey< xAOD::TrackMeasurementValidationContainer > m_trtDCName
Definition: TrackStateOnSurfaceDecorator.h:101
AthCommonDataStore::declareGaudiProperty
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>
Definition: AthCommonDataStore.h:156
IdentContIndex::collHash
unsigned short collHash() const
Accessor to hash, obj index and combined index.
Definition: IdentContIndex.h:85
Trk::PRDtoTrackMap::isShared
bool isShared(const PrepRawData &prd) const
does this PRD belong to more than one track?
DerivationFramework::TrackStateOnSurfaceDecorator::m_containerName
SG::ReadHandleKey< xAOD::TrackParticleContainer > m_containerName
Definition: TrackStateOnSurfaceDecorator.h:85
Trk::TrackStateOnSurface::Measurement
@ Measurement
This is a measurement, and will at least contain a Trk::MeasurementBase.
Definition: TrackStateOnSurface.h:101
DerivationFramework::TrackStateOnSurfaceDecorator::kTrkL1YDecor
@ kTrkL1YDecor
Definition: TrackStateOnSurfaceDecorator.h:141
Trk::TrackInfo::particleHypothesis
ParticleHypothesis particleHypothesis() const
Returns the particle hypothesis used for Track fitting.
fitman.k
k
Definition: fitman.py:528
DerivationFramework::TrackStateOnSurfaceDecorator::m_pixId
const PixelID * m_pixId
Definition: TrackStateOnSurfaceDecorator.h:120