|  | ATLAS Offline Software
    | 
 
 
 
#include <InDetRecStatisticsAlg.h>
|  | 
|  | InDetRecStatisticsAlg (const std::string &name, ISvcLocator *pSvcLocator) | 
|  | Default Constructor.  More... 
 | 
|  | 
| StatusCode | initialize () | 
|  | Initialization of services, track collections, creates TrackStatHelper for each Track Collection.  More... 
 | 
|  | 
| StatusCode | execute (const EventContext &ctx) const | 
|  | Calculation of statistics.  More... 
 | 
|  | 
| StatusCode | finalize () | 
|  | Statistics table printed, collection cleared.  More... 
 | 
|  | 
| StatusCode | getServices () | 
|  | Get various services such as StoreGate, dictionaries, detector managers etc.  More... 
 | 
|  | 
| StatusCode | resetStatistics () | 
|  | Clear statistics counters, called before each track collection is processed.  More... 
 | 
|  | 
| void | printStatistics () | 
|  | Print tracking statistics calculated with TrackStatHelper.  More... 
 | 
|  | 
| void | printTrackSummary (MsgStream &out, enum eta_region) | 
|  | Print track statistics for all and low proability tracks.  More... 
 | 
|  | 
| virtual StatusCode | sysInitialize () override | 
|  | Override sysInitialize.  More... 
 | 
|  | 
| virtual bool | isClonable () const override | 
|  | Specify if the algorithm is clonable.  More... 
 | 
|  | 
| virtual unsigned int | cardinality () const override | 
|  | Cardinality (Maximum number of clones that can exist) special value 0 means that algorithm is reentrant.  More... 
 | 
|  | 
| virtual StatusCode | sysExecute (const EventContext &ctx) override | 
|  | Execute an algorithm.  More... 
 | 
|  | 
| virtual const DataObjIDColl & | extraOutputDeps () const override | 
|  | Return the list of extra output dependencies.  More... 
 | 
|  | 
| virtual bool | filterPassed (const EventContext &ctx) const | 
|  | 
| virtual void | setFilterPassed (bool state, const EventContext &ctx) const | 
|  | 
| ServiceHandle< StoreGateSvc > & | evtStore () | 
|  | The standard StoreGateSvc(event store) Returns (kind of) a pointer to theStoreGateSvc.  More...
 | 
|  | 
| const ServiceHandle< StoreGateSvc > & | evtStore () const | 
|  | The standard StoreGateSvc(event store) Returns (kind of) a pointer to theStoreGateSvc.  More...
 | 
|  | 
| const ServiceHandle< StoreGateSvc > & | detStore () const | 
|  | The standard StoreGateSvc/DetectorStoreReturns (kind of) a pointer to theStoreGateSvc.  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, V, H > &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 | 
|  | 
|  | 
| void | selectGenSignal (const McEventCollection *, std::vector< std::pair< HepMC::ConstGenParticlePtr, int > > &, unsigned int, unsigned int, CounterLocal &counter) const | 
|  | Select charged,stable particles which pass pt and eta cuts for analysis.  More... 
 | 
|  | 
| void | selectRecSignal (const TrackCollection *, std::vector< const Trk::Track * > &, std::vector< const Trk::Track * > &, CounterLocal &counter) const | 
|  | Select for analysis reconstructed tracks passing Pt and eta cuts.  More... 
 | 
|  | 
| const Trk::TrackParameters * | getUnbiasedTrackParameters (const Trk::TrackParameters *, const Trk::MeasurementBase *) | 
|  | Get Unbiased Track Parameters.  More... 
 | 
|  | 
| Identifier | getIdentifier (const Trk::MeasurementBase *measurement) | 
|  | 
| Gaudi::Details::PropertyBase & | declareGaudiProperty (Gaudi::Property< T, V, H > &hndl, const SG::VarHandleKeyType &) | 
|  | specialization for handling Gaudi::Property<SG::VarHandleKey>  More... 
 | 
|  | 
| Gaudi::Details::PropertyBase & | declareGaudiProperty (Gaudi::Property< T, V, H > &hndl, const SG::VarHandleKeyArrayType &) | 
|  | specialization for handling Gaudi::Property<SG::VarHandleKeyArray>  More... 
 | 
|  | 
| Gaudi::Details::PropertyBase & | declareGaudiProperty (Gaudi::Property< T, V, H > &hndl, const SG::VarHandleType &) | 
|  | specialization for handling Gaudi::Property<SG::VarHandleBase>  More... 
 | 
|  | 
| Gaudi::Details::PropertyBase & | declareGaudiProperty (Gaudi::Property< T, V, H > &t, const SG::NotHandleType &) | 
|  | specialization for handling everything that's not a Gaudi::Property<SG::VarHandleKey> or a <SG::VarHandleKeyArray>  More... 
 | 
|  | 
Definition at line 46 of file InDetRecStatisticsAlg.h.
 
◆ CounterLocal
◆ StoreGateSvc_t
◆ ECounter
| Enumerator | 
|---|
| kN_rec_tracks_without_perigee | number of tracks w/o perigee  | 
| kN_unknown_hits | number of hits without track  | 
| kN_rec_tracks_processed | number of reconstructed tracks processed  | 
| kN_gen_tracks_processed | number of generated tracks processed  | 
| kN_spacepoints_processed | number of space points processed  | 
| kNCounter |  | 
Definition at line 147 of file InDetRecStatisticsAlg.h.
 
 
◆ InDetRecStatisticsAlg()
      
        
          | InDet::InDetRecStatisticsAlg::InDetRecStatisticsAlg | ( | const std::string & | name, | 
        
          |  |  | ISvcLocator * | pSvcLocator | 
        
          |  | ) |  |  | 
      
 
Default Constructor. 
Definition at line 74 of file InDetRecStatisticsAlg.cxx.
  118           "Measurement updator to calculate unbiased track states");
 
  120           "Tool to calculate residuals and pulls");
 
 
 
 
◆ calculatePull()
  
  | 
        
          | float InDet::InDetRecStatisticsAlg::calculatePull | ( | const float | residual, |  
          |  |  | const float | trkErr, |  
          |  |  | const float | hitErr |  
          |  | ) |  |  |  | staticprivate | 
 
Calculate pull from residual, track and hit error. 
Definition at line 771 of file InDetRecStatisticsAlg.cxx.
  775   ErrorSum = sqrt(
pow(trkErr, 2) + 
pow(hitErr, 2));
 
  776   if (ErrorSum != 0) { 
return residual/ErrorSum; }
 
 
 
 
◆ cardinality()
Cardinality (Maximum number of clones that can exist) special value 0 means that algorithm is reentrant. 
Override this to return 0 for reentrant algorithms. 
Override this to return 0 for reentrant algorithms. 
Definition at line 75 of file AthCommonReentrantAlgorithm.cxx.
 
 
◆ declareGaudiProperty() [1/4]
specialization for handling Gaudi::Property<SG::VarHandleKeyArray> 
Definition at line 170 of file AthCommonDataStore.h.
  175                                                        hndl.documentation());
 
 
 
 
◆ declareGaudiProperty() [2/4]
specialization for handling Gaudi::Property<SG::VarHandleKey> 
Definition at line 156 of file AthCommonDataStore.h.
  161                                                        hndl.documentation());
 
 
 
 
◆ declareGaudiProperty() [3/4]
specialization for handling Gaudi::Property<SG::VarHandleBase> 
Definition at line 184 of file AthCommonDataStore.h.
  189                                                        hndl.documentation());
 
 
 
 
◆ declareGaudiProperty() [4/4]
◆ declareProperty() [1/6]
Declare a new Gaudi property. 
- Parameters
- 
  
    | name | Name of the property. |  | hndl | Object holding the property value. |  | doc | Documentation 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.
  250     this->declare(hndl.
vhKey());
 
  251     hndl.
vhKey().setOwner(
this);
 
 
 
 
◆ declareProperty() [2/6]
Declare a new Gaudi property. 
- Parameters
- 
  
    | name | Name of the property. |  | hndl | Object holding the property value. |  | doc | Documentation 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.
 
 
◆ declareProperty() [3/6]
◆ declareProperty() [4/6]
Declare a new Gaudi property. 
- Parameters
- 
  
    | name | Name of the property. |  | property | Object holding the property value. |  | doc | Documentation 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.
 
 
◆ declareProperty() [5/6]
Declare a new Gaudi property. 
- Parameters
- 
  
    | name | Name of the property. |  | property | Object holding the property value. |  | doc | Documentation 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.
 
 
◆ declareProperty() [6/6]
◆ detStore()
◆ evtStore() [1/2]
◆ evtStore() [2/2]
◆ execute()
      
        
          | StatusCode InDet::InDetRecStatisticsAlg::execute | ( | const EventContext & | ctx | ) | const | 
      
 
Calculation of statistics. 
Definition at line 265 of file InDetRecStatisticsAlg.cxx.
  278         return StatusCode::SUCCESS;
 
  291     std::vector <std::pair<HepMC::ConstGenParticlePtr,int> > GenSignal;
 
  293     unsigned int inTimeStart = 0;
 
  294     unsigned int inTimeEnd   = 0;
 
  301       ATH_MSG_ERROR(
"No reco track collection specified! Aborting.");
 
  302       return StatusCode::FAILURE;
 
  306     std::vector< SG::ReadHandle<TrackTruthCollection> > truth_track_collections;
 
  309       if (truth_track_collections.size() != rec_track_collections.size()) {
 
  310         ATH_MSG_ERROR(
"Different number of reco and truth track collections (" << rec_track_collections.size() << 
"!=" << truth_track_collections.size() << 
")" );
 
  314         ATH_MSG_ERROR(
"Number expected reco track collections does not match the actual number of such collections (" 
  315                       << 
m_SignalCounters.size() << 
"!=" << rec_track_collections.size() << 
")" );
 
  318     std::vector< SG::ReadHandle<TrackCollection> >
::iterator rec_track_collections_iter = rec_track_collections.begin();
 
  319     std::vector< SG::ReadHandle<TrackTruthCollection> >
::iterator truth_track_collections_iter = truth_track_collections.begin();
 
  320     for (std::vector <class TrackStatHelper *>::const_iterator statHelper
 
  323          ++statHelper, ++rec_track_collections_iter) {
 
  324       assert( rec_track_collections_iter != rec_track_collections.end());
 
  327       const TrackCollection       * RecCollection = &(**rec_track_collections_iter);
 
  330       if (RecCollection)  
ATH_MSG_DEBUG(
"Retrieved " << RecCollection->
size() << 
" reconstructed tracks from storegate");
 
  334         assert( truth_track_collections_iter != truth_track_collections.end());
 
  335         TruthMap = &(**truth_track_collections_iter);
 
  336         if (TruthMap)   
ATH_MSG_DEBUG(
"Retrieved " << TruthMap->size() << 
" TrackTruth elements from storegate");
 
  337         ++truth_track_collections_iter;
 
  342       std::vector <const Trk::Track *>          RecTracks, RecSignal;
 
  346             "  RecTracks.size()="          << RecTracks.size()
 
  347             << 
", GenSignal.size()="          << GenSignal.size());
 
  350       (*statHelper)->addEvent    (RecCollection,
 
  365          it < RecCollection->
end(); ++ 
it){
 
  366     std::vector<const Trk::RIO_OnTrack*> rioOnTracks;
 
  368                      (*it)->measurementsOnTrack()->stdcont() );
 
  376     return StatusCode::SUCCESS;
 
 
 
 
◆ extraDeps_update_handler()
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()
Return the list of extra output dependencies. 
This list is extended to include symlinks implied by inheritance relations. 
Definition at line 94 of file AthCommonReentrantAlgorithm.cxx.
 
 
◆ filterPassed()
◆ finalize()
      
        
          | StatusCode InDet::InDetRecStatisticsAlg::finalize | ( |  | ) |  | 
      
 
Statistics table printed, collection cleared. 
Definition at line 382 of file InDetRecStatisticsAlg.cxx.
  389   for (std::vector <class TrackStatHelper *>::const_iterator collection =
 
  393     delete (*collection);
 
  396   return StatusCode::SUCCESS;
 
 
 
 
◆ getIdentifier()
◆ getServices()
      
        
          | StatusCode InDet::InDetRecStatisticsAlg::getServices | ( |  | ) |  | 
      
 
Get various services such as StoreGate, dictionaries, detector managers etc. 
Definition at line 400 of file InDetRecStatisticsAlg.cxx.
  407     if (
sc.isFailure()) {
 
  409       return StatusCode::FAILURE;
 
  414     if (
sc.isFailure()) {
 
  416       return StatusCode::FAILURE;
 
  423      return StatusCode::FAILURE;
 
  427      return StatusCode::FAILURE;
 
  432    if (
sc.isFailure()) {
 
  434      return StatusCode::FAILURE;
 
  439      return StatusCode::FAILURE;
 
  443    if (dict->
file_name().find(
"SLHC")!=std::string::npos) isSLHC=
true;
 
  448        return StatusCode::FAILURE;
 
  457        return StatusCode::FAILURE;
 
  469        return StatusCode::FAILURE;
 
  481        return StatusCode::FAILURE;
 
  488    return StatusCode :: SUCCESS;
 
 
 
 
◆ getUnbiasedTrackParameters()
Get Unbiased Track Parameters. 
Definition at line 780 of file InDetRecStatisticsAlg.cxx.
  793     if ( trkParameters->covariance() ) {
 
  796       unbiasedTrkParameters =
 
  801       if (!unbiasedTrkParameters) {
 
  803         <<
"use normal parameters");
 
  809       <<
"Unbiased track states can not be calculated " 
  810       <<
"(ie. pulls and residuals will be too small)");
 
  817   return unbiasedTrkParameters;
 
 
 
 
◆ initialize()
      
        
          | StatusCode InDet::InDetRecStatisticsAlg::initialize | ( |  | ) |  | 
      
 
Initialization of services, track collections, creates TrackStatHelper for each Track Collection. 
Definition at line 156 of file InDetRecStatisticsAlg.cxx.
  162   if (sc1.isFailure()) {
 
  164     return StatusCode::FAILURE;
 
  168     ATH_MSG_ERROR(
"No reco track collection specified! Aborting.");
 
  169     return StatusCode::FAILURE;
 
  176           << 
" TrackTruthCollection keys." 
  177           << 
" You have to specify one TrackTruthCollection for each" 
  178           << 
" TrackCollection! Exiting." 
  180     return StatusCode::FAILURE;
 
  187       ATH_MSG_FATAL(
"Could not retrieve measurement updator tool: " 
  189       return StatusCode::FAILURE;
 
  194       "No Updator for unbiased track states given, use normal states!");
 
  202       "No residual/pull calculator for general hit residuals configured." 
  205       "It is recommended to give R/P calculators to the det-specific tool" 
  206     << 
" handle lists then.");
 
  209     <<
" (to calculate residuals and pulls) ");
 
  212     ATH_MSG_INFO(
"Generic hit residuals&pulls will be calculated in one or both " 
  213          << 
"available local coordinates");
 
  237   unsigned int nCollections = 0;
 
  249   if (sc3.isFailure()) {
 
  251     return StatusCode::FAILURE;
 
  258   return StatusCode :: SUCCESS;
 
 
 
 
◆ inputHandles()
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. 
 
 
◆ isClonable()
◆ msg() [1/2]
◆ msg() [2/2]
◆ msgLvl()
◆ outputHandles()
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. 
 
 
◆ printStatistics()
      
        
          | void InDet::InDetRecStatisticsAlg::printStatistics | ( |  | ) |  | 
      
 
Print tracking statistics calculated with TrackStatHelper. 
Definition at line 583 of file InDetRecStatisticsAlg.cxx.
  586   ATH_MSG_INFO(
" ********** Beginning InDetRecStatistics Statistics Table ***********");
 
  587   ATH_MSG_INFO(
"For documentation see https://twiki.cern.ch/twiki/bin/view/Atlas/InDetRecStatistics");
 
  588   ATH_MSG_INFO(
"(or for guaranteed latest version: http://atlas-sw.cern.ch/cgi-bin/viewcvs-atlas.cgi/offline/InnerDetector/InDetValidation/InDetRecStatistics/doc/mainpage.h?&view=markup )");
 
  589   ATH_MSG_INFO(
" ********************************************************************");
 
  591   std::stringstream outstr;
 
  592   int def_precision(outstr.precision());
 
  595      << std::setiosflags(std::ios::fixed | std::ios::showpoint)
 
  596      << std::setw(7) << std::setprecision(2)
 
  603      << 
" truth particles" << 
"\n" 
  605      << 
" tracks without perigee, " 
  607          << 
"\t" << 
"Reco  TrackCollections : ";
 
  609   for (std::vector <class TrackStatHelper *>::const_iterator collection =
 
  619       outstr << 
"\"" << (*collection)->key() << 
"\"";
 
  628              << 
"\t" << 
"TrackTruthCollections  : ";
 
  630       for (std::vector <class TrackStatHelper *>::const_iterator collection =  
m_SignalCounters.begin();
 
  639       outstr << 
"\"" << (*collection)->Truthkey() << 
"\"";
 
  646       << s_linestr2 << 
"\n" 
  647       << 
"Cuts and Settings for Statistics Table" << 
"\n" 
  648       << 
"\t" << 
"TrackSummary Statistics" << 
"\t" 
  650       << 
"\t" << 
"Signal                \t" << 
"pT > " 
  652       << 
"\t" << 
"Primary track start   \t" << 
"R < " 
  655       << 
"\t" << 
"Barrel                \t" << 0.0
 
  657       << 
"\t" << 
"Primary track end     \t" << 
"R > " 
  662       << 
"\t" << 
"Secondary (non-Primary) start \t" 
  667       << 
"\t" << 
"Secondary (non-primary) end   \t" 
  670           << 
"\t" << 
"Forward                \t" 
  672       << 
"\t" << 
"Low prob tracks #1    \t" << 
"< " 
  675       << 
"\t" << 
"Low prob tracks #2    \t" << 
"< " 
  678       << 
"\t" << 
"No link tracks        \t  Track has no link associated to an HepMC Particle" << 
"\n" 
  679       << 
"\t" << 
"Good reco tracks      \t" << 
"> " 
  686   RestoreStream<MsgStream> restore(
out);
 
  687   out << 
"\n" << s_linestr2 << 
"\n";
 
  693         << s_linestr2 << 
"\n" 
  694         << 
"Detailed Statistics for Hits on Reconstructed tracks, using TrackSummary: (Preselection of tracks as described above.)" << 
"\n" 
  695         << s_linestr2 << 
"\n" 
  696         << 
"----------------------------------------------------------------------------------------------------------------------------------------------------" << 
"\n" 
  697         << 
"  Reco Tracks                           .........................................hits/track.......................................................  " << 
"\n" 
  698         << 
"----------------------------------------------------------------------------------------------------------------------------------------------------" << 
"\n" 
  699         << 
"  in BARREL                tracks/event " << track_stummary_type_header << 
"\n" 
  700         << 
"----------------------------------------------------------------------------------------------------------------------------------------------------" << 
"\n";
 
  704        << 
"----------------------------------------------------------------------------------------------------------------------------------------------------" << 
"\n" 
  705        << 
"  in TRANSITION region     tracks/event  " << track_stummary_type_header << 
"\n" 
  706        << 
"----------------------------------------------------------------------------------------------------------------------------------------------------" 
  711         << 
"----------------------------------------------------------------------------------------------------------------------------------------------------" << 
"\n" 
  712         << 
"  in ENDCAP                tracks/event " << track_stummary_type_header << 
"\n" 
  713         << 
"----------------------------------------------------------------------------------------------------------------------------------------------------" << 
"\n";
 
  717         << 
"----------------------------------------------------------------------------------------------------------------------------------------------------" << 
"\n" 
  718         << 
"  in FORWARD region        tracks/event  " << track_stummary_type_header << 
"\n" 
  719         << 
"----------------------------------------------------------------------------------------------------------------------------------------------------" << 
"\n";
 
  725     outstr << 
"\n" << std::setprecision(def_precision)
 
  727            <<
"Statistics for Secondaries (non-Primaries)"<<
"\n" 
  728            << 
"\t" << 
"Secondary track start \t" 
  731            << 
"\t" << 
"Secondary track end   \t" 
  736     out << 
"\n" << s_linestr2 << 
"\n";
 
  743   ATH_MSG_INFO(
" ********** Ending InDetRecStatistics Statistics Table ***********");
 
 
 
 
◆ printTrackSummary()
      
        
          | void InDet::InDetRecStatisticsAlg::printTrackSummary | ( | MsgStream & | out, | 
        
          |  |  | enum eta_region | eta_reg | 
        
          |  | ) |  |  | 
      
 
Print track statistics for all and low proability tracks. 
Definition at line 749 of file InDetRecStatisticsAlg.cxx.
  755          << 
"----------------------------------------------------------------------------------------------------------------------------------------------" << 
"\n";
 
  761          << 
"----------------------------------------------------------------------------------------------------------------------------------------------" << 
"\n";
 
 
 
 
◆ renounce()
◆ renounceArray()
◆ resetStatistics()
      
        
          | StatusCode InDet::InDetRecStatisticsAlg::resetStatistics | ( |  | ) |  | 
      
 
Clear statistics counters, called before each track collection is processed. 
Definition at line 491 of file InDetRecStatisticsAlg.cxx.
  495     for (std::vector<InDet::TrackStatHelper *>::const_iterator 
counter =
 
  500     return StatusCode :: SUCCESS;
 
 
 
 
◆ selectGenSignal()
Select charged,stable particles which pass pt and eta cuts for analysis. 
Classify truth tracks as primary, secondary or truncated 
Definition at line 529 of file InDetRecStatisticsAlg.cxx.
  535   if (! SimTracks) 
return;
 
  537   unsigned int nb_mc_event = SimTracks->
size();
 
  538   std::unique_ptr<PileUpType>  put = std::make_unique<PileUpType>(SimTracks);
 
  549   for(
unsigned int ievt=0; ievt<nb_mc_event; ++ievt)
 
  551       const HepMC::GenEvent* genEvent = SimTracks->
at(ievt);
 
  553       for (
const auto& 
particle: *genEvent){
 
  559       if (std::abs(
charge)<0.5) 
continue;
 
  562         std::pair<HepMC::ConstGenParticlePtr,int> thisPair(
particle,ievt);
 
  563         GenSignal.push_back(thisPair);
 
 
 
 
◆ selectRecSignal()
Select for analysis reconstructed tracks passing Pt and eta cuts. 
Definition at line 503 of file InDetRecStatisticsAlg.cxx.
  509      it != RecCollection->
end(); ++ 
it){
 
  510     RecTracks.push_back(*
it);
 
  512       (*it)->trackParameters();
 
  514     if(!trackpara->
empty()){
 
  518       RecSignal.push_back(*
it);
 
 
 
 
◆ setFilterPassed()
◆ sysExecute()
Execute an algorithm. 
We override this in order to work around an issue with the Algorithm base class storing the event context in a member variable that can cause crashes in MT jobs. 
Definition at line 85 of file AthCommonReentrantAlgorithm.cxx.
 
 
◆ sysInitialize()
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< Gaudi::Algorithm > >.
Reimplemented in InputMakerBase, and HypoBase.
Definition at line 61 of file AthCommonReentrantAlgorithm.cxx.
  110   if (
sc.isFailure()) {
 
  118       if ( cs.retrieve().isFailure() ) {
 
  120         return StatusCode::SUCCESS;
 
  122       if (cs->regHandle(
this,*
h).isFailure()) {
 
  123         sc = StatusCode::FAILURE;
 
  124         ATH_MSG_ERROR(
"unable to register WriteCondHandle " << 
h->fullKey()
 
 
 
 
◆ sysStart()
Handle START transition. 
We override this in order to make sure that conditions handle keys can cache a pointer to the conditions container. 
 
 
◆ updateVHKA()
◆ ATLAS_THREAD_SAFE
  
  | 
        
          | Counter<std::atomic<long> > m_counter InDet::InDetRecStatisticsAlg::ATLAS_THREAD_SAFE |  | mutableprivate | 
 
 
◆ m_detStore
◆ m_doTruth
  
  | 
        
          | bool InDet::InDetRecStatisticsAlg::m_doTruth |  | private | 
 
 
◆ m_events_processed
  
  | 
        
          | std::atomic<long> InDet::InDetRecStatisticsAlg::m_events_processed |  | mutableprivate | 
 
 
◆ m_evtStore
◆ m_extendedExtraObjects
Extra output dependency collection, extended by AthAlgorithmDHUpdate to add symlinks. 
Empty if no symlinks were found. 
Definition at line 114 of file AthCommonReentrantAlgorithm.h.
 
 
◆ m_fakeTrackCut
  
  | 
        
          | float InDet::InDetRecStatisticsAlg::m_fakeTrackCut |  | private | 
 
 
◆ m_fakeTrackCut2
  
  | 
        
          | float InDet::InDetRecStatisticsAlg::m_fakeTrackCut2 |  | private | 
 
Second definition of maximum probability for which a track will be considered a fake. 
Definition at line 123 of file InDetRecStatisticsAlg.h.
 
 
◆ m_idDictMgr
◆ m_idHelper
◆ m_isUnbiased
  
  | 
        
          | std::atomic<int> InDet::InDetRecStatisticsAlg::m_isUnbiased |  | mutableprivate | 
 
 
◆ m_matchTrackCut
  
  | 
        
          | float InDet::InDetRecStatisticsAlg::m_matchTrackCut |  | private | 
 
Minimum number of hits from a truth track to be considered a matched reco track. 
Definition at line 124 of file InDetRecStatisticsAlg.h.
 
 
◆ m_maxEta
  
  | 
        
          | float InDet::InDetRecStatisticsAlg::m_maxEta |  | private | 
 
 
◆ m_maxEtaBarrel
  
  | 
        
          | float InDet::InDetRecStatisticsAlg::m_maxEtaBarrel |  | private | 
 
 
◆ m_maxEtaEndcap
  
  | 
        
          | float InDet::InDetRecStatisticsAlg::m_maxEtaEndcap |  | private | 
 
 
◆ m_maxEtaFORWARD
  
  | 
        
          | float InDet::InDetRecStatisticsAlg::m_maxEtaFORWARD |  | private | 
 
 
◆ m_maxEtaTransition
  
  | 
        
          | float InDet::InDetRecStatisticsAlg::m_maxEtaTransition |  | private | 
 
 
◆ m_maxRStartPrimary
  
  | 
        
          | float InDet::InDetRecStatisticsAlg::m_maxRStartPrimary |  | private | 
 
 
◆ m_maxRStartSecondary
  
  | 
        
          | float InDet::InDetRecStatisticsAlg::m_maxRStartSecondary |  | private | 
 
 
◆ m_maxZStartPrimary
  
  | 
        
          | float InDet::InDetRecStatisticsAlg::m_maxZStartPrimary |  | private | 
 
 
◆ m_maxZStartSecondary
  
  | 
        
          | float InDet::InDetRecStatisticsAlg::m_maxZStartSecondary |  | private | 
 
 
◆ m_McTrackCollection_key
◆ m_minEtaFORWARD
  
  | 
        
          | float InDet::InDetRecStatisticsAlg::m_minEtaFORWARD |  | private | 
 
 
◆ m_minPt
  
  | 
        
          | float InDet::InDetRecStatisticsAlg::m_minPt |  | private | 
 
 
◆ m_minREndPrimary
  
  | 
        
          | float InDet::InDetRecStatisticsAlg::m_minREndPrimary |  | private | 
 
If track has end vertex, this is min R of end vertex to be considered primary. 
Definition at line 130 of file InDetRecStatisticsAlg.h.
 
 
◆ m_minREndSecondary
  
  | 
        
          | float InDet::InDetRecStatisticsAlg::m_minREndSecondary |  | private | 
 
If track has end vertex, this is min R of end vertex to be considered secondary. 
Definition at line 131 of file InDetRecStatisticsAlg.h.
 
 
◆ m_minZEndPrimary
  
  | 
        
          | float InDet::InDetRecStatisticsAlg::m_minZEndPrimary |  | private | 
 
If track has end vertex, this is min Z of end vertex to be considered primary. 
Definition at line 132 of file InDetRecStatisticsAlg.h.
 
 
◆ m_minZEndSecondary
  
  | 
        
          | float InDet::InDetRecStatisticsAlg::m_minZEndSecondary |  | private | 
 
If track has end vertex, this is min Z of end vertex to be considered secondary. 
Definition at line 133 of file InDetRecStatisticsAlg.h.
 
 
◆ m_pixelID
◆ m_printSecondary
  
  | 
        
          | bool InDet::InDetRecStatisticsAlg::m_printSecondary |  | private | 
 
 
◆ m_pullWarning
  
  | 
        
          | std::atomic<bool> InDet::InDetRecStatisticsAlg::m_pullWarning {} |  | mutableprivate | 
 
 
◆ m_RecTrackCollection_keys
◆ m_residualPullCalculator
◆ m_sctID
◆ m_SignalCounters
  
  | 
        
          | std::vector<class TrackStatHelper *> InDet::InDetRecStatisticsAlg::m_SignalCounters |  | private | 
 
 
◆ m_trackSelectorTool
◆ m_TrackTruthCollection_keys
◆ m_trkSummaryTool
◆ m_trtID
◆ m_truthToTrack
◆ m_updator
◆ m_updatorHandle
  
  | 
        
          | ToolHandle<Trk::IUpdator> InDet::InDetRecStatisticsAlg::m_updatorHandle |  | private | 
 
 
◆ m_UpdatorWarning
  
  | 
        
          | std::atomic<bool> InDet::InDetRecStatisticsAlg::m_UpdatorWarning {} |  | mutableprivate | 
 
 
◆ m_useTrackSelection
  
  | 
        
          | bool InDet::InDetRecStatisticsAlg::m_useTrackSelection |  | private | 
 
 
◆ m_UseTrackSummary
  
  | 
        
          | bool InDet::InDetRecStatisticsAlg::m_UseTrackSummary |  | private | 
 
 
◆ m_varHandleArraysDeclared
◆ m_vhka
The documentation for this class was generated from the following files:
 
def retrieve(aClass, aKey=None)
JetConstituentVector::iterator iterator
Counter< int > CounterLocal
const PixelID * m_pixelID
get pixel layer from hit ID
const AtlasDetectorID * m_idHelper
Used to find out the sub-det from PRD->identify().
Const iterator class for DataVector/DataList.
constexpr ParticleHypothesis particle[PARTICLEHYPOTHESES]
the array of masses
@ kN_rec_tracks_processed
number of reconstructed tracks processed
static std::string getSummaryTypeHeader()
bool isNucleus(const T &p)
PDG rule 16 Nuclear codes are given as 10-digit numbers ±10LZZZAAAI.
std::atomic< bool > m_pullWarning
warn only once, if pull cannot be calculated
float m_minZEndSecondary
If track has end vertex, this is min Z of end vertex to be considered secondary.
ToolHandle< Trk::IResidualPullCalculator > m_residualPullCalculator
The residual and pull calculator tool handle.
ToolHandle< Trk::IExtendedTrackSummaryTool > m_trkSummaryTool
tool to get track summary information from track
StatusCode resetStatistics()
Clear statistics counters, called before each track collection is processed.
float m_maxRStartPrimary
Maximum R of start vertex to be considered primary.
const TRT_ID * m_trtID
get trt layer from hit ID
StatusCode getServices()
Get various services such as StoreGate, dictionaries, detector managers etc.
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)
std::atomic< bool > m_UpdatorWarning
warn only once, if unbiased track states can not be calculated
void selectGenSignal(const McEventCollection *, std::vector< std::pair< HepMC::ConstGenParticlePtr, int > > &, unsigned int, unsigned int, CounterLocal &counter) const
Select charged,stable particles which pass pt and eta cuts for analysis.
StoreGateSvc_t m_evtStore
Pointer to StoreGate (event store by default)
std::vector< SG::VarHandleKeyArray * > m_vhka
bool msgLvl(const MSG::Level lvl) const
@ kN_rec_tracks_without_perigee
number of tracks w/o perigee
float m_minREndSecondary
If track has end vertex, this is min R of end vertex to be considered secondary.
#define ATH_MSG_VERBOSE(x)
const std::string & key() const
Return the StoreGate ID for the referenced object.
bool m_UseTrackSummary
Flag to print detailed statistics for each track collection.
const std::string & file_name() const
Access to file name.
void printTrackSummary(MsgStream &out, enum eta_region)
Print track statistics for all and low proability tracks.
bool m_useTrackSelection
Use track selector tool.
const ServiceHandle< StoreGateSvc > & detStore() const
The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.
virtual void setOwner(IDataHandleHolder *o)=0
An algorithm that can be simultaneously executed in multiple threads.
SG::ReadHandleKey< McEventCollection > m_McTrackCollection_key
void SetCuts(const struct cuts &)
Sets the cuts such as the eta regions (barrel, transition,endcap) and the hit fraction fake cuts and ...
void printStatistics()
Print tracking statistics calculated with TrackStatHelper.
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T, V, H > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>
virtual const DataObjIDColl & extraOutputDeps() const override
Return the list of extra output dependencies.
virtual const RIO_OnTrack & rioOnTrack(unsigned int) const =0
returns the RIO_OnTrack (also known as ROT) objects depending on the integer.
IdDictDictionary * find_dictionary(const std::string &name) const
Access dictionary by name.
virtual std::unique_ptr< TrackParameters > removeFromState(const TrackParameters &, const Amg::Vector2D &, const Amg::MatrixX &) const =0
the reverse updating or inverse KalmanFilter removes a measurement from the track state,...
virtual std::vector< Gaudi::DataHandle * > outputHandles() const override
Return this algorithm's output handles.
bool m_printSecondary
Flag to print hit information for secondary tracks.
::StatusCode StatusCode
StatusCode definition for legacy code.
ToolHandle< Trk::IUpdator > m_updatorHandle
Tool handle of updator for unbiased states.
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T, V, H > &t)
virtual StatusCode sysExecute(const EventContext &ctx) override
Execute an algorithm.
std::atomic< long > m_events_processed
number of events processed
const SCT_ID * m_sctID
get sct layer from hit ID
Base class for all CompetingRIOsOnTack implementations, extends the common MeasurementBase.
const T * front() const
Access the first element in the collection as an rvalue.
ToolHandle< Trk::ITruthToTrack > m_truthToTrack
tool to create track parameters from a gen particle
std::vector< class TrackStatHelper * > m_SignalCounters
Vector of TrackStatHelper objects, one for each track collection.
float m_maxEta
Maximum Eta cut for tracks used by the algorithm.
StoreGateSvc_t m_detStore
Pointer to StoreGate (detector store by default)
StatusCode initialize(bool used=true)
If this object is used as a property, then this should be called during the initialize phase.
float m_matchTrackCut
Minimum number of hits from a truth track to be considered a matched reco track.
Trk::IUpdator * m_updator
updator for unbiased states
virtual bool isValid() override final
Can the handle be successfully dereferenced?
McEventCollection::const_iterator in_time_minimum_bias_event_begin() const
extract the in-time minimum bias McEvent Particles from the McEventCollection A pair of iterators is ...
const Amg::MatrixX & localCovariance() const
Interface method to get the localError.
virtual void renounce()=0
std::conditional< std::is_base_of< SG::VarHandleKeyArray, T >::value, VarHandleKeyArrayType, type2 >::type type
float m_maxEtaTransition
define max eta of transition region
double pT() const
Access method for transverse momentum.
float m_minPt
Minimum Pt cut for tracks used by the algorithm.
ToolHandle< Trk::ITrackSelectorTool > m_trackSelectorTool
@ kN_gen_tracks_processed
number of generated tracks processed
IdDictManager is the interface to identifier dictionaries.
double charge(const T &p)
const IdDictManager * m_idDictMgr
const LocalParameters & localParameters() const
Interface method to get the LocalParameters.
const_iterator end() const noexcept
Return a const_iterator pointing past the end of the collection.
bool isStable(const T &p)
Identify if the particle is stable, i.e. has not decayed.
float m_fakeTrackCut2
Second definition of maximum probability for which a track will be considered a fake.
float m_minZEndPrimary
If track has end vertex, this is min Z of end vertex to be considered primary.
#define ATH_MSG_WARNING(x)
float m_maxRStartSecondary
Maximum R of start vertex to be considered secondary.
McEventCollection::const_iterator in_time_minimum_bias_event_end() const
float m_maxZStartSecondary
Maximum Z of start vertex to be considered secondary.
float m_maxEtaEndcap
define max eta of eta region
Identifier identify() const
return the identifier -extends MeasurementBase
const IdDictMgr * manager(void) const
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
SG::ReadHandleKeyArray< TrackTruthCollection > m_TrackTruthCollection_keys
virtual StatusCode sysInitialize() override
Override sysInitialize.
double eta() const
Access method for pseudorapidity - from momentum.
bool m_doTruth
Use truth information.
std::atomic< int > m_isUnbiased
if can get unbiased residuals
float m_maxZStartPrimary
Maximum Z of start vertex to be considered primary.
float m_fakeTrackCut
Maximum probability for which a track will be considered a fake.
float m_maxEtaBarrel
define max eta of barrel region
const T * at(size_type n) const
Access an element, as an rvalue.
unsigned int indexOfMaxAssignProb() const
Index of the ROT with the highest assignment probability.
DataObjIDColl m_extendedExtraObjects
Extra output dependency collection, extended by AthAlgorithmDHUpdate to add symlinks.
constexpr int pow(int base, int exp) noexcept
@ kN_unknown_hits
number of hits without track
SG::ReadHandleKeyArray< TrackCollection > m_RecTrackCollection_keys
size_type size() const noexcept
Returns the number of elements in the collection.
float m_minREndPrimary
If track has end vertex, this is min R of end vertex to be considered primary.
bool empty() const noexcept
Returns true if the collection is empty.
@ kN_spacepoints_processed
number of space points processed
const_iterator begin() const noexcept
Return a const_iterator pointing at the beginning of the collection.
void selectRecSignal(const TrackCollection *, std::vector< const Trk::Track * > &, std::vector< const Trk::Track * > &, CounterLocal &counter) const
Select for analysis reconstructed tracks passing Pt and eta cuts.