ATLAS Offline Software
Loading...
Searching...
No Matches
TileEopFilterAlg Class Reference

#include <TileEopFilterAlg.h>

Inheritance diagram for TileEopFilterAlg:
Collaboration diagram for TileEopFilterAlg:

Public Member Functions

 TileEopFilterAlg (const std::string &name, ISvcLocator *pSvcLocator)
 ~TileEopFilterAlg ()
virtual StatusCode initialize ()
virtual StatusCode execute (const EventContext &ctx)
 Execute method.
virtual StatusCode sysInitialize () override
 Override sysInitialize.
virtual bool isClonable () const override
 Specify if the algorithm is clonable.
virtual StatusCode sysExecute (const EventContext &ctx) override
 Execute an algorithm.
virtual const DataObjIDColl & extraOutputDeps () const override
 Return the list of extra output dependencies.
virtual bool filterPassed (const EventContext &ctx) const
 Get filter decision:
virtual void setFilterPassed (bool state, const EventContext &ctx) const
 Set filter decision:
ServiceHandle< StoreGateSvc > & evtStore ()
 The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.
const ServiceHandle< StoreGateSvc > & detStore () const
 The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.
virtual StatusCode sysStart () override
 Handle START transition.
virtual std::vector< Gaudi::DataHandle * > inputHandles () const override
 Return this algorithm's input handles.
virtual std::vector< Gaudi::DataHandle * > outputHandles () const override
 Return this algorithm's output handles.
Gaudi::Details::PropertyBase & declareProperty (Gaudi::Property< T, V, H > &t)
void updateVHKA (Gaudi::Details::PropertyBase &)
MsgStream & msg () const
bool msgLvl (const MSG::Level lvl) const

Protected Member Functions

virtual bool isReEntrant () const override final
 Legacy algorithms are not thread-safe.
void renounceArray (SG::VarHandleKeyArray &handlesArray)
 remove all handles from I/O resolution
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.

Private Types

typedef ServiceHandle< StoreGateSvc > StoreGateSvc_t

Private Member Functions

Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T, V, H > &hndl, const SG::VarHandleKeyType &)
 specialization for handling Gaudi::Property<SG::VarHandleKey>

Private Attributes

std::string m_inputTracks
std::string m_outputTracks
std::string m_inputClusters
std::string m_outputClusters
std::string m_inputCells
std::string m_outputCells
std::string m_trackClusters
std::string m_trackCells
std::string m_clusterCells
float m_trackMom
float m_trackEta
float m_trackIso
float m_trackPtrel
float m_trackClusterR
float m_trackCellR
bool m_dumpLarCells
ToolHandle< ITrackTools > m_trackInCalo
DataObjIDColl m_extendedExtraObjects
 Extra output dependency collection, extended by AthAlgorithmDHUpdate to add symlinks.
StoreGateSvc_t m_evtStore
 Pointer to StoreGate (event store by default).
StoreGateSvc_t m_detStore
 Pointer to StoreGate (detector store by default).
std::vector< SG::VarHandleKeyArray * > m_vhka
bool m_varHandleArraysDeclared

Detailed Description

Definition at line 23 of file TileEopFilterAlg.h.

Member Typedef Documentation

◆ StoreGateSvc_t

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

Definition at line 376 of file AthCommonDataStore.h.

Constructor & Destructor Documentation

◆ TileEopFilterAlg()

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

Definition at line 18 of file TileEopFilterAlg.cxx.

18 :
19 AthAlgorithm( name, pSvcLocator ), m_trackInCalo("TrackExtrapolator"){
20//=======================================
21
22 declareProperty("InputTracks", m_inputTracks = "InDetTrackParticles");
23 declareProperty("OutputTracks", m_outputTracks = "SelectedTracks");
24 declareProperty("InputClusters", m_inputClusters = "CaloTopoClusters");
25 declareProperty("OutputClusters", m_outputClusters = "SelectedClusters");
26 declareProperty("InputCells", m_inputCells = "AllCalo");
27 declareProperty("OutputCells", m_outputCells = "SelectedCells");
28 declareProperty("TrackClusters", m_trackClusters = "TrackClusters");
29 declareProperty("TrackCells", m_trackCells = "TrackCells");
30 declareProperty("ClusterCells", m_clusterCells = "ClusterCells");
31 declareProperty("TrackMomCut", m_trackMom = 1000.);
32 declareProperty("TrackEtaCut", m_trackEta = 2.4);
33 declareProperty("TrackIsoCut", m_trackIso = 0.8);
34 declareProperty("TrackPtrelCut", m_trackPtrel = 0.15);
35 declareProperty("TrackClusterR", m_trackClusterR = 0.2);
36 declareProperty("TrackCellR", m_trackCellR = 1.0);
37 declareProperty("DumpLArCells", m_dumpLarCells = false);
38 declareProperty("TrackTools", m_trackInCalo);
39}
AthAlgorithm(const std::string &name, ISvcLocator *pSvcLocator)
Constructor.
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T, V, H > &t)
std::string m_outputTracks
std::string m_inputClusters
ToolHandle< ITrackTools > m_trackInCalo
std::string m_inputCells
std::string m_clusterCells
std::string m_outputCells
std::string m_trackClusters
std::string m_inputTracks
std::string m_outputClusters
std::string m_trackCells

◆ ~TileEopFilterAlg()

TileEopFilterAlg::~TileEopFilterAlg ( )
inline

Definition at line 29 of file TileEopFilterAlg.h.

29{};

Member Function Documentation

◆ declareGaudiProperty()

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

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

Definition at line 156 of file AthCommonDataStore.h.

158 {
160 hndl.value(),
161 hndl.documentation());
162
163 }

◆ declareProperty()

Gaudi::Details::PropertyBase & AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::declareProperty ( Gaudi::Property< T, V, H > & t)
inlineinherited

Definition at line 145 of file AthCommonDataStore.h.

145 {
146 typedef typename SG::HandleClassifier<T>::type htype;
148 }
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T, V, H > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>

◆ detStore()

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

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

Definition at line 95 of file AthCommonDataStore.h.

◆ evtStore()

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

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

Definition at line 85 of file AthCommonDataStore.h.

◆ execute()

StatusCode TileEopFilterAlg::execute ( const EventContext & ctx)
virtual

Execute method.

Implements AthAlgorithm.

Definition at line 51 of file TileEopFilterAlg.cxx.

51 {
52//=======================================
53
54 //Get the input tracks
55 const TRACKCONTAINER* inputTracks = 0;
56 CHECK( evtStore()->retrieve( inputTracks, m_inputTracks ) );
57
58 //Allocate the output tracks container
59 auto outputTracks = std::make_unique< TRACKCONTAINER >();
60 auto outputAuxTracks = std::make_unique< TRACKAUXCONTAINER>();
61 outputTracks->setStore( outputAuxTracks.get() );
62
63
64 //Select tracks
65 TRACKCONTAINER::const_iterator trackItr = inputTracks->begin();
66 TRACKCONTAINER::const_iterator trackEnd = inputTracks->end();
67 for(; trackItr != trackEnd; ++trackItr ){
68 const TRACK* track = *trackItr;
69 if(!track){ ATH_MSG_INFO("Not a valid track"); continue; }
70 //Cut 1. Momentum
71 if(track->p4().P() >= m_trackMom){
72 //Cut 2. Eta
73 if(fabs(track->eta()) <= m_trackEta){
74 /*
75 //Cut 3. Isolation: Only one track in that cone
76 //Extrapolate the current track and all other tracks and check they don't overlap in the range
77 int tracksInCone=1;
78 TRACKCONTAINER::const_iterator trackItr2 = inputTracks->begin();
79 TRACKCONTAINER::const_iterator trackEnd2 = inputTracks->end();
80 vector< vector<double> > etrack = m_trackInCalo->getXYZEtaPhiPerLayer(track);
81 for(; trackItr2 != trackEnd2; ++trackItr2 ){
82 if(trackItr==trackItr2) continue;
83 const TRACK* track2 = *trackItr2;
84 if(track2->p() < m_trackMom) continue;
85 vector< vector<double> > etrack2 = m_trackInCalo->getXYZEtaPhiPerLayer(track2);
86 for(int i=0;i<11;i++){
87 double dif_eta = etrack2[i][3] - etrack[i][3];
88 double dif_phi = etrack2[i][4] - etrack[i][4];
89 if(dif_phi<0) dif_phi=-dif_phi;
90 if(dif_phi>M_PI){dif_phi=2*M_PI-dif_phi;}
91 double deltaR = sqrt(dif_eta*dif_eta+dif_phi*dif_phi);
92 if(deltaR<m_trackIso) tracksInCone++;
93 }
94 }
95 if(tracksInCone==1){
96 TRACK* tmpTrack = new TRACK();
97 tmpTrack->makePrivateStore( track );
98 outputTracks->push_back(tmpTrack);
99 }
100 */
101
102 //Cut 3. Isolation: require ptcone{IsoCut}/track_pt < ptrelCut
103 double ptcone=0.;
104 TRACKCONTAINER::const_iterator trackItr2 = inputTracks->begin();
105 TRACKCONTAINER::const_iterator trackEnd2 = inputTracks->end();
106 for(; trackItr2 != trackEnd2; ++trackItr2 ){
107 if(trackItr==trackItr2) continue;
108 const TRACK* track2 = *trackItr2;
109 double dif_eta = track->eta() - track2->eta();
110 double dif_phi = track->phi() - track2->phi();
111 if(dif_phi<0) dif_phi=-dif_phi;
112 if(dif_phi>M_PI){dif_phi=2*M_PI-dif_phi;}
113 double deltaR = sqrt(dif_eta*dif_eta+dif_phi*dif_phi);
114 if(deltaR<m_trackIso) ptcone += track2->pt();
115 }
116 if(ptcone/track->pt() < m_trackPtrel ){
117 TRACK* tmpTrack = new TRACK();
118 tmpTrack->makePrivateStore( track );
119 outputTracks->push_back(tmpTrack);
120 }
121 }
122 }
123 }
124
125 ATH_MSG_DEBUG("Number of selected tracks: " << outputTracks->size());
126
127 //Get input clusters
128 const CLUSTERCONTAINER* inputClusters = 0;
129 CHECK( evtStore()->retrieve( inputClusters, m_inputClusters ) );
130
131 //Allocate output clusters container
132 auto outputClusters = std::make_unique< xAOD::CaloClusterContainer>();
133 auto outputAuxClusters = std::make_unique< xAOD::CaloClusterAuxContainer>();
134 outputClusters->setStore( outputAuxClusters.get() );
135
136
137 //Allocate output association between tracks and clusters
138 ASSOCCONTAINER* trackClusters = new ASSOCCONTAINER_CONSTRUCTOR(outputTracks->size());
139 CHECK( evtStore()->record( trackClusters, m_trackClusters ) );
140
141 //Select clusters that match a track
142 //For each cluster loop over all selected tracks
143 //extrapolate the track to each calorimeter layer
144 //compute distance of cluster center in given layer to track pointer in same layer
145 //select cluster if distance is smaller than threshold
146 CLUSTERCONTAINER::const_iterator clusterItr = inputClusters->begin();
147 CLUSTERCONTAINER::const_iterator clusterEnd = inputClusters->end();
148 for(;clusterItr != clusterEnd; ++clusterItr){
149 const CLUSTER* cluster = *clusterItr;
150 TRACKCONTAINER::const_iterator trackItr = outputTracks->begin();
151 TRACKCONTAINER::const_iterator trackEnd = outputTracks->end();
152 ASSOCCONTAINER::iterator assocItr = trackClusters->begin();
153 for( ; trackItr != trackEnd; ++trackItr ){
154 const TRACK* track = *trackItr;
155 vector< vector<double> > etrack = m_trackInCalo->getXYZEtaPhiPerLayer(track);
156 double deltaR=999;
157 for(int cell_sid=0;cell_sid<CaloSampling::Unknown;cell_sid++){
158 int lay=-1;
159 if (cell_sid==0 || cell_sid==4 ){lay=0;}
160 else if(cell_sid==1 || cell_sid==5 ){lay=1;}
161 else if(cell_sid==2 || cell_sid==6 ){lay=2;}
162 else if(cell_sid==3 || cell_sid==7 ){lay=3;}
163 else if(cell_sid==12 || cell_sid==18){lay=4;}
164 else if(cell_sid==13 || cell_sid==19){lay=5;}
165 else if(cell_sid==15 || cell_sid==17){lay=5;}
166 else if(cell_sid==14 || cell_sid==20){lay=6;}
167 else if(cell_sid==16) {lay=6;}
168 else if(cell_sid==8 ){lay=7;}
169 else if(cell_sid==9 ){lay=8;}
170 else if(cell_sid==10 ){lay=9;}
171 else if(cell_sid==11 ){lay=10;}
172 if(lay==-1) continue;
173 double dif_eta = cluster->etaSample((CaloSampling::CaloSample)cell_sid) - etrack[lay][3];
174 double dif_phi = cluster->phiSample((CaloSampling::CaloSample)cell_sid) - etrack[lay][4];
175 if(dif_phi<0) dif_phi=-dif_phi;
176 if(dif_phi>M_PI){dif_phi=2*M_PI-dif_phi;}
177 double tmp = sqrt(dif_eta*dif_eta+dif_phi*dif_phi);
178 deltaR = (tmp<deltaR ? tmp : deltaR);
179 }
181 unsigned int i=0;
182 while(i!=outputClusters->size()){if(outputClusters->at(i)==cluster){break;}i++;}
183 if(i==outputClusters->size()){
184 CLUSTER* tmpCluster = new CLUSTER();
185 tmpCluster->makePrivateStore( cluster );
186 outputClusters->push_back(tmpCluster);
187 }
188 //Fill association
189 assocItr->push_back(i); //FIXME
190 }
191 ++assocItr;
192 }
193 }
194
195 ATH_MSG_DEBUG("Number of selected clusters: " << outputClusters->size());
196
197 //Get input cells
198 const CELLCONTAINER* inputCells = 0;
199 CHECK( evtStore()->retrieve( inputCells, m_inputCells ) );
200
201 //Allocate output cells container
202 ConstDataVector<CELLCONTAINER>* outputCells = new ConstDataVector<CELLCONTAINER>( SG::VIEW_ELEMENTS );
203 CHECK( evtStore()->record( outputCells, m_outputCells ) );
204
205 //Allocate output association between clusters and cells
206 ASSOCCONTAINER* clusterCells = new ASSOCCONTAINER_CONSTRUCTOR(outputClusters->size());
207 CHECK( evtStore()->record( clusterCells, m_clusterCells ) );
208
209 //Select cells associated to clusters
210 clusterItr = outputClusters->begin();
211 clusterEnd = outputClusters->end();
212 ASSOCCONTAINER::iterator assocItr = clusterCells->begin();
213 //Loop over clusters
214 for(;clusterItr != clusterEnd; ++clusterItr){
215 const CLUSTER* cluster = *clusterItr;
216 if(cluster->getCellLinks() != 0){
217 CLUSTER::const_cell_iterator cellItr = cluster->cell_begin();
218 CLUSTER::const_cell_iterator cellEnd = cluster->cell_end();
219 for(;cellItr != cellEnd; ++cellItr){
220 const CELL* cell = *cellItr;
221 unsigned int i=0;
222 while(i!=outputCells->size()){if(outputCells->at(i)==cell){break;}i++;}
223 if(i==outputCells->size()){
224 outputCells->push_back(cell);
225 }
226 //Fill association
227 assocItr->push_back(i);//FIXME
228 }
229 }
230 ++assocItr;
231 }
232
233 //Allocate output association between tracks and cells
234 ASSOCCONTAINER* trackCells = new ASSOCCONTAINER_CONSTRUCTOR(outputTracks->size());
235 CHECK( evtStore()->record( trackCells, m_trackCells ) );
236
237 //Also select cells associated to tracks
238 //cell matches track in a cone of DeltaR and is not in ouputCells already
239 trackItr = outputTracks->begin();
240 trackEnd = outputTracks->end();
241 assocItr = trackCells->begin();
242 //Loop over tracks
243 for( ; trackItr != trackEnd; ++trackItr ){
244 const TRACK* track = *trackItr;
245 vector< vector<double> > etrack = m_trackInCalo->getXYZEtaPhiPerLayer(track);
246 //loop cells
247 CELLCONTAINER::const_iterator cellItr = inputCells->begin();
248 CELLCONTAINER::const_iterator cellEnd = inputCells->end();
249 for(;cellItr != cellEnd; ++cellItr){
250 const CELL* cell = *cellItr;
251 CaloSampling::CaloSample cell_sid = (CaloSampling::CaloSample)cell->caloDDE()->getSampling();
252 //http://acode-browser.usatlas.bnl.gov/lxr/source/atlas/Calorimeter/CaloGeoHelpers/CaloGeoHelpers/CaloSampling.def
253 int lay=-1;
254 if (cell_sid==0 || cell_sid==4 ){lay=0;}
255 else if(cell_sid==1 || cell_sid==5 ){lay=1;}
256 else if(cell_sid==2 || cell_sid==6 ){lay=2;}
257 else if(cell_sid==3 || cell_sid==7 ){lay=3;}
258 else if(cell_sid==12 || cell_sid==18){lay=4;}
259 else if(cell_sid==13 || cell_sid==19){lay=5;}
260 else if(cell_sid==15 || cell_sid==17){lay=5;}
261 else if(cell_sid==14 || cell_sid==20){lay=6;}
262 else if(cell_sid==16) {lay=6;}
263 else if(cell_sid==8 ){lay=7;}
264 else if(cell_sid==9 ){lay=8;}
265 else if(cell_sid==10 ){lay=9;}
266 else if(cell_sid==11 ){lay=10;}
267 if(lay==-1) continue;
268 double dif_eta = cell->eta() - etrack[lay][3];
269 double dif_phi = cell->phi() - etrack[lay][4];
270 if(dif_phi<0) dif_phi=-dif_phi;
271 if(dif_phi>M_PI){dif_phi=2*M_PI-dif_phi;}
272 double deltaR = sqrt(dif_eta*dif_eta+dif_phi*dif_phi);
273 if(deltaR<=m_trackCellR){
274 unsigned int i=0;
275 while(i!=outputCells->size()){if(outputCells->at(i)==cell){break;}i++;}
276 if(i==outputCells->size()){
277 outputCells->push_back(cell);
278 }
279 assocItr->push_back(i);//FIXME
280 }
281 }
282 ++assocItr;
283 }
284
285 ATH_MSG_DEBUG("Number of selected cells: " << outputCells->size());
286
287 CHECK( evtStore()->record(std::move(outputClusters), m_outputClusters ) );
288 CHECK( evtStore()->record(std::move(outputAuxClusters), m_outputClusters+"Aux.") );
289 CHECK( evtStore()->record(std::move(outputTracks), m_outputTracks) );
290 CHECK( evtStore()->record(std::move(outputAuxTracks), m_outputTracks+"Aux.") );
291
292
293 return StatusCode::SUCCESS;
294
295}
#define M_PI
Scalar deltaR(const MatrixBase< Derived > &vec) const
#define ATH_MSG_DEBUG(x,...)
#define ATH_MSG_INFO(x,...)
#define CHECK(...)
Evaluate an expression and check for errors.
xAOD::TrackParticle TRACK
xAOD::CaloClusterContainer CLUSTERCONTAINER
CaloCell CELL
CALORIMETER INCLUDES.
CaloCellContainer CELLCONTAINER
xAOD::CaloCluster CLUSTER
xAOD::TrackParticleContainer TRACKCONTAINER
std::vector< std::vector< int > > ASSOCCONTAINER
#define ASSOCCONTAINER_CONSTRUCTOR(size)
ServiceHandle< StoreGateSvc > & evtStore()
value_type push_back(value_type pElem)
Add an element to the end of the collection.
ElementProxy at(size_type n)
Access an element, as an lvalue.
DataModel_detail::const_iterator< DataVector > const_iterator
Definition DataVector.h:861
const_iterator end() const noexcept
Return a const_iterator pointing past the end of the collection.
const_iterator begin() const noexcept
Return a const_iterator pointing at the beginning of the collection.
const CaloClusterCellLink * getCellLinks() const
Get a pointer to the CaloClusterCellLink object (const version).
float phiSample(const CaloSample sampling) const
Retrieve barycenter in a given sample.
CaloClusterCellLink::const_iterator const_cell_iterator
Iterator of the underlying CaloClusterCellLink (explicitly const version).
const_cell_iterator cell_end() const
const_cell_iterator cell_begin() const
Iterator of the underlying CaloClusterCellLink (const version).
float etaSample(const CaloSample sampling) const
Retrieve barycenter in a given sample.
virtual double phi() const override final
The azimuthal angle ( ) of the particle (has range to .).
virtual double pt() const override final
The transverse momentum ( ) of the particle.
virtual double eta() const override final
The pseudorapidity ( ) of the particle.
@ VIEW_ELEMENTS
this data object is a view, it does not own its elmts
@ ptcone
Track isolation.

◆ extraDeps_update_handler()

void AthCommonDataStore< AthCommonMsg< Gaudi::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 & AthCommonAlgorithm< Gaudi::Algorithm >::extraOutputDeps ( ) const
overridevirtualinherited

Return the list of extra output dependencies.

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

Definition at line 89 of file AthCommonAlgorithm.cxx.

54{
55 // If we didn't find any symlinks to add, just return the collection
56 // from the base class. Otherwise, return the extended collection.
57 if (!m_extendedExtraObjects.empty()) {
59 }
61}
Common base class for algorithms.

◆ filterPassed()

virtual bool AthCommonAlgorithm< Gaudi::Algorithm >::filterPassed ( const EventContext & ctx) const
inlinevirtualinherited

Get filter decision:

Definition at line 93 of file AthCommonAlgorithm.h.

93 {
94 return execState( ctx ).filterPassed();
95 }
virtual bool filterPassed(const EventContext &ctx) const
Get filter decision:

◆ initialize()

StatusCode TileEopFilterAlg::initialize ( )
virtual

Definition at line 42 of file TileEopFilterAlg.cxx.

42 {
43//=======================================
44
45 CHECK(m_trackInCalo.retrieve());
46
47 return StatusCode::SUCCESS;
48}

◆ inputHandles()

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

◆ isClonable()

virtual bool AthCommonAlgorithm< Gaudi::Algorithm >::isClonable ( ) const
inlineoverridevirtualinherited

Specify if the algorithm is clonable.

Only relevant for non-reentrant algorithms. Actual number of clones needs to be set via the "Cardinality" property.

Reimplemented in AFP_DigiTop, AlgB, AlgT, BCM_Digitization, CscDigitBuilder, CscDigitToCscRDO, G4AtlasAlg, G4RunAlg, HGTD_Digitization, HiveAlgBase, InDet::GNNSeedingTrackMaker, InDet::SCT_Clusterization, InDet::SiSPGNNTrackMaker, InDet::SiSPSeededTrackFinder, InDet::SiTrackerSpacePointFinder, ISF::SimKernelMT, ITk::StripDigitization, ITkPixelCablingAlg, ITkStripCablingAlg, LArHitEMapMaker, LArTTL1Maker, LUCID_DigiTop, LVL1::L1TopoSimulation, MergeCalibHits, MergeGenericMuonSimHitColl, MergeHijingPars, MergeMcEventCollection, MergeTrackRecordCollection, MergeTruthJets, MergeTruthParticles, MuonDigitizer, PileUpMTAlg, PixelDigitization, RoIBResultToxAOD, SCT_ByteStreamErrorsTestAlg, SCT_CablingCondAlgFromCoraCool, SCT_CablingCondAlgFromText, SCT_ConditionsParameterTestAlg, SCT_ConditionsSummaryTestAlg, SCT_ConfigurationConditionsTestAlg, SCT_Digitization, SCT_FlaggedConditionTestAlg, SCT_LinkMaskingTestAlg, SCT_MajorityConditionsTestAlg, SCT_ModuleVetoTestAlg, SCT_MonitorConditionsTestAlg, SCT_PrepDataToxAOD, SCT_RawDataToxAOD, SCT_ReadCalibChipDataTestAlg, SCT_ReadCalibDataTestAlg, SCT_RODVetoTestAlg, SCT_SensorsTestAlg, SCT_SiliconConditionsTestAlg, SCT_StripVetoTestAlg, SCT_TdaqEnabledTestAlg, SCT_TestCablingAlg, SCTEventFlagWriter, SCTRawDataProvider, SCTSiLorentzAngleTestAlg, SCTSiPropertiesTestAlg, SGInputLoader, Simulation::BeamEffectsAlg, TileHitVecToCnt, TileMuonFitter, TilePulseForTileMuonReceiver, TileRawChannelMaker, TRTDigitization, and ZDC_DigiTop.

Definition at line 68 of file AthCommonAlgorithm.h.

68 {
69 return true;
70 }

◆ isReEntrant()

virtual bool AthAlgorithm::isReEntrant ( ) const
inlinefinaloverrideprotectedvirtualinherited

Legacy algorithms are not thread-safe.

Definition at line 47 of file AthAlgorithm.h.

47{ return false; }

◆ msg()

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

Definition at line 24 of file AthCommonMsg.h.

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

◆ msgLvl()

bool AthCommonMsg< Gaudi::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< Gaudi::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< Gaudi::Algorithm > >::renounce ( T & h)
inlineprotectedinherited

Definition at line 368 of file AthCommonDataStore.h.

369 {
370 h.renounce();
372 }
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)

◆ renounceArray()

void AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::renounceArray ( SG::VarHandleKeyArray & handlesArray)
inlineprotectedinherited

remove all handles from I/O resolution

Definition at line 352 of file AthCommonDataStore.h.

352 {
354 }

◆ setFilterPassed()

virtual void AthCommonAlgorithm< Gaudi::Algorithm >::setFilterPassed ( bool state,
const EventContext & ctx ) const
inlinevirtualinherited

Set filter decision:

Definition at line 99 of file AthCommonAlgorithm.h.

99 {
101 }
virtual void setFilterPassed(bool state, const EventContext &ctx) const
Set filter decision:

◆ sysExecute()

StatusCode AthCommonAlgorithm< Gaudi::Algorithm >::sysExecute ( const EventContext & ctx)
overridevirtualinherited

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.

Reimplemented in AthAnalysisAlgorithm.

Definition at line 80 of file AthCommonAlgorithm.cxx.

41{
42 return BaseAlg::sysExecute (ctx);
43}

◆ sysInitialize()

StatusCode AthCommonAlgorithm< Gaudi::Algorithm >::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< Gaudi::Algorithm > >.

Reimplemented in AthAnalysisAlgorithm, AthHistogramAlgorithm, HypoBase, InputMakerBase, and PyAthena::Alg.

Definition at line 60 of file AthCommonAlgorithm.cxx.

71 {
73
74 if (sc.isFailure()) {
75 return sc;
76 }
77
78 ServiceHandle<ICondSvc> cs("CondSvc",name());
79 for (auto h : outputHandles()) {
80 if (h->isCondition() && h->mode() == Gaudi::DataHandle::Writer) {
81 // do this inside the loop so we don't create the CondSvc until needed
82 if ( cs.retrieve().isFailure() ) {
83 ATH_MSG_WARNING("no CondSvc found: won't autoreg WriteCondHandles");
85 }
86 if (cs->regHandle(this,*h).isFailure()) {
88 ATH_MSG_ERROR("unable to register WriteCondHandle " << h->fullKey()
89 << " with CondSvc");
90 }
91 }
92 }
93 return sc;
94}
#define ATH_MSG_ERROR(x,...)
#define ATH_MSG_WARNING(x,...)
virtual StatusCode sysInitialize() override
virtual std::vector< Gaudi::DataHandle * > outputHandles() const override

◆ sysStart()

virtual StatusCode AthCommonDataStore< AthCommonMsg< Gaudi::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< Gaudi::Algorithm > >::updateVHKA ( Gaudi::Details::PropertyBase & )
inlineinherited

Definition at line 298 of file AthCommonDataStore.h.

298 {
299 for (auto &a : m_vhka) {
301 for (auto k : keys) {
302 k->setOwner(this);
303 }
304 }
305 }

Member Data Documentation

◆ m_clusterCells

std::string TileEopFilterAlg::m_clusterCells
private

Definition at line 44 of file TileEopFilterAlg.h.

◆ m_detStore

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

Pointer to StoreGate (detector store by default).

Definition at line 381 of file AthCommonDataStore.h.

◆ m_dumpLarCells

bool TileEopFilterAlg::m_dumpLarCells
private

Definition at line 51 of file TileEopFilterAlg.h.

◆ m_evtStore

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

Pointer to StoreGate (event store by default).

Definition at line 378 of file AthCommonDataStore.h.

◆ m_extendedExtraObjects

DataObjIDColl AthCommonAlgorithm< Gaudi::Algorithm >::m_extendedExtraObjects
privateinherited

Extra output dependency collection, extended by AthAlgorithmDHUpdate to add symlinks.

Empty if no symlinks were found.

Definition at line 108 of file AthCommonAlgorithm.h.

◆ m_inputCells

std::string TileEopFilterAlg::m_inputCells
private

Definition at line 40 of file TileEopFilterAlg.h.

◆ m_inputClusters

std::string TileEopFilterAlg::m_inputClusters
private

Definition at line 38 of file TileEopFilterAlg.h.

◆ m_inputTracks

std::string TileEopFilterAlg::m_inputTracks
private

Definition at line 36 of file TileEopFilterAlg.h.

◆ m_outputCells

std::string TileEopFilterAlg::m_outputCells
private

Definition at line 41 of file TileEopFilterAlg.h.

◆ m_outputClusters

std::string TileEopFilterAlg::m_outputClusters
private

Definition at line 39 of file TileEopFilterAlg.h.

◆ m_outputTracks

std::string TileEopFilterAlg::m_outputTracks
private

Definition at line 37 of file TileEopFilterAlg.h.

◆ m_trackCellR

float TileEopFilterAlg::m_trackCellR
private

Definition at line 50 of file TileEopFilterAlg.h.

◆ m_trackCells

std::string TileEopFilterAlg::m_trackCells
private

Definition at line 43 of file TileEopFilterAlg.h.

◆ m_trackClusterR

float TileEopFilterAlg::m_trackClusterR
private

Definition at line 49 of file TileEopFilterAlg.h.

◆ m_trackClusters

std::string TileEopFilterAlg::m_trackClusters
private

Definition at line 42 of file TileEopFilterAlg.h.

◆ m_trackEta

float TileEopFilterAlg::m_trackEta
private

Definition at line 46 of file TileEopFilterAlg.h.

◆ m_trackInCalo

ToolHandle<ITrackTools> TileEopFilterAlg::m_trackInCalo
private

Definition at line 53 of file TileEopFilterAlg.h.

◆ m_trackIso

float TileEopFilterAlg::m_trackIso
private

Definition at line 47 of file TileEopFilterAlg.h.

◆ m_trackMom

float TileEopFilterAlg::m_trackMom
private

Definition at line 45 of file TileEopFilterAlg.h.

◆ m_trackPtrel

float TileEopFilterAlg::m_trackPtrel
private

Definition at line 48 of file TileEopFilterAlg.h.

◆ m_varHandleArraysDeclared

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

Definition at line 387 of file AthCommonDataStore.h.

◆ m_vhka

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

Definition at line 386 of file AthCommonDataStore.h.


The documentation for this class was generated from the following files: