ATLAS Offline Software
Public Member Functions | Protected Member Functions | Private Types | Private Member Functions | Private Attributes | List of all members
RefitTracksAndVertex Class Reference

#include <RefitTracksAndVertex.h>

Inheritance diagram for RefitTracksAndVertex:
Collaboration diagram for RefitTracksAndVertex:

Public Member Functions

 RefitTracksAndVertex (const std::string &name, ISvcLocator *pSvcLocator)
 The RefitTracksAndVertex is an implementation to add the so-called TRT momentum constraint on a track. More...
 
 ~RefitTracksAndVertex ()
 
StatusCode initialize ()
 initialize method of this algorithm. More...
 
StatusCode execute ()
 execute method of this algorithm that is called for each event
More...
 
StatusCode finalize ()
 finalize method of this algorithm. More...
 
MsgStream & dump (MsgStream &outst) const
 
virtual StatusCode sysInitialize () override
 Override sysInitialize. More...
 
virtual const DataObjIDColl & extraOutputDeps () const override
 Return the list of extra output dependencies. 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 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
 

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

typedef ServiceHandle< StoreGateSvcStoreGateSvc_t
 

Private Member Functions

bool accept (const Trk::Track &track)
 Verifies if the given track passes the track selection criteria specified via the jobOptions. More...
 
const Trk::MeasurementSet addPM (Trk::MeasurementSet &ms, const Trk::PseudoMeasurementOnTrack *pm)
 adds a PseudoMeasurement to a MeasurementSet More...
 
const Trk::PseudoMeasurementOnTrackcreatePMfromSi (const Trk::Perigee *mp)
 creates a PseudoMeasurement with (z0, theta) from extended track perigee parameters More...
 
Trk::TrackfitSCTOnlyTrack (const Trk::Track *track)
 Strips of all TRT hits from the track and replaces them with a TRT momentum constraint from a the TRT segment belonging to the (extended) track (returns NULL in case of failure) More...
 
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

const AtlasDetectorIDm_idHelper
 Detector ID helper. More...
 
std::string m_vertexListInput
 Name of the TrackCollection (input) More...
 
std::string m_trackListOutput
 Name of the TrackCollection (Output) More...
 
std::string m_outputVertexContainerName
 Name of vertex container. More...
 
ToolHandle< Trk::ITrackFitterm_trackFitter
 The TrackFitter to refit the tracks (segment, momentum constraint) More...
 
ToolHandle< Trk::IVertexFitterm_vertexFitter
 The TrackFitter to refit the tracks (segment, momentum constraint) More...
 
bool m_applyTrkSel
 apply a selection on tracks or not More...
 
bool m_refitTracks
 refitTracks More...
 
bool m_addPM
 apply a pseudo measurement based on the original track (theta,z0) More...
 
double m_selPtMin
 minimal pT cut value for the TrackSelection More...
 
double m_selEtaMin
 minimal eta cut value for the TrackSelection More...
 
double m_selEtaMax
 maximal eta cut value for the TrackSelection More...
 
int m_selNHitPIXMin
 minimal number of PIX hits cut value for the TrackSelection More...
 
int m_selNHitSCTMin
 minimal number of SCT hits cut value for the TrackSelection More...
 
size_t m_nTracksProcessed
 Counter for number of tracks processed. More...
 
size_t m_nTracksPresel
 Counter for number of tracks passing the preselection. More...
 
size_t m_nTracksAccepted
 Counter for number of tracks passing the preselection and with PM. More...
 
size_t m_nRejectPIX
 Counter for number of tracks failing the min number of PIX hits req. More...
 
size_t m_nRejectSCT
 Counter for number of tracks failing the min number of SCT hits req. More...
 
size_t m_nRejectTRT
 Counter for number of tracks failing the min number of TRT hits req. More...
 
size_t m_nRejectPM
 Counter for number of tracks failing the addition of a pseudo-measurement (PM) More...
 
DataObjIDColl m_extendedExtraObjects
 
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 31 of file RefitTracksAndVertex.h.

Member Typedef Documentation

◆ StoreGateSvc_t

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

Definition at line 388 of file AthCommonDataStore.h.

Constructor & Destructor Documentation

◆ RefitTracksAndVertex()

RefitTracksAndVertex::RefitTracksAndVertex ( const std::string &  name,
ISvcLocator *  pSvcLocator 
)

The RefitTracksAndVertex is an implementation to add the so-called TRT momentum constraint on a track.

It was developed in the context of alignment, and its main idea is that if the TRT is free from "weak modes", its curvature measurement can be added as a PseudoMeasurement (PM) to a Si-only track. This extra information, taken into account while refitting the Si-only part of the track or read in by the alignment algorithms directly, can serve to eliminate the alignment weak modes from the Si tracker of ATLAS. More details can be found at: https://twiki.cern.ch/twiki/bin/view/Atlas/TRTMomConstraint

Definition at line 27 of file RefitTracksAndVertex.cxx.

28  : AthAlgorithm (name, pSvcLocator)
29  , m_idHelper(nullptr)
30  , m_vertexListInput("PrimaryVertices")
31  , m_trackListOutput("SiTracksWithRefitTracksAndVertex")
32  , m_outputVertexContainerName("RefittedPrimaryVertex")
33  , m_trackFitter("Trk::GlobalChi2Fitter/InDetTrackFitter")
34  , m_vertexFitter("Trk::FullVertexFitter")
35  , m_applyTrkSel(false)
36  , m_refitTracks(true)
37  , m_addPM(false)
38  , m_selPtMin(0)
39  , m_selEtaMin(-2.5)
40  , m_selEtaMax(2.5)
41  , m_selNHitPIXMin(0)
42  , m_selNHitSCTMin(6)
44  , m_nTracksPresel(0)
46  , m_nRejectPIX(0)
47  , m_nRejectSCT(0)
48  , m_nRejectTRT(0)
49  , m_nRejectPM(0)
50 {
51  // declare algorithm parameters
52  declareProperty("VertexListInput" , m_vertexListInput) ;
53  declareProperty("TrackListOutput" , m_trackListOutput) ;
54  declareProperty("OutputVertexContainer" , m_outputVertexContainerName) ;
55  declareProperty("TrackFitter" , m_trackFitter) ;
56  declareProperty("VertexFitterTool" , m_vertexFitter);
57  declareProperty("ApplyTrkSel" , m_applyTrkSel) ;
58  declareProperty("RefitTracks" , m_refitTracks) ;
59  declareProperty("AddPseudoMeasurement", m_addPM);
60  declareProperty("SelPtMin" , m_selPtMin) ;
61  declareProperty("SelEtaMin" , m_selEtaMin) ;
62  declareProperty("SelEtaMax" , m_selEtaMax) ;
63  declareProperty("SelNHitPIXMin" , m_selNHitPIXMin) ;
64  declareProperty("SelNHitSCTMin" , m_selNHitSCTMin) ;
65 
66 }

◆ ~RefitTracksAndVertex()

RefitTracksAndVertex::~RefitTracksAndVertex ( )

Definition at line 68 of file RefitTracksAndVertex.cxx.

68 {}

Member Function Documentation

◆ accept()

bool RefitTracksAndVertex::accept ( const Trk::Track track)
private

Verifies if the given track passes the track selection criteria specified via the jobOptions.

◆ addPM()

const Trk::MeasurementSet RefitTracksAndVertex::addPM ( Trk::MeasurementSet ms,
const Trk::PseudoMeasurementOnTrack pm 
)
private

adds a PseudoMeasurement to a MeasurementSet

Definition at line 237 of file RefitTracksAndVertex.cxx.

237  {
238  Trk::MeasurementSet sortedMS ;
239  sortedMS.push_back( pm ) ;
240  for( int i=0, i_max=ms.size() ; i!=i_max ; ++i ) {
241  sortedMS.push_back( ms[i] ) ;
242  }
243  return sortedMS ;
244 }

◆ createPMfromSi()

const Trk::PseudoMeasurementOnTrack * RefitTracksAndVertex::createPMfromSi ( const Trk::Perigee mp)
private

creates a PseudoMeasurement with (z0, theta) from extended track perigee parameters

Definition at line 213 of file RefitTracksAndVertex.cxx.

213  {
214  Trk::DefinedParameter z0 ( mp->parameters()[Trk::z0], Trk::z0 ) ;
215  Trk::DefinedParameter theta( mp->parameters()[Trk::theta], Trk::theta ) ;
216  std::vector<Trk::DefinedParameter> defPar ;
217  defPar.push_back( z0 ) ;
218  defPar.push_back( theta ) ;
219  if( !mp->covariance() ) return nullptr;
220  Trk::LocalParameters parFromSi( defPar ) ;
221  AmgSymMatrix(2) covFromSi;
222 
223  covFromSi( 0, 0 ) = (*mp->covariance())( Trk::z0,Trk::z0 ) ;
224  covFromSi( 1, 1 ) = (*mp->covariance())( Trk::theta,Trk::theta ) ;
225  covFromSi( 1, 0 ) = (*mp->covariance())( Trk::z0, Trk::theta ) ;
226  covFromSi( 0, 1 ) = (*mp->covariance())( Trk::z0, Trk::theta ) ;
227 
228  const Trk::Surface& mpSurf = mp->associatedSurface() ;
229 
230  Trk::PseudoMeasurementOnTrack *pm = new Trk::PseudoMeasurementOnTrack( std::move(parFromSi)
231  , covFromSi
232  , mpSurf
233  ) ;
234  return pm ;
235 }

◆ declareGaudiProperty() [1/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< Algorithm > >::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< Algorithm > >::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< Algorithm > >::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< Algorithm > >::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< Algorithm > >::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< Algorithm > >::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< Algorithm > >::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< Algorithm > >::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< Algorithm > >::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< Algorithm > >::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< Algorithm > >::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; }

◆ dump()

MsgStream & RefitTracksAndVertex::dump ( MsgStream &  outst) const

Definition at line 345 of file RefitTracksAndVertex.cxx.

345  {
346  outst << std::endl ;
347  outst << "|-------------------------------------------------------------------";
348  outst << "-----------------------------|" << std::endl ;
349  outst << "| processed : "
350  << std::setw(7) << m_nTracksProcessed
351  << " tracks |"
352  << std::endl ;
353  outst << "| accepted by track presel. : "
354  << std::setw(7) << m_nTracksPresel
355  << " tracks |"
356  << std::endl ;
357  outst << "| accepted by track presel. + PM : "
358  << std::setw(7) << m_nTracksAccepted
359  << " tracks |"
360  << std::endl ;
361  outst << "| ------------------------------------------------------------------";
362  outst << "---------------------------- |" << std::endl ;
363  outst << "| reject by # PIX hits : "
364  << std::setw(7) << m_nRejectPIX
365  << " tracks |"
366  << std::endl ;
367  outst << "| reject by # SCT hits : "
368  << std::setw(7) << m_nRejectSCT
369  << " tracks |"
370  << std::endl ;
371  outst << "| reject by # TRT hits : "
372  << std::setw(7) << m_nRejectTRT
373  << " tracks |"
374  << std::endl ;
375  outst << "| ------------------------------------------------------------------";
376  outst << "---------------------------- |" << std::endl ;
377  outst << "| reject by exist. PM(TRT) : "
378  << std::setw(7) << m_nRejectPM
379  << " tracks |"
380  << std::endl ;
381  outst << "|-------------------------------------------------------------------";
382  outst << "-----------------------------|" << std::endl ;
383  return outst ;
384 }

◆ evtStore() [1/2]

ServiceHandle<StoreGateSvc>& AthCommonDataStore< AthCommonMsg< Algorithm > >::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< Algorithm > >::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; }

◆ execute()

StatusCode RefitTracksAndVertex::execute ( )

execute method of this algorithm that is called for each event

Definition at line 123 of file RefitTracksAndVertex.cxx.

123  {
124 
125  TrackCollection* outputtracks = new TrackCollection() ;
126 
127  //---------------------------
128  // Primary Vertex
129  //---------------------------
130  const xAOD::VertexContainer* vertices = nullptr;
131  if ( !evtStore()->retrieve( vertices, m_vertexListInput ).isSuccess() ){ // retrieve arguments: container type, container key
132  ATH_MSG_WARNING("execute() Failed to retrieve Reconstructed vertex container. " << m_vertexListInput );
133  //ATH_MSG_ERROR(evtStore()->dump());
134  delete outputtracks;
135  return StatusCode::SUCCESS; //?? really
136  }
137 
138  if( evtStore()->record( outputtracks, m_trackListOutput ).isFailure() ) {
139  ATH_MSG_ERROR( "Failed to record trackcollection with name " << m_trackListOutput );
140  }
141 
142  xAOD::VertexContainer* theVertexContainer = new xAOD::VertexContainer;
143  xAOD::VertexAuxContainer* theVertexAuxContainer = new xAOD::VertexAuxContainer;
144  theVertexContainer->setStore( theVertexAuxContainer );
145 
146  CHECK( evtStore()->record(theVertexContainer, m_outputVertexContainerName) );
147  CHECK( evtStore()->record(theVertexAuxContainer, m_outputVertexContainerName + "Aux.") );
148 
149  const xAOD::Vertex* primaryVertex = nullptr;
150  for( const xAOD::Vertex* vertex: *vertices ) {
151  if( vertex->vertexType() == xAOD::VxType::PriVtx ) {
152  primaryVertex = vertex;
153  break;
154  }
155  }
156 
157  std::vector< const Trk::TrackParameters* > trackParametersToFit;
158 
159  // Check we have found a PV
160  if( primaryVertex ){
161  if(primaryVertex->nTrackParticles() < 2)
162  return StatusCode::SUCCESS;
163 
164  //Loop over all tracks in the PV
165  for(unsigned int i =0; i< primaryVertex->nTrackParticles(); ++i ){
166  auto trackParticle = primaryVertex->trackParticle( i );
167  auto track = trackParticle->track();
168  // Check that there is Trk::Track
169  if(track){
170  //Refit Track using on the SCT hits
171  if(m_refitTracks){
172  auto newTrack = fitSCTOnlyTrack( track ) ;
173  if(newTrack){
174  outputtracks->push_back( newTrack ) ;
175  if(newTrack->perigeeParameters())
176  trackParametersToFit.push_back( newTrack->perigeeParameters() );
177  }
178  } else {
179  if(track->perigeeParameters())
180  trackParametersToFit.push_back( track->perigeeParameters() );
181  }
182  }
183  }
184  m_nTracksProcessed += primaryVertex->nTrackParticles() ;
185  m_nTracksAccepted += outputtracks->size() ;
186  // Make sure there are at least 2 tracks to fit in the vertex fit
187 
188  ATH_MSG_DEBUG(" From: " << primaryVertex->nTrackParticles() << " tracks " << trackParametersToFit.size() << " will be used" );
189 
190  if(trackParametersToFit.size() > 1){
191 
192  Amg::Vector3D position = primaryVertex->position();
193  // Fit and store vertex
194  auto vertex = m_vertexFitter->fit(trackParametersToFit, position );
195  if(vertex){
196  theVertexContainer->push_back (vertex);
197  vertex->setVertexType(xAOD::VxType::PriVtx);
198 
199  ATH_MSG_DEBUG("Old Vtx " << primaryVertex->position());
200  ATH_MSG_DEBUG("New Vtx " << vertex->position());
201  }
202  }
203  }
204 
205 
206 
207 
208 
209  return StatusCode::SUCCESS;
210 } // execute(.)

◆ extraDeps_update_handler()

void AthCommonDataStore< AthCommonMsg< Algorithm > >::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

◆ extraOutputDeps()

const DataObjIDColl & AthAlgorithm::extraOutputDeps ( ) const
overridevirtualinherited

Return the list of extra output dependencies.

This list is extended to include symlinks implied by inheritance relations.

Definition at line 50 of file AthAlgorithm.cxx.

51 {
52  // If we didn't find any symlinks to add, just return the collection
53  // from the base class. Otherwise, return the extended collection.
54  if (!m_extendedExtraObjects.empty()) {
56  }
57  return Algorithm::extraOutputDeps();
58 }

◆ finalize()

StatusCode RefitTracksAndVertex::finalize ( )

finalize method of this algorithm.

Prints out a summary of all events

Definition at line 118 of file RefitTracksAndVertex.cxx.

118  {
119  ATH_MSG_DEBUG( (*this) ) ;
120  return StatusCode::SUCCESS;
121 }

◆ fitSCTOnlyTrack()

Trk::Track * RefitTracksAndVertex::fitSCTOnlyTrack ( const Trk::Track track)
private

Strips of all TRT hits from the track and replaces them with a TRT momentum constraint from a the TRT segment belonging to the (extended) track (returns NULL in case of failure)

Definition at line 246 of file RefitTracksAndVertex.cxx.

246  {
247  Trk::MeasurementSet setSCT ;
248  Trk::MeasurementSet setPix ;
249  Trk::MeasurementSet setTRT ;
250 
251  const Trk::Perigee* perTrk = track->perigeeParameters();
252  if( !perTrk ) {
253  ATH_MSG_WARNING("RefitTracksAndVertex() : No Perigee parameter on track!");
254  return nullptr ;
255  }
256 
257  if( perTrk->eta() < m_selEtaMin || perTrk->eta() > m_selEtaMax)
258  return nullptr ;
259 
260  if( perTrk->pT() < m_selPtMin)
261  return nullptr ;
262 
263 
264  //store all silicon measurements into the measurementset
265  DataVector<const Trk::MeasurementBase>::const_iterator it = track->measurementsOnTrack()->begin();
266  DataVector<const Trk::MeasurementBase>::const_iterator itEnd = track->measurementsOnTrack()->end();
267  for ( ; it!=itEnd; ++it){
268  if( !(*it) ) {
269  // log (MSG::WARNING) << "The MeasurementBase set has a void"
270  // << " member! Skip it.." << endmsg;
271  } else {
272  const Trk::RIO_OnTrack* rio = dynamic_cast <const Trk::RIO_OnTrack*>(*it);
273  if (rio != nullptr) {
274  const Identifier& surfaceID = (rio->identify()) ;
275  if( m_idHelper->is_sct(surfaceID) ) {
276  setSCT.push_back ( *it ) ;
277  } else if( m_idHelper->is_trt(surfaceID) ) {
278  setTRT.push_back ( *it ) ;
279  } else if( m_idHelper->is_pixel(surfaceID) ){
280  setPix.push_back ( *it ) ;
281  }
282  }
283  }
284  }
285 
286  if( (int)setSCT.size() < m_selNHitSCTMin )
287  return nullptr;
288 
289  ATH_MSG_DEBUG("RefitTracksAndVertex() : Found " << setSCT.size() << " SCT measurm's!" ) ;
290  ATH_MSG_DEBUG("RefitTracksAndVertex() : Found " << setPix.size() << " Pix measurm's!" ) ;
291  ATH_MSG_DEBUG("RefitTracksAndVertex() : Found " << setTRT.size() << " TRT measurm's!") ;
292 
293 
294  ATH_MSG_DEBUG( std::setiosflags( std::ios::scientific )) ;
295  ATH_MSG_DEBUG (std::setprecision( 7 )) ;
296  ATH_MSG_VERBOSE( std::setiosflags( std::ios::scientific )) ;
297  ATH_MSG_VERBOSE( std::setprecision( 7 )) ;
298 
299  // now add z_0 and theta from original track as PseudoMeas to the TRT MeasurementSet
300  if(m_addPM){
301  const Trk::PseudoMeasurementOnTrack *pmFromSi = createPMfromSi( perTrk ) ;
302  if( !pmFromSi ) {
303  ATH_MSG_ERROR("RefitTracksAndVertex() : PseudoMeasurementOnTrack creation failed! " );
304  return nullptr ;
305  }
306  ATH_MSG_DEBUG( "RefitTracksAndVertex() : pmFromSi " << *pmFromSi) ;
307  Trk::MeasurementSet setSCT = addPM( setSCT, pmFromSi ) ;
308  }
309 
310  // Add TRT hits as they do no harm
311  for( int i=0, i_max=setTRT.size() ; i!=i_max ; ++i ) {
312  setSCT.push_back( setTRT[i] ) ;
313  }
314 
315  ATH_MSG_VERBOSE ( "RefitTracksAndVertex() : Si+PM MeasurementSet : " );
316  for( int i=0, i_max=setSCT.size() ; i!=i_max ; ++i ) {
317  ATH_MSG_VERBOSE ("============== i=" << i << " =============");
318  ATH_MSG_VERBOSE ( *(setSCT[i]));
319  }
320  ATH_MSG_VERBOSE ("==========================================");
321 
322  // fit TRT part of the track with PseudoMeas on z_0, theta
323  Trk::Track* trkSCT=(m_trackFitter->fit(Gaudi::Hive::currentContext()
324  ,setSCT
325  , *perTrk
326  , true
327  , Trk::pion
328  //, Trk::muon
329  //, Trk::nonInteracting
330  )).release() ;
331  if( !trkSCT ) {
332  ATH_MSG_DEBUG( "RefitTracksAndVertex() : Fit of SCT part of the track failed! " ) ;
333  return nullptr ;
334  }
335  const Trk::Perigee* perSCT = trkSCT->perigeeParameters();
336  ATH_MSG_VERBOSE( "RefitTracksAndVertex() : perSCT " << *perSCT) ;
337 
338  return trkSCT;
339 }

◆ initialize()

StatusCode RefitTracksAndVertex::initialize ( )

initialize method of this algorithm.


Definition at line 70 of file RefitTracksAndVertex.cxx.

70  {
71  //retrieve the DetectorStore service
72  StatusCode status=detStore().retrieve() ;
73  if( status.isFailure() ) {
74  ATH_MSG_FATAL( "DetectorStore service not found !" );
75  return status;
76  }else{
77  ATH_MSG_DEBUG( "DetectorStore retrieved!" );
78  }
79 
80  if (detStore()->retrieve(m_idHelper, "AtlasID").isFailure()) {
81  ATH_MSG_FATAL( "Could not get AtlasDetectorID helper" );
82  return StatusCode::FAILURE;
83  }
84 
85  // Set up fitter
86  status = m_trackFitter.retrieve();
87  if (status.isFailure()) {
88  ATH_MSG_FATAL( "Could not find tool " << m_trackFitter << ". Exiting.");
89  return status ;
90  } else {
91  ATH_MSG_DEBUG( " Got " << m_trackFitter << " as TrackFitter. " ) ;
92  }
93 
94  // Set up fitter
95  status = m_vertexFitter.retrieve();
96  if (status.isFailure()) {
97  ATH_MSG_FATAL( "Could not find tool " << m_vertexFitter << ". Exiting.");
98  return status ;
99  } else {
100  ATH_MSG_DEBUG( " Got " << m_vertexFitter << " as VertexFitter. " ) ;
101  }
102 
103  // Print input properties
104  if( m_applyTrkSel ) {
106  "Track selection will be applied:"
107  << "\n " << m_selEtaMin << " < eta < " << m_selEtaMax
108  << "\n pT > " << m_selPtMin/Gaudi::Units::GeV << " GeV"
109  << "\n number_of_PIXEL_hits >= " << m_selNHitPIXMin
110  << "\n number_of_SCT_hits >= " << m_selNHitSCTMin
111  ) ;
112  } else {
113  ATH_MSG_DEBUG( "NO selection will be applied to tracks" ) ;
114  }
115  return StatusCode::SUCCESS;
116 } // initialize(.)

◆ inputHandles()

virtual std::vector<Gaudi::DataHandle*> AthCommonDataStore< AthCommonMsg< Algorithm > >::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.

◆ msg() [1/2]

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

Definition at line 24 of file AthCommonMsg.h.

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

◆ msg() [2/2]

MsgStream& AthCommonMsg< Algorithm >::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< Algorithm >::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< Algorithm > >::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< Algorithm > >::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< Algorithm > >::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()

StatusCode AthAlgorithm::sysInitialize ( )
overridevirtualinherited

Override sysInitialize.

Override sysInitialize from the base class.

Loop through all output handles, and if they're WriteCondHandles, automatically register them and this Algorithm with the CondSvc

Scan through all outputHandles, and if they're WriteCondHandles, register them with the CondSvc

Reimplemented from AthCommonDataStore< AthCommonMsg< Algorithm > >.

Reimplemented in AthAnalysisAlgorithm, AthFilterAlgorithm, PyAthena::Alg, and AthHistogramAlgorithm.

Definition at line 66 of file AthAlgorithm.cxx.

66  {
68 
69  if (sc.isFailure()) {
70  return sc;
71  }
72  ServiceHandle<ICondSvc> cs("CondSvc",name());
73  for (auto h : outputHandles()) {
74  if (h->isCondition() && h->mode() == Gaudi::DataHandle::Writer) {
75  // do this inside the loop so we don't create the CondSvc until needed
76  if ( cs.retrieve().isFailure() ) {
77  ATH_MSG_WARNING("no CondSvc found: won't autoreg WriteCondHandles");
78  return StatusCode::SUCCESS;
79  }
80  if (cs->regHandle(this,*h).isFailure()) {
81  sc = StatusCode::FAILURE;
82  ATH_MSG_ERROR("unable to register WriteCondHandle " << h->fullKey()
83  << " with CondSvc");
84  }
85  }
86  }
87  return sc;
88 }

◆ sysStart()

virtual StatusCode AthCommonDataStore< AthCommonMsg< Algorithm > >::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< Algorithm > >::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_addPM

bool RefitTracksAndVertex::m_addPM
private

apply a pseudo measurement based on the original track (theta,z0)

Definition at line 73 of file RefitTracksAndVertex.h.

◆ m_applyTrkSel

bool RefitTracksAndVertex::m_applyTrkSel
private

apply a selection on tracks or not

Definition at line 71 of file RefitTracksAndVertex.h.

◆ m_detStore

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

Pointer to StoreGate (detector store by default)

Definition at line 393 of file AthCommonDataStore.h.

◆ m_evtStore

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

Pointer to StoreGate (event store by default)

Definition at line 390 of file AthCommonDataStore.h.

◆ m_extendedExtraObjects

DataObjIDColl AthAlgorithm::m_extendedExtraObjects
privateinherited

Definition at line 79 of file AthAlgorithm.h.

◆ m_idHelper

const AtlasDetectorID* RefitTracksAndVertex::m_idHelper
private

Detector ID helper.

Definition at line 60 of file RefitTracksAndVertex.h.

◆ m_nRejectPIX

size_t RefitTracksAndVertex::m_nRejectPIX
private

Counter for number of tracks failing the min number of PIX hits req.

Definition at line 82 of file RefitTracksAndVertex.h.

◆ m_nRejectPM

size_t RefitTracksAndVertex::m_nRejectPM
private

Counter for number of tracks failing the addition of a pseudo-measurement (PM)

Definition at line 85 of file RefitTracksAndVertex.h.

◆ m_nRejectSCT

size_t RefitTracksAndVertex::m_nRejectSCT
private

Counter for number of tracks failing the min number of SCT hits req.

Definition at line 83 of file RefitTracksAndVertex.h.

◆ m_nRejectTRT

size_t RefitTracksAndVertex::m_nRejectTRT
private

Counter for number of tracks failing the min number of TRT hits req.

Definition at line 84 of file RefitTracksAndVertex.h.

◆ m_nTracksAccepted

size_t RefitTracksAndVertex::m_nTracksAccepted
private

Counter for number of tracks passing the preselection and with PM.

Definition at line 81 of file RefitTracksAndVertex.h.

◆ m_nTracksPresel

size_t RefitTracksAndVertex::m_nTracksPresel
private

Counter for number of tracks passing the preselection.

Definition at line 80 of file RefitTracksAndVertex.h.

◆ m_nTracksProcessed

size_t RefitTracksAndVertex::m_nTracksProcessed
private

Counter for number of tracks processed.

Definition at line 79 of file RefitTracksAndVertex.h.

◆ m_outputVertexContainerName

std::string RefitTracksAndVertex::m_outputVertexContainerName
private

Name of vertex container.

Definition at line 66 of file RefitTracksAndVertex.h.

◆ m_refitTracks

bool RefitTracksAndVertex::m_refitTracks
private

refitTracks

Definition at line 72 of file RefitTracksAndVertex.h.

◆ m_selEtaMax

double RefitTracksAndVertex::m_selEtaMax
private

maximal eta cut value for the TrackSelection

Definition at line 76 of file RefitTracksAndVertex.h.

◆ m_selEtaMin

double RefitTracksAndVertex::m_selEtaMin
private

minimal eta cut value for the TrackSelection

Definition at line 75 of file RefitTracksAndVertex.h.

◆ m_selNHitPIXMin

int RefitTracksAndVertex::m_selNHitPIXMin
private

minimal number of PIX hits cut value for the TrackSelection

Definition at line 77 of file RefitTracksAndVertex.h.

◆ m_selNHitSCTMin

int RefitTracksAndVertex::m_selNHitSCTMin
private

minimal number of SCT hits cut value for the TrackSelection

Definition at line 78 of file RefitTracksAndVertex.h.

◆ m_selPtMin

double RefitTracksAndVertex::m_selPtMin
private

minimal pT cut value for the TrackSelection

Definition at line 74 of file RefitTracksAndVertex.h.

◆ m_trackFitter

ToolHandle<Trk::ITrackFitter> RefitTracksAndVertex::m_trackFitter
private

The TrackFitter to refit the tracks (segment, momentum constraint)

Definition at line 67 of file RefitTracksAndVertex.h.

◆ m_trackListOutput

std::string RefitTracksAndVertex::m_trackListOutput
private

Name of the TrackCollection (Output)

Definition at line 65 of file RefitTracksAndVertex.h.

◆ m_varHandleArraysDeclared

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

Definition at line 399 of file AthCommonDataStore.h.

◆ m_vertexFitter

ToolHandle<Trk::IVertexFitter> RefitTracksAndVertex::m_vertexFitter
private

The TrackFitter to refit the tracks (segment, momentum constraint)

Definition at line 68 of file RefitTracksAndVertex.h.

◆ m_vertexListInput

std::string RefitTracksAndVertex::m_vertexListInput
private

Name of the TrackCollection (input)

Definition at line 61 of file RefitTracksAndVertex.h.

◆ m_vhka

std::vector<SG::VarHandleKeyArray*> AthCommonDataStore< AthCommonMsg< Algorithm > >::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
Trk::LocalParameters
Definition: LocalParameters.h:98
ATH_MSG_FATAL
#define ATH_MSG_FATAL(x)
Definition: AthMsgStreamMacros.h:34
xAOD::Vertex_v1::nTrackParticles
size_t nTrackParticles() const
Get the number of tracks associated with this vertex.
Definition: Vertex_v1.cxx:270
xAOD::VertexAuxContainer_v1
Temporary container used until we have I/O for AuxStoreInternal.
Definition: VertexAuxContainer_v1.h:32
python.PerfMonSerializer.p
def p
Definition: PerfMonSerializer.py:743
Trk::Track
The ATLAS Track class.
Definition: Tracking/TrkEvent/TrkTrack/TrkTrack/Track.h:73
RefitTracksAndVertex::m_idHelper
const AtlasDetectorID * m_idHelper
Detector ID helper.
Definition: RefitTracksAndVertex.h:60
AtlasDetectorID::is_sct
bool is_sct(Identifier id) const
Definition: AtlasDetectorID.h:770
AthCommonDataStore< AthCommonMsg< Algorithm > >::declareProperty
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
Definition: AthCommonDataStore.h:145
Trk::ParametersT
Dummy class used to allow special convertors to be called for surfaces owned by a detector element.
Definition: EMErrorDetail.h:25
RefitTracksAndVertex::m_vertexFitter
ToolHandle< Trk::IVertexFitter > m_vertexFitter
The TrackFitter to refit the tracks (segment, momentum constraint)
Definition: RefitTracksAndVertex.h:68
RefitTracksAndVertex::m_trackFitter
ToolHandle< Trk::ITrackFitter > m_trackFitter
The TrackFitter to refit the tracks (segment, momentum constraint)
Definition: RefitTracksAndVertex.h:67
theta
Scalar theta() const
theta method
Definition: AmgMatrixBasePlugin.h:71
CSV_InDetExporter.new
new
Definition: CSV_InDetExporter.py:145
RefitTracksAndVertex::addPM
const Trk::MeasurementSet addPM(Trk::MeasurementSet &ms, const Trk::PseudoMeasurementOnTrack *pm)
adds a PseudoMeasurement to a MeasurementSet
Definition: RefitTracksAndVertex.cxx:237
skel.it
it
Definition: skel.GENtoEVGEN.py:423
Surface
Definition: Trigger/TrigAccel/TrigCudaFitter/src/Surface.h:7
AthCommonDataStore< AthCommonMsg< Algorithm > >::m_evtStore
StoreGateSvc_t m_evtStore
Pointer to StoreGate (event store by default)
Definition: AthCommonDataStore.h:390
AthCommonDataStore< AthCommonMsg< Algorithm > >::m_vhka
std::vector< SG::VarHandleKeyArray * > m_vhka
Definition: AthCommonDataStore.h:398
RefitTracksAndVertex::m_selPtMin
double m_selPtMin
minimal pT cut value for the TrackSelection
Definition: RefitTracksAndVertex.h:74
Trk::z0
@ z0
Definition: ParamDefs.h:70
Trk::RIO_OnTrack
Definition: RIO_OnTrack.h:70
xAOD::Vertex_v1::position
const Amg::Vector3D & position() const
Returns the 3-pos.
AtlasDetectorID::is_trt
bool is_trt(Identifier id) const
Definition: AtlasDetectorID.h:782
read_hist_ntuple.t
t
Definition: read_hist_ntuple.py:5
ATH_MSG_VERBOSE
#define ATH_MSG_VERBOSE(x)
Definition: AthMsgStreamMacros.h:28
const
bool const RAWDATA *ch2 const
Definition: LArRodBlockPhysicsV0.cxx:562
RefitTracksAndVertex::m_trackListOutput
std::string m_trackListOutput
Name of the TrackCollection (Output)
Definition: RefitTracksAndVertex.h:65
xAOD::VertexContainer
VertexContainer_v1 VertexContainer
Definition of the current "Vertex container version".
Definition: VertexContainer.h:14
python.SystemOfUnits.ms
int ms
Definition: SystemOfUnits.py:132
AmgSymMatrix
#define AmgSymMatrix(dim)
Definition: EventPrimitives.h:52
AthenaPoolTestRead.sc
sc
Definition: AthenaPoolTestRead.py:27
Trk::DefinedParameter
std::pair< double, ParamDefs > DefinedParameter
Definition: DefinedParameter.h:27
AthCommonDataStore< AthCommonMsg< Algorithm > >::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
RefitTracksAndVertex::m_nRejectPM
size_t m_nRejectPM
Counter for number of tracks failing the addition of a pseudo-measurement (PM)
Definition: RefitTracksAndVertex.h:85
Trk::PseudoMeasurementOnTrack
Class to handle pseudo-measurements in fitters and on track objects.
Definition: PseudoMeasurementOnTrack.h:44
AthCommonDataStore< AthCommonMsg< Algorithm > >::evtStore
ServiceHandle< StoreGateSvc > & evtStore()
The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.
Definition: AthCommonDataStore.h:85
RefitTracksAndVertex::m_nTracksPresel
size_t m_nTracksPresel
Counter for number of tracks passing the preselection.
Definition: RefitTracksAndVertex.h:80
RefitTracksAndVertex::m_outputVertexContainerName
std::string m_outputVertexContainerName
Name of vertex container.
Definition: RefitTracksAndVertex.h:66
AthCommonDataStore
Definition: AthCommonDataStore.h:52
AthAlgorithm::sysInitialize
virtual StatusCode sysInitialize() override
Override sysInitialize.
Definition: AthAlgorithm.cxx:66
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition: AthMsgStreamMacros.h:33
RefitTracksAndVertex::m_selEtaMin
double m_selEtaMin
minimal eta cut value for the TrackSelection
Definition: RefitTracksAndVertex.h:75
AthCommonDataStore< AthCommonMsg< Algorithm > >::outputHandles
virtual std::vector< Gaudi::DataHandle * > outputHandles() const override
Return this algorithm's output handles.
xAOD::VertexAuxContainer
VertexAuxContainer_v1 VertexAuxContainer
Definition of the current jet auxiliary container.
Definition: VertexAuxContainer.h:19
RefitTracksAndVertex::m_selNHitSCTMin
int m_selNHitSCTMin
minimal number of SCT hits cut value for the TrackSelection
Definition: RefitTracksAndVertex.h:78
lumiFormat.i
int i
Definition: lumiFormat.py:92
TrackCollection
DataVector< Trk::Track > TrackCollection
This typedef represents a collection of Trk::Track objects.
Definition: TrackCollection.h:19
RefitTracksAndVertex::m_nRejectTRT
size_t m_nRejectTRT
Counter for number of tracks failing the min number of TRT hits req.
Definition: RefitTracksAndVertex.h:84
RefitTracksAndVertex::createPMfromSi
const Trk::PseudoMeasurementOnTrack * createPMfromSi(const Trk::Perigee *mp)
creates a PseudoMeasurement with (z0, theta) from extended track perigee parameters
Definition: RefitTracksAndVertex.cxx:213
Identifier
Definition: DetectorDescription/Identifier/Identifier/Identifier.h:32
Trk::theta
@ theta
Definition: ParamDefs.h:72
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
RefitTracksAndVertex::m_nRejectSCT
size_t m_nRejectSCT
Counter for number of tracks failing the min number of SCT hits req.
Definition: RefitTracksAndVertex.h:83
Trk::pion
@ pion
Definition: ParticleHypothesis.h:29
xAOD::VxType::PriVtx
@ PriVtx
Primary vertex.
Definition: TrackingPrimitives.h:571
CHECK
#define CHECK(...)
Evaluate an expression and check for errors.
Definition: Control/AthenaKernel/AthenaKernel/errorcheck.h:422
xAOD::Vertex_v1::trackParticle
const TrackParticle * trackParticle(size_t i) const
Get the pointer to a given track that was used in vertex reco.
Definition: Vertex_v1.cxx:249
AthCommonDataStore< AthCommonMsg< Algorithm > >::m_detStore
StoreGateSvc_t m_detStore
Pointer to StoreGate (detector store by default)
Definition: AthCommonDataStore.h:393
TRT::Track::z0
@ z0
Definition: InnerDetector/InDetCalibEvent/TRT_CalibData/TRT_CalibData/TrackInfo.h:63
DataVector< Trk::Track >
RefitTracksAndVertex::m_selNHitPIXMin
int m_selNHitPIXMin
minimal number of PIX hits cut value for the TrackSelection
Definition: RefitTracksAndVertex.h:77
SG::VarHandleKeyArray::renounce
virtual void renounce()=0
Trk::MeasurementSet
std::vector< const MeasurementBase * > MeasurementSet
vector of fittable measurements
Definition: FitterTypes.h:30
SG::HandleClassifier::type
std::conditional< std::is_base_of< SG::VarHandleKeyArray, T >::value, VarHandleKeyArrayType, type2 >::type type
Definition: HandleClassifier.h:54
Trk::Track::perigeeParameters
const Perigee * perigeeParameters() const
return Perigee.
Definition: Tracking/TrkEvent/TrkTrack/src/Track.cxx:163
Trk
Ensure that the ATLAS eigen extensions are properly loaded.
Definition: FakeTrackBuilder.h:9
merge_scale_histograms.doc
string doc
Definition: merge_scale_histograms.py:9
python.EventInfoMgtInit.release
release
Definition: EventInfoMgtInit.py:24
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:195
RefitTracksAndVertex::m_applyTrkSel
bool m_applyTrkSel
apply a selection on tracks or not
Definition: RefitTracksAndVertex.h:71
DataVector::push_back
value_type push_back(value_type pElem)
Add an element to the end of the collection.
RefitTracksAndVertex::m_vertexListInput
std::string m_vertexListInput
Name of the TrackCollection (input)
Definition: RefitTracksAndVertex.h:61
Amg::Vector3D
Eigen::Matrix< double, 3, 1 > Vector3D
Definition: GeoPrimitives.h:47
AthAlgorithm::m_extendedExtraObjects
DataObjIDColl m_extendedExtraObjects
Definition: AthAlgorithm.h:79
Trk::vertex
@ vertex
Definition: MeasurementType.h:21
a
TList * a
Definition: liststreamerinfos.cxx:10
h
xAOD::Vertex_v1
Class describing a Vertex.
Definition: Vertex_v1.h:42
RefitTracksAndVertex::m_nTracksProcessed
size_t m_nTracksProcessed
Counter for number of tracks processed.
Definition: RefitTracksAndVertex.h:79
ATH_MSG_WARNING
#define ATH_MSG_WARNING(x)
Definition: AthMsgStreamMacros.h:32
RefitTracksAndVertex::m_addPM
bool m_addPM
apply a pseudo measurement based on the original track (theta,z0)
Definition: RefitTracksAndVertex.h:73
Trk::RIO_OnTrack::identify
virtual Identifier identify() const final
return the identifier -extends MeasurementBase
Definition: RIO_OnTrack.h:155
SG::VarHandleBase::vhKey
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
Definition: StoreGate/src/VarHandleBase.cxx:616
RefitTracksAndVertex::fitSCTOnlyTrack
Trk::Track * fitSCTOnlyTrack(const Trk::Track *track)
Strips of all TRT hits from the track and replaces them with a TRT momentum constraint from a the TRT...
Definition: RefitTracksAndVertex.cxx:246
declareProperty
#define declareProperty(n, p, h)
Definition: BaseFakeBkgTool.cxx:15
Trk::MeasurementBaseType::PseudoMeasurementOnTrack
@ PseudoMeasurementOnTrack
Definition: MeasurementBase.h:51
AthAlgorithm::AthAlgorithm
AthAlgorithm()
Default constructor:
RefitTracksAndVertex::m_nTracksAccepted
size_t m_nTracksAccepted
Counter for number of tracks passing the preselection and with PM.
Definition: RefitTracksAndVertex.h:81
python.Bindings.keys
keys
Definition: Control/AthenaPython/python/Bindings.py:790
merge.status
status
Definition: merge.py:17
xAOD::track
@ track
Definition: TrackingPrimitives.h:512
LHEF::Writer
Pythia8::Writer Writer
Definition: Prophecy4fMerger.cxx:12
RefitTracksAndVertex::m_refitTracks
bool m_refitTracks
refitTracks
Definition: RefitTracksAndVertex.h:72
GeV
#define GeV
Definition: CaloTransverseBalanceVecMon.cxx:30
DataVector::size
size_type size() const noexcept
Returns the number of elements in the collection.
AthCommonDataStore::declareGaudiProperty
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>
Definition: AthCommonDataStore.h:156
RefitTracksAndVertex::m_nRejectPIX
size_t m_nRejectPIX
Counter for number of tracks failing the min number of PIX hits req.
Definition: RefitTracksAndVertex.h:82
fitman.k
k
Definition: fitman.py:528
ServiceHandle< ICondSvc >
RefitTracksAndVertex::m_selEtaMax
double m_selEtaMax
maximal eta cut value for the TrackSelection
Definition: RefitTracksAndVertex.h:76