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

Generated the decision for hypo thats triggers on high pt isolated tracks. More...

#include <TrigIsoHPtTrackTriggerHypoTool.h>

Inheritance diagram for TrigIsoHPtTrackTriggerHypoTool:
Collaboration diagram for TrigIsoHPtTrackTriggerHypoTool:

Classes

struct  TrackInfo
 

Public Member Functions

 TrigIsoHPtTrackTriggerHypoTool (const std::string &type, const std::string &name, const IInterface *parent)
 
virtual ~TrigIsoHPtTrackTriggerHypoTool ()
 
virtual StatusCode initialize () override
 
StatusCode decide (std::vector< TrackInfo > &decisions) const
 decides upon a collection of tracks More...
 
bool decideOnSingleObject (const xAOD::TrackParticle_v1 *track, const xAOD::TrackParticleContainer *AllTracks, size_t cutIndex) const
 Auxiluary method, single track selection. More...
 
StatusCode inclusiveSelection (std::vector< TrackInfo > &input) const
 actual implementation of decide, in case of inclusive selection ( one object cut ) More...
 
StatusCode multiplicitySelection (std::vector< TrackInfo > &input) const
 actual implementation of decide, in case of multiple objects selection ( independentone ) More...
 
StatusCode markPassing (std::vector< TrackInfo > &input, const std::set< size_t > &passing) const
 stores decisions for all object passing multiple cuts The passsingSelection inner vectors have to have size == input size 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
 

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

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

HLT::Identifier m_decisionId
 
Gaudi::Property< std::vector< float > > m_TrackPt { this, "MinTrackPt", { float( 50.0*Gaudi::Units::GeV ) }, "Track pT requirement" }
 
Gaudi::Property< std::vector< float > > m_TrackEta { this, "MinTrackEta", { float(2.5 ) }, "Track Eta requirement" }
 
Gaudi::Property< std::vector< float > > m_Trackd0 { this, "MaxTrackd0", {5.}, "Maximum Track d0 allowed" }
 
Gaudi::Property< std::vector< float > > m_Trackd0Sig { this, "MaxTrackd0Sig", {5.}, "Maximum Track d0 Sig allowed" }
 
Gaudi::Property< std::vector< unsigned > > m_TrackNPixHits { this, "MinTrackNPixHits", {2}, "Minimum number of pixel hits required from the trigger" }
 
Gaudi::Property< std::vector< unsigned > > m_TrackNSCTHits { this, "MinTrackNSCTHits", {5}, "Minimum number of SCT hits required from the trigger" }
 
Gaudi::Property< std::vector< bool > > m_doIso { this, "EnableTrackIsolation", {false}, "If track based isolation should be applied or not? "}
 
Gaudi::Property< std::vector< bool > > m_IsoCum { this, "EnableCumalitiveIsolation", {false}, "Instead of checking if one track is above a certain pT threshold, add up all tracks for isolation"}
 
Gaudi::Property< std::vector< float > > m_IsoDR { this, "TrackIsoCone", {0.3}, "Isolation requirment over the main track" }
 
Gaudi::Property< std::vector< float > > m_IsoPt { this, "MinIsoTrackPt", {float( 5.0*Gaudi::Units::GeV )}, "Min pT requirment of other tracks to be considered for isolation" }
 
size_t m_multiplicity = 1
 
ToolHandle< GenericMonitoringToolm_monTool { this, "MonTool", "", "Monitoring tool" }
 
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

Generated the decision for hypo thats triggers on high pt isolated tracks.

Author
Ismet Siral ismet.nosp@m..sir.nosp@m.al@ce.nosp@m.rn.c.nosp@m.h - University of Oregon

Definition at line 23 of file TrigIsoHPtTrackTriggerHypoTool.h.

Member Typedef Documentation

◆ StoreGateSvc_t

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

Definition at line 388 of file AthCommonDataStore.h.

Constructor & Destructor Documentation

◆ TrigIsoHPtTrackTriggerHypoTool()

TrigIsoHPtTrackTriggerHypoTool::TrigIsoHPtTrackTriggerHypoTool ( const std::string &  type,
const std::string &  name,
const IInterface *  parent 
)

◆ ~TrigIsoHPtTrackTriggerHypoTool()

TrigIsoHPtTrackTriggerHypoTool::~TrigIsoHPtTrackTriggerHypoTool ( )
virtual

Definition at line 56 of file TrigIsoHPtTrackTriggerHypoTool.cxx.

56 {}

Member Function Documentation

◆ decide()

StatusCode TrigIsoHPtTrackTriggerHypoTool::decide ( std::vector< TrackInfo > &  decisions) const

decides upon a collection of tracks

Definition at line 283 of file TrigIsoHPtTrackTriggerHypoTool.cxx.

283  {
284  // handle the simplest and most common case ( multiplicity == 1 ) in easiest possible manner
285  if ( m_TrackPt.size() == 1 ) {
286  return inclusiveSelection( input );
287 
288  } else {
289  return multiplicitySelection( input );
290  }
291 
292  return StatusCode::SUCCESS;
293 }

◆ decideOnSingleObject()

bool TrigIsoHPtTrackTriggerHypoTool::decideOnSingleObject ( const xAOD::TrackParticle_v1 track,
const xAOD::TrackParticleContainer AllTracks,
size_t  cutIndex 
) const

Auxiluary method, single track selection.

Definition at line 58 of file TrigIsoHPtTrackTriggerHypoTool.cxx.

58  {
59  auto cutCounter = Monitored::Scalar<int>( "CutCounter", -1 );
60  auto cutIndexM = Monitored::Scalar<int>( "CutIndex", cutIndex ); // one can do 2D plots for each cut independently
61 
62  auto MONtrackPt = Monitored::Scalar( "trackPt", -999. );
63  auto MONtrackd0 = Monitored::Scalar( "trackd0", -999. );
64  auto MONtrackNPixHits = Monitored::Scalar( "trackNPixHits", -999. );
65  auto MONtrackNSCTHits = Monitored::Scalar( "trackNSCTHits", -999. );
66  auto MONtrackd0Sig = Monitored::Scalar( "trackd0Sig", -999. );
67  auto MONtrackEta = Monitored::Scalar( "trackEta", -999. );
68  auto MONtrackIsoPt = Monitored::Scalar( "trackIsoPt", -999. );
69  auto MONtrackAggrIsoPt = Monitored::Scalar( "trackAggrIsoPt", -999. );
70  auto monitorIt = Monitored::Group( m_monTool, cutCounter, cutIndexM,
71  MONtrackPt, MONtrackEta,
72  MONtrackd0, MONtrackd0Sig,
73  MONtrackNPixHits, MONtrackNSCTHits,
74  MONtrackIsoPt, MONtrackAggrIsoPt
75  );
76 
77 
78 
79 
80  //Checking Track pT Requirments
81  auto trackPt= (track)->pt();
82  if( trackPt < m_TrackPt[cutIndex] ) { // Check track pT requirments
83  ATH_MSG_DEBUG( "Fails pt cut" << trackPt << " < " << m_TrackPt[cutIndex] );
84  return false;
85 
86  }
87  cutCounter++;
88 
89 
90  //Checking Track Eta Requirments
91  auto trackEta=std::abs( (track)->p4().Eta() );
92  if( trackEta > m_TrackEta[cutIndex] ) { // Check track pT requirments
93  ATH_MSG_DEBUG( "Fails Eta cut" << trackEta << " > " << m_TrackEta[cutIndex] );
94  return false;
95 
96  }
97  cutCounter++;
98 
99 
100 
101  //Checking Track d0 Requirments
102  auto trackd0= std::abs((track)->d0());
103  if( trackd0 > m_Trackd0[cutIndex]) {
104  ATH_MSG_DEBUG( "Fails d0 cut" << trackd0 << " > " << m_Trackd0[cutIndex] );
105  return false;
106 
107  }
108  cutCounter++;
109 
110 
111  //Checking Track d0 Sig Requirments
112  auto trackd0Sig= std::abs(xAOD::TrackingHelpers::d0significance(track));
113  if( trackd0Sig > m_Trackd0Sig[cutIndex]) {
114  ATH_MSG_DEBUG( "Fails d0 Sig cut" << trackd0Sig << " > " << m_Trackd0Sig[cutIndex] );
115  return false;
116 
117  }
118  cutCounter++;
119 
120 
121  //Attempt to read track summary, and save info on number of pixels
122  uint8_t trackNPixHits=0;
123  if ( ! (track)->summaryValue(trackNPixHits,xAOD::numberOfPixelHits )) { // Cannot obtain the track summary
124  ATH_MSG_DEBUG( "Failed to retrieve pedigree parameters");
125  return false;
126  }
127  ATH_MSG_DEBUG( "Succesfully retrieved pedigree parameters");
128  cutCounter++;
129  //Attempt to read track summary, and save info on number of SCT hits
130  uint8_t trackNSCTHits=0;
131  if ( ! (track)->summaryValue(trackNSCTHits,xAOD::numberOfSCTHits )) { // Cannot obtain the track summary
132  ATH_MSG_DEBUG( "Failed to retrieve pedigree parameters");
133  return false;
134  }
135  ATH_MSG_DEBUG( "Succesfully retrieved pedigree parameters");
136  cutCounter++;
137 
138 
139 
140  //Checking Track Min number of Pix Hits Requirments
141  if( trackNPixHits <= m_TrackNPixHits[cutIndex] ){
142 
143  ATH_MSG_DEBUG( "Fails numperOfPixelHits cut" << trackNPixHits << " <= " << m_TrackNPixHits[cutIndex] );
144  return false;
145  }
146  cutCounter++;
147 
148 
149  //Checking Track Min number of SCT Hits Requirments
150  if( trackNSCTHits <= m_TrackNSCTHits[cutIndex] ){
151 
152  ATH_MSG_DEBUG( "Fails numperOfSCTHits cut" << trackNSCTHits << " <= " << m_TrackNSCTHits[cutIndex] );
153  return false;
154  }
155  cutCounter++;
156 
157 
158  //Definning a cumlative pT variable that adds up the momentum of all tracks
159 
160  //If isolation is applied, loop over all tracks, and veto the event if there is a track above a certain threshold in the isolation cone
161  if (m_doIso[cutIndex]) {
162  float CumulativePT = 0.0;
163 
164  for (auto trackIter = AllTracks->begin(); trackIter != AllTracks->end(); ++trackIter){
165 
166  //Skip the track that is out of DR
167  if( (*trackIter)==track) continue;
168  if (track->p4().DeltaR((*trackIter)->p4()) > m_IsoDR[cutIndex] ) continue;
169 
170  //Skip the track that doens't have many Pixel and SCT Hits (Quality Check)
171  uint8_t iterPix=0;
172  if ( ! (*trackIter)->summaryValue(iterPix,xAOD::numberOfPixelHits ))
173  continue;
174  uint8_t iterSCT=0;
175  if ( ! (*trackIter)->summaryValue(iterSCT,xAOD::numberOfSCTHits ))
176  continue;
177 
178  if (iterPix<=m_TrackNPixHits[cutIndex] ) continue;
179  if (iterSCT<=2 ) continue;
180 
181 
182  //If cumalitve, add up the momentum of the track, if it's a bove a certain threshold kill the trac
183 
184  if(m_IsoCum[cutIndex]){
185  CumulativePT+=(*trackIter)->pt();
186  if(CumulativePT>=m_IsoPt[cutIndex]) {
187  MONtrackAggrIsoPt=CumulativePT;
188  ATH_MSG_DEBUG( "Fails Cum Isolation cut" );
189  return false;
190  }
191  }
192  //If not cumlaitve, veto the track only if one track is bigger then the threshold
193  else {
194  if ((*trackIter)->pt() > MONtrackIsoPt ) {
195  MONtrackIsoPt=(*trackIter)->pt();
196  }
197 
198  if( (*trackIter)->pt()>=m_IsoPt[cutIndex] ) {
199  ATH_MSG_DEBUG( "Fails Isolation cut" );
200  return false;
201  }
202  }
203 
204 
205 
206  }
207 
208  MONtrackAggrIsoPt=CumulativePT;
209  cutCounter++;
210  }
211 
212  //Monitorung histograms are filled at the end, only if they pass the selection. (For optimisation studies)
213  MONtrackNPixHits=trackNPixHits;
214  MONtrackNSCTHits=trackNSCTHits;
215  MONtrackPt= trackPt;
216  MONtrackEta= trackEta;
217  MONtrackd0= trackd0;
218  MONtrackd0Sig= trackd0Sig;
219 
220 
221 
222  ATH_MSG_DEBUG( "Passed selection" );
223  return true;
224 
225 }

◆ 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

◆ inclusiveSelection()

StatusCode TrigIsoHPtTrackTriggerHypoTool::inclusiveSelection ( std::vector< TrackInfo > &  input) const

actual implementation of decide, in case of inclusive selection ( one object cut )

Definition at line 227 of file TrigIsoHPtTrackTriggerHypoTool.cxx.

227  {
228  for ( auto i: input ) {
229 
230  if ( i.previousDecisionsIDs.count( m_decisionId.numeric() ) == 0 ) {
231  continue;
232  }
233 
234  auto objDecision = decideOnSingleObject( i.track, i.AllTracks, 0 );
235  if ( objDecision == true ) {
236 
237  addDecisionID( m_decisionId.numeric(), i.decision );
238  }
239  }
240  return StatusCode::SUCCESS;
241 }

◆ initialize()

StatusCode TrigIsoHPtTrackTriggerHypoTool::initialize ( )
overridevirtual

Definition at line 23 of file TrigIsoHPtTrackTriggerHypoTool.cxx.

23  {
24 
25  if ( !m_monTool.empty() ) CHECK( m_monTool.retrieve() );
26 
27  ATH_MSG_VERBOSE( "Initialization completed successfully:" );
28 
29  //Track Trigger Kinematic Requirments
30  ATH_MSG_VERBOSE( "MaxTrackPt = " << m_TrackPt );
31  ATH_MSG_VERBOSE( "MaxTrackEta = " << m_TrackEta );
32  ATH_MSG_VERBOSE( "MaxTrackd0 = " << m_Trackd0 );
33  ATH_MSG_VERBOSE( "MaxTrackd0Sig = " << m_Trackd0Sig );
34  ATH_MSG_VERBOSE( "MinTrackNPixHits = " << m_TrackNPixHits );
35  ATH_MSG_VERBOSE( "MinTrackNSCTHits = " << m_TrackNSCTHits );
36  //Track Trigger Isolation Requirments
37  ATH_MSG_VERBOSE( "TrackIsoCone = " << m_IsoDR );
38  ATH_MSG_VERBOSE( "MinIsoTrackPt = " << m_IsoPt );
39  ATH_MSG_VERBOSE( "EnableTrackIsolation = " << m_doIso );
40  ATH_MSG_VERBOSE( "EnableCumulIsolation = " << m_IsoCum );
41 
42  std::vector<size_t> sizes( {m_TrackPt.size(), m_TrackEta.size(), m_Trackd0.size( ), m_Trackd0Sig.size(), m_TrackNPixHits.size() , m_TrackNSCTHits.size() , m_doIso.size() , m_IsoDR.size() , m_IsoPt.size() } );
43 
44 
45  if ( *std::min_element( sizes.begin(), sizes.end() ) != *std::max_element( sizes.begin(), sizes.end() ) ) {
46  ATH_MSG_ERROR( "Missconfiguration, cut properties listed above ( when INFO ) have different dimensions shortest: " << *std::min_element( sizes.begin(), sizes.end() ) << " longest " << *std::max_element( sizes.begin(), sizes.end() ) );
47  return StatusCode::FAILURE;
48  }
49 
50  ATH_MSG_VERBOSE( "Tool configured for chain/id: " << m_decisionId );
51 
52  return StatusCode::SUCCESS;
53 }

◆ 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.

◆ markPassing()

StatusCode TrigIsoHPtTrackTriggerHypoTool::markPassing ( std::vector< TrackInfo > &  input,
const std::set< size_t > &  passing 
) const

stores decisions for all object passing multiple cuts The passsingSelection inner vectors have to have size == input size

Definition at line 244 of file TrigIsoHPtTrackTriggerHypoTool.cxx.

244  {
245 
246  for ( auto idx: passing )
247  addDecisionID( m_decisionId.numeric(), input[idx].decision );
248  return StatusCode::SUCCESS;
249 
250 }

◆ 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  }

◆ multiplicitySelection()

StatusCode TrigIsoHPtTrackTriggerHypoTool::multiplicitySelection ( std::vector< TrackInfo > &  input) const

actual implementation of decide, in case of multiple objects selection ( independentone )

Definition at line 253 of file TrigIsoHPtTrackTriggerHypoTool.cxx.

253  {
254  HLT::Index2DVec passingSelection( m_multiplicity );
255 
256  for ( size_t cutIndex = 0; cutIndex < m_multiplicity; ++ cutIndex ) {
257  size_t trkIndex{ 0 };
258  for ( auto trkIter = input.begin(); trkIter != input.end(); ++trkIter, ++trkIndex ) {
259 
260  if ( trkIter->previousDecisionsIDs.count( m_decisionId.numeric() ) == 0 ) {
261  continue;
262  }
263 
264  if ( decideOnSingleObject( trkIter->track, trkIter->AllTracks, cutIndex ) ) {
265  passingSelection[cutIndex].push_back( trkIndex );
266 
267  }
268  }
269  // checking if by chance none of the objects passed the single obj selection, if so there will be no valid combination and we can skip
270  if ( passingSelection[cutIndex].empty() ) {
271  ATH_MSG_DEBUG( "No object passed selection " << cutIndex << " rejecting" );
272  return StatusCode::SUCCESS;
273  }
274  }
275 
276  std::set<size_t> passingIndices;
277  HLT::elementsInUniqueCombinations( passingSelection, passingIndices );
278  return markPassing( input, passingIndices );
279 
280 
281 }

◆ 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_decisionId

HLT::Identifier TrigIsoHPtTrackTriggerHypoTool::m_decisionId
private

Definition at line 73 of file TrigIsoHPtTrackTriggerHypoTool.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_doIso

Gaudi::Property< std::vector<bool> > TrigIsoHPtTrackTriggerHypoTool::m_doIso { this, "EnableTrackIsolation", {false}, "If track based isolation should be applied or not? "}
private

Definition at line 82 of file TrigIsoHPtTrackTriggerHypoTool.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_IsoCum

Gaudi::Property< std::vector<bool> > TrigIsoHPtTrackTriggerHypoTool::m_IsoCum { this, "EnableCumalitiveIsolation", {false}, "Instead of checking if one track is above a certain pT threshold, add up all tracks for isolation"}
private

Definition at line 83 of file TrigIsoHPtTrackTriggerHypoTool.h.

◆ m_IsoDR

Gaudi::Property< std::vector<float> > TrigIsoHPtTrackTriggerHypoTool::m_IsoDR { this, "TrackIsoCone", {0.3}, "Isolation requirment over the main track" }
private

Definition at line 84 of file TrigIsoHPtTrackTriggerHypoTool.h.

◆ m_IsoPt

Gaudi::Property< std::vector<float> > TrigIsoHPtTrackTriggerHypoTool::m_IsoPt { this, "MinIsoTrackPt", {float( 5.0*Gaudi::Units::GeV )}, "Min pT requirment of other tracks to be considered for isolation" }
private

Definition at line 85 of file TrigIsoHPtTrackTriggerHypoTool.h.

◆ m_monTool

ToolHandle<GenericMonitoringTool> TrigIsoHPtTrackTriggerHypoTool::m_monTool { this, "MonTool", "", "Monitoring tool" }
private

Definition at line 90 of file TrigIsoHPtTrackTriggerHypoTool.h.

◆ m_multiplicity

size_t TrigIsoHPtTrackTriggerHypoTool::m_multiplicity = 1
private

Definition at line 88 of file TrigIsoHPtTrackTriggerHypoTool.h.

◆ m_Trackd0

Gaudi::Property< std::vector<float> > TrigIsoHPtTrackTriggerHypoTool::m_Trackd0 { this, "MaxTrackd0", {5.}, "Maximum Track d0 allowed" }
private

Definition at line 77 of file TrigIsoHPtTrackTriggerHypoTool.h.

◆ m_Trackd0Sig

Gaudi::Property< std::vector<float> > TrigIsoHPtTrackTriggerHypoTool::m_Trackd0Sig { this, "MaxTrackd0Sig", {5.}, "Maximum Track d0 Sig allowed" }
private

Definition at line 78 of file TrigIsoHPtTrackTriggerHypoTool.h.

◆ m_TrackEta

Gaudi::Property< std::vector<float> > TrigIsoHPtTrackTriggerHypoTool::m_TrackEta { this, "MinTrackEta", { float(2.5 ) }, "Track Eta requirement" }
private

Definition at line 76 of file TrigIsoHPtTrackTriggerHypoTool.h.

◆ m_TrackNPixHits

Gaudi::Property< std::vector<unsigned> > TrigIsoHPtTrackTriggerHypoTool::m_TrackNPixHits { this, "MinTrackNPixHits", {2}, "Minimum number of pixel hits required from the trigger" }
private

Definition at line 79 of file TrigIsoHPtTrackTriggerHypoTool.h.

◆ m_TrackNSCTHits

Gaudi::Property< std::vector<unsigned> > TrigIsoHPtTrackTriggerHypoTool::m_TrackNSCTHits { this, "MinTrackNSCTHits", {5}, "Minimum number of SCT hits required from the trigger" }
private

Definition at line 80 of file TrigIsoHPtTrackTriggerHypoTool.h.

◆ m_TrackPt

Gaudi::Property< std::vector<float> > TrigIsoHPtTrackTriggerHypoTool::m_TrackPt { this, "MinTrackPt", { float( 50.0*Gaudi::Units::GeV ) }, "Track pT requirement" }
private

Definition at line 75 of file TrigIsoHPtTrackTriggerHypoTool.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:
TrigIsoHPtTrackTriggerHypoTool::markPassing
StatusCode markPassing(std::vector< TrackInfo > &input, const std::set< size_t > &passing) const
stores decisions for all object passing multiple cuts The passsingSelection inner vectors have to hav...
Definition: TrigIsoHPtTrackTriggerHypoTool.cxx:244
TrigIsoHPtTrackTriggerHypoTool::m_monTool
ToolHandle< GenericMonitoringTool > m_monTool
Definition: TrigIsoHPtTrackTriggerHypoTool.h:90
TrigIsoHPtTrackTriggerHypoTool::m_Trackd0Sig
Gaudi::Property< std::vector< float > > m_Trackd0Sig
Definition: TrigIsoHPtTrackTriggerHypoTool.h:78
TrigDefs::Group
Group
Properties of a chain group.
Definition: GroupProperties.h:13
xAOD::uint8_t
uint8_t
Definition: Muon_v1.cxx:557
HLT::Identifier::numeric
TrigCompositeUtils::DecisionID numeric() const
numeric ID
Definition: TrigCompositeUtils/TrigCompositeUtils/HLTIdentifier.h:47
AthCommonDataStore::declareProperty
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
Definition: AthCommonDataStore.h:145
TrigCompositeUtils::addDecisionID
void addDecisionID(DecisionID id, Decision *d)
Appends the decision (given as ID) to the decision object.
Definition: TrigCompositeUtilsRoot.cxx:61
xAOD::TrackingHelpers::d0significance
double d0significance(const xAOD::TrackParticle *tp, double d0_uncert_beam_spot_2)
Definition: TrackParticlexAODHelpers.cxx:42
test_pyathena.pt
pt
Definition: test_pyathena.py:11
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_evtStore
StoreGateSvc_t m_evtStore
Pointer to StoreGate (event store by default)
Definition: AthCommonDataStore.h:390
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_vhka
std::vector< SG::VarHandleKeyArray * > m_vhka
Definition: AthCommonDataStore.h:398
xAOD::numberOfPixelHits
@ numberOfPixelHits
these are the pixel hits, including the b-layer [unit8_t].
Definition: TrackingPrimitives.h:259
read_hist_ntuple.t
t
Definition: read_hist_ntuple.py:5
ATH_MSG_VERBOSE
#define ATH_MSG_VERBOSE(x)
Definition: AthMsgStreamMacros.h:28
empty
bool empty(TH1 *h)
Definition: computils.cxx:295
SG::VarHandleKeyArray::setOwner
virtual void setOwner(IDataHandleHolder *o)=0
TrigIsoHPtTrackTriggerHypoTool::m_Trackd0
Gaudi::Property< std::vector< float > > m_Trackd0
Definition: TrigIsoHPtTrackTriggerHypoTool.h:77
HLT::Identifier::fromToolName
static HLT::Identifier fromToolName(const std::string &tname)
Definition: HLTIdentifier.cxx:31
TrigIsoHPtTrackTriggerHypoTool::m_TrackPt
Gaudi::Property< std::vector< float > > m_TrackPt
Definition: TrigIsoHPtTrackTriggerHypoTool.h:75
IDTPMcnv.htype
htype
Definition: IDTPMcnv.py:29
TrigIsoHPtTrackTriggerHypoTool::m_TrackEta
Gaudi::Property< std::vector< float > > m_TrackEta
Definition: TrigIsoHPtTrackTriggerHypoTool.h:76
python.utils.AtlRunQueryDQUtils.p
p
Definition: AtlRunQueryDQUtils.py:210
AthCommonDataStore
Definition: AthCommonDataStore.h:52
TrigIsoHPtTrackTriggerHypoTool::m_multiplicity
size_t m_multiplicity
Definition: TrigIsoHPtTrackTriggerHypoTool.h:88
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition: AthMsgStreamMacros.h:33
TrigIsoHPtTrackTriggerHypoTool::decideOnSingleObject
bool decideOnSingleObject(const xAOD::TrackParticle_v1 *track, const xAOD::TrackParticleContainer *AllTracks, size_t cutIndex) const
Auxiluary method, single track selection.
Definition: TrigIsoHPtTrackTriggerHypoTool.cxx:58
lumiFormat.i
int i
Definition: lumiFormat.py:85
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
PlotPulseshapeFromCool.input
input
Definition: PlotPulseshapeFromCool.py:106
TRT::Track::d0
@ d0
Definition: InnerDetector/InDetCalibEvent/TRT_CalibData/TRT_CalibData/TrackInfo.h:62
test_pyathena.parent
parent
Definition: test_pyathena.py:15
CHECK
#define CHECK(...)
Evaluate an expression and check for errors.
Definition: Control/AthenaKernel/AthenaKernel/errorcheck.h:422
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_detStore
StoreGateSvc_t m_detStore
Pointer to StoreGate (detector store by default)
Definition: AthCommonDataStore.h:393
AthAlgTool::AthAlgTool
AthAlgTool()
Default constructor:
HLT::elementsInUniqueCombinations
void elementsInUniqueCombinations(const Index2DVec &indices, std::set< size_t > &participants, std::function< bool(const Index1DVec &)> &&filter)
Definition: Combinators.cxx:154
TauGNNUtils::Variables::Track::trackPt
bool trackPt(const xAOD::TauJet &, const xAOD::TauTrack &track, double &out)
Definition: TauGNNUtils.cxx:472
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
TrigIsoHPtTrackTriggerHypoTool::m_IsoPt
Gaudi::Property< std::vector< float > > m_IsoPt
Definition: TrigIsoHPtTrackTriggerHypoTool.h:85
TrigIsoHPtTrackTriggerHypoTool::m_IsoDR
Gaudi::Property< std::vector< float > > m_IsoDR
Definition: TrigIsoHPtTrackTriggerHypoTool.h:84
merge_scale_histograms.doc
string doc
Definition: merge_scale_histograms.py:9
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:228
TrigIsoHPtTrackTriggerHypoTool::m_TrackNSCTHits
Gaudi::Property< std::vector< unsigned > > m_TrackNSCTHits
Definition: TrigIsoHPtTrackTriggerHypoTool.h:80
TrigIsoHPtTrackTriggerHypoTool::inclusiveSelection
StatusCode inclusiveSelection(std::vector< TrackInfo > &input) const
actual implementation of decide, in case of inclusive selection ( one object cut )
Definition: TrigIsoHPtTrackTriggerHypoTool.cxx:227
TrigIsoHPtTrackTriggerHypoTool::m_IsoCum
Gaudi::Property< std::vector< bool > > m_IsoCum
Definition: TrigIsoHPtTrackTriggerHypoTool.h:83
TrigIsoHPtTrackTriggerHypoTool::m_TrackNPixHits
Gaudi::Property< std::vector< unsigned > > m_TrackNPixHits
Definition: TrigIsoHPtTrackTriggerHypoTool.h:79
DataVector::end
const_iterator end() const noexcept
Return a const_iterator pointing past the end of the collection.
a
TList * a
Definition: liststreamerinfos.cxx:10
h
python.CaloScaleNoiseConfig.type
type
Definition: CaloScaleNoiseConfig.py:78
TrigIsoHPtTrackTriggerHypoTool::m_doIso
Gaudi::Property< std::vector< bool > > m_doIso
Definition: TrigIsoHPtTrackTriggerHypoTool.h:82
LArNewCalib_DelayDump_OFC_Cali.idx
idx
Definition: LArNewCalib_DelayDump_OFC_Cali.py:69
SG::VarHandleBase::vhKey
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
Definition: StoreGate/src/VarHandleBase.cxx:623
TrigIsoHPtTrackTriggerHypoTool::multiplicitySelection
StatusCode multiplicitySelection(std::vector< TrackInfo > &input) const
actual implementation of decide, in case of multiple objects selection ( independentone )
Definition: TrigIsoHPtTrackTriggerHypoTool.cxx:253
xAOD::numberOfSCTHits
@ numberOfSCTHits
number of hits in SCT [unit8_t].
Definition: TrackingPrimitives.h:268
TrigIsoHPtTrackTriggerHypoTool::m_decisionId
HLT::Identifier m_decisionId
Definition: TrigIsoHPtTrackTriggerHypoTool.h:73
HLT::Index2DVec
std::vector< Index1DVec > Index2DVec
Definition: TrigCompositeUtils/TrigCompositeUtils/Combinators.h:140
python.Bindings.keys
keys
Definition: Control/AthenaPython/python/Bindings.py:798
xAOD::track
@ track
Definition: TrackingPrimitives.h:512
Monitored::Scalar
Declare a monitored scalar variable.
Definition: MonitoredScalar.h:34
AthCommonDataStore::declareGaudiProperty
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>
Definition: AthCommonDataStore.h:156
Eta
@ Eta
Definition: RPCdef.h:8
TauGNNUtils::Variables::Track::trackEta
bool trackEta(const xAOD::TauJet &, const xAOD::TauTrack &track, double &out)
Definition: TauGNNUtils.cxx:477
DataVector::begin
const_iterator begin() const noexcept
Return a const_iterator pointing at the beginning of the collection.
fitman.k
k
Definition: fitman.py:528