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

#include <FPGATrackSimDataPrepAlg.h>

Inheritance diagram for FPGATrackSimDataPrepAlg:
Collaboration diagram for FPGATrackSimDataPrepAlg:

Public Member Functions

 FPGATrackSimDataPrepAlg (const std::string &name, ISvcLocator *pSvcLocator)
 
virtual ~FPGATrackSimDataPrepAlg ()=default
 
virtual StatusCode initialize () override
 
virtual StatusCode execute () override
 
virtual StatusCode finalize () override
 
virtual StatusCode sysInitialize () override
 Override sysInitialize. More...
 
virtual const DataObjIDColl & extraOutputDeps () const override
 Return the list of extra output dependencies. More...
 
ServiceHandle< StoreGateSvc > & evtStore ()
 The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc. More...
 
const ServiceHandle< StoreGateSvc > & evtStore () const
 The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc. More...
 
const ServiceHandle< StoreGateSvc > & detStore () const
 The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc. More...
 
virtual StatusCode sysStart () override
 Handle START transition. More...
 
virtual std::vector< Gaudi::DataHandle * > inputHandles () const override
 Return this algorithm's input handles. More...
 
virtual std::vector< Gaudi::DataHandle * > outputHandles () const override
 Return this algorithm's output handles. More...
 
Gaudi::Details::PropertyBase & declareProperty (Gaudi::Property< T > &t)
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleKey &hndl, const std::string &doc, const SG::VarHandleKeyType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleBase &hndl, const std::string &doc, const SG::VarHandleType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleKeyArray &hndArr, const std::string &doc, const SG::VarHandleKeyArrayType &)
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, T &property, const std::string &doc, const SG::NotHandleType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, T &property, const std::string &doc="none")
 Declare a new Gaudi property. More...
 
void updateVHKA (Gaudi::Details::PropertyBase &)
 
MsgStream & msg () const
 
MsgStream & msg (const MSG::Level lvl) const
 
bool msgLvl (const MSG::Level lvl) const
 

Protected Member Functions

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

Private Types

typedef ServiceHandle< StoreGateSvcStoreGateSvc_t
 

Private Member Functions

StatusCode readInputs (bool &done)
 
StatusCode processInputs (SG::WriteHandle< FPGATrackSimHitCollection > &FPGAHitUnmapped, SG::WriteHandle< FPGATrackSimClusterCollection > &FPGAClusters, SG::WriteHandle< FPGATrackSimClusterCollection > &FPGAClustersFiltered, SG::WriteHandle< FPGATrackSimClusterCollection > &FPGASpacePoints)
 
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

std::string m_description
 
int m_ev = 0
 
ToolHandle< IFPGATrackSimInputToolm_hitSGInputTool {this, "SGInputTool", "", "Input tool from SG"}
 
ToolHandle< IFPGATrackSimEventInputHeaderToolm_hitInputTool {this, "InputTool", "FPGATrackSimSGToRawHitsTool/FPGATrackSimSGToRawHitsTool", "Input Tool"}
 
ToolHandle< FPGATrackSimReadRawRandomHitsToolm_hitInputTool2 {this, "InputTool2", "FPGATrackSimReadRawRandomHitsTool/FPGATrackSimReadRawRandomHitsTool", "Potential 2nd input Tool to load data from more than one source"}
 
ToolHandle< FPGATrackSimRawToLogicalHitsToolm_hitMapTool {this, "RawToLogicalHitsTool", "FPGATrackSim_RawToLogicalHitsTool/FPGATrackSim_RawToLogicalHitsTool", "Raw To Logical Tool"}
 
ToolHandle< IFPGATrackSimHitFilteringToolm_hitFilteringTool {this, "HitFilteringTool", "FPGATrackSimHitFilteringTool/FPGATrackSimHitFilteringTool", "Hit Filtering Tool"}
 
ToolHandle< FPGATrackSimClusteringToolIm_clusteringTool {this, "ClusteringTool", "FPGATrackSimClusteringTool/FPGATrackSimClusteringTool", "Hit Clustering Tool"}
 
ToolHandle< FPGATrackSimSpacePointsToolIm_spacepointsTool {this, "SpacePointTool", "FPGATrackSimSpacePointsTool/FPGATrackSimSpacePointsTool", "Space Points Tool"}
 
ToolHandle< FPGATrackSimOutputHeaderToolm_writeOutputTool {this, "OutputTool", "FPGATrackSimOutputHeaderTool/FPGATrackSimOutputHeaderTool", "Output tool"}
 
ServiceHandle< IFPGATrackSimMappingSvcm_FPGATrackSimMapping {this, "FPGATrackSimMapping", "FPGATrackSimMappingSvc", "FPGATrackSimMappingSvc"}
 
ServiceHandle< IFPGATrackSimEventSelectionSvcm_evtSel {this, "eventSelector", "FPGATrackSimEventSelectionSvc", "Event selection Svc"}
 
Gaudi::Property< int > m_firstInputToolN {this, "FirstInputToolN", 1, "number of times to use event from first input tool"}
 
Gaudi::Property< int > m_secondInputToolN {this, "SecondInputToolN", 0, "number of times to use event from second input tool"}
 
Gaudi::Property< bool > m_doHitFiltering {this, "HitFiltering", false, "flag to enable hit/cluster filtering"}
 
Gaudi::Property< bool > m_clustering {this, "Clustering", false, "flag to enable the clustering"}
 
Gaudi::Property< bool > m_doSpacepoints {this, "Spacepoints", false, "flag to enable the spacepoint formation"}
 
Gaudi::Property< bool > m_writeOutputData {this, "writeOutputData", true,"write the output TTree"}
 
Gaudi::Property< bool > m_doEvtSel {this, "doEvtSel", true, "do event selection"}
 
Gaudi::Property< bool > m_runOnRDO {this,"runOnRDO", false, "case when runnin on RDO file (and not or wrapper)"}
 
Gaudi::Property< std::string > m_preClusterBranch {this, "preClusterBranch", "LogicalEventInputHeader_PreCluster", "Name of the branch for pre-cluster input data in output ROOT file." }
 
Gaudi::Property< std::string > m_postClusterBranch {this, "postClusterBranch", "LogicalEventInputHeader_PostCluster", "Name of the branch for post-cluster input data in output ROOT file." }
 
FPGATrackSimEventInputHeader m_eventHeader
 
FPGATrackSimEventInputHeader m_firstInputHeader
 
FPGATrackSimLogicalEventInputHeaderm_logicEventHeader_precluster = nullptr
 
FPGATrackSimLogicalEventInputHeaderm_logicEventHeader = nullptr
 
std::vector< FPGATrackSimClusterm_clusters
 
std::vector< FPGATrackSimClusterm_clusters_original
 
std::vector< FPGATrackSimClusterm_spacepoints
 
std::vector< FPGATrackSimHitm_hits_miss
 
double m_evt = 0
 
ToolHandle< GenericMonitoringToolm_monTool {this,"MonTool", "", "Monitoring tool"}
 
SG::WriteHandleKeyArray< FPGATrackSimClusterCollectionm_FPGAClusterKey {this, "FPGATrackSimClusterKey",{"FPGAClusters_1st"},"FPGATrackSim Clusters key"}
 
SG::WriteHandleKey< FPGATrackSimClusterCollectionm_FPGAClusterFilteredKey {this, "FPGATrackSimClusterFilteredKey","FPGAClustersFiltered","FPGATrackSim Filtered Clusters key"}
 
SG::WriteHandleKeyArray< FPGATrackSimClusterCollectionm_FPGASpacePointsKey {this, "FPGATrackSimSpacePoints1stKey",{"FPGASpacePoints_1st","FPGASpacePoints_2nd"},"FPGATrackSim SpacePoints key"}
 
SG::WriteHandleKeyArray< FPGATrackSimHitCollectionm_FPGAHitKey {this, "FPGATrackSimHitKey",{"FPGAHits_1st"},"FPGATrackSim Hits key"}
 
SG::WriteHandleKey< FPGATrackSimHitCollectionm_FPGAHitUnmappedKey {this, "FPGATrackSimHitUnmappedKey","FPGAHitsUnmapped_1st","FPGATrackSim Unmapped Hits 1st stage key"}
 
SG::ReadHandleKey< xAOD::TruthParticleContainerm_inputTruthParticleContainerKey {this, "TruthTrackContainer", "TruthParticles", "Truth Particle Container"}
 
SG::WriteHandleKey< xAODTruthParticleLinkVectorm_truthLinkContainerKey {this, "TruthLinks", "xAODFPGATruthLinks", "Output EF xAODTruthLinks container"}
 
SG::WriteHandleKey< FPGATrackSimTruthTrackCollectionm_FPGATruthTrackKey {this, "FPGATrackSimTruthTrackKey", "FPGATruthTracks", "FPGATrackSim truth tracks"}
 
SG::WriteHandleKey< FPGATrackSimOfflineTrackCollectionm_FPGAOfflineTrackKey {this, "FPGATrackSimOfflineTrackKey", "FPGAOfflineTracks", "FPGATrackSim offline tracks"}
 
DataObjIDColl m_extendedExtraObjects
 
StoreGateSvc_t m_evtStore
 Pointer to StoreGate (event store by default) More...
 
StoreGateSvc_t m_detStore
 Pointer to StoreGate (detector store by default) More...
 
std::vector< SG::VarHandleKeyArray * > m_vhka
 
bool m_varHandleArraysDeclared
 

Detailed Description

Definition at line 56 of file FPGATrackSimDataPrepAlg.h.

Member Typedef Documentation

◆ StoreGateSvc_t

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

Definition at line 388 of file AthCommonDataStore.h.

Constructor & Destructor Documentation

◆ FPGATrackSimDataPrepAlg()

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

Definition at line 43 of file FPGATrackSimDataPrepAlg.cxx.

43  :
44  AthAlgorithm(name, pSvcLocator)
45 {
46 }

◆ ~FPGATrackSimDataPrepAlg()

virtual FPGATrackSimDataPrepAlg::~FPGATrackSimDataPrepAlg ( )
virtualdefault

Member Function Documentation

◆ declareGaudiProperty() [1/4]

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

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

Definition at line 170 of file AthCommonDataStore.h.

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

◆ declareGaudiProperty() [2/4]

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

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

Definition at line 156 of file AthCommonDataStore.h.

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

◆ declareGaudiProperty() [3/4]

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

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

Definition at line 184 of file AthCommonDataStore.h.

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

◆ declareGaudiProperty() [4/4]

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

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

Definition at line 199 of file AthCommonDataStore.h.

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

◆ declareProperty() [1/6]

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

Declare a new Gaudi property.

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

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

Definition at line 245 of file AthCommonDataStore.h.

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

◆ declareProperty() [2/6]

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

Declare a new Gaudi property.

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

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

Definition at line 221 of file AthCommonDataStore.h.

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

◆ declareProperty() [3/6]

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

Definition at line 259 of file AthCommonDataStore.h.

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

◆ declareProperty() [4/6]

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

Declare a new Gaudi property.

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

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

Definition at line 333 of file AthCommonDataStore.h.

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

◆ declareProperty() [5/6]

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

Declare a new Gaudi property.

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

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

Definition at line 352 of file AthCommonDataStore.h.

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

◆ declareProperty() [6/6]

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

Definition at line 145 of file AthCommonDataStore.h.

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

◆ detStore()

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

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

Definition at line 95 of file AthCommonDataStore.h.

95 { return m_detStore; }

◆ evtStore() [1/2]

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

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

Definition at line 85 of file AthCommonDataStore.h.

85 { return m_evtStore; }

◆ evtStore() [2/2]

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

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

Definition at line 90 of file AthCommonDataStore.h.

90 { return m_evtStore; }

◆ execute()

StatusCode FPGATrackSimDataPrepAlg::execute ( )
overridevirtual

Definition at line 106 of file FPGATrackSimDataPrepAlg.cxx.

107 {
108 #ifdef BENCHMARK_LOGICALHITSALG
109  std::chrono::time_point<std::chrono::steady_clock> t_0, t_1;
111 #endif
112 
113  const EventContext& ctx = getContext();
114 
115  // Read inputs
116  bool done = false;
117  ATH_CHECK(readInputs(done));
118 
119  if (done) {
120  SmartIF<IEventProcessor> appMgr{service("ApplicationMgr")};
121  if (!appMgr) {
122  ATH_MSG_ERROR("Failed to retrieve ApplicationMgr as IEventProcessor");
123  return StatusCode::FAILURE;
124  }
125  return appMgr->stopRun();
126  }
127 
129  ATH_CHECK( FPGAHits.record (std::make_unique<FPGATrackSimHitCollection>()));
130 
132  ATH_CHECK( FPGAHitUnmapped.record (std::make_unique<FPGATrackSimHitCollection>()));
133 
135  ATH_CHECK( FPGAClusters.record (std::make_unique<FPGATrackSimClusterCollection>()));
136 
138  ATH_CHECK( FPGAClustersFiltered.record (std::make_unique<FPGATrackSimClusterCollection>()));
139 
141  ATH_CHECK( FPGASpacePoints.record (std::make_unique<FPGATrackSimClusterCollection>()));
142 
144  ATH_CHECK(truthLinkVec.record(std::make_unique<xAODTruthParticleLinkVector>()));
145 
147  ATH_CHECK(FPGATruthTracks.record(std::make_unique<FPGATrackSimTruthTrackCollection>()));
148 
150  ATH_CHECK(FPGAOfflineTracks.record(std::make_unique<FPGATrackSimOfflineTrackCollection>()));
151 
152  // Apply truth track cuts
153  if ( m_doEvtSel ){
154  if (!m_evtSel->selectEvent(&m_eventHeader))
155  {
156  ATH_MSG_DEBUG("Event skipped by: " << m_evtSel->name());
157  return StatusCode::SUCCESS;
158  }
159  else {
160  ATH_MSG_DEBUG("Event accepted by: " << m_evtSel->name());
161  // Make a new truth link vector based on FPGATrackSim selections
162  if (m_runOnRDO) {
163  SG::ReadHandle<xAOD::TruthParticleContainer> truthParticleContainer(m_inputTruthParticleContainerKey, ctx); // Read offline TruthParticles
164  if (!truthParticleContainer.isValid()) {
165  ATH_MSG_ERROR("No valid truth particle container with key " << truthParticleContainer.key());
166  m_evtSel->setSelectedEvent(false);
167  return StatusCode::FAILURE;
168  }
169  const ElementLink<xAOD::TruthParticleContainer> eltp(*truthParticleContainer, truthParticleContainer->size() - 1);
170  std::vector<FPGATrackSimTruthTrack> const& truthtracks = m_eventHeader.optional().getTruthTracks();
171  for (const xAOD::TruthParticle* truthParticle : *truthParticleContainer) // loop over offline truth particles
172  {
173  for (const FPGATrackSimTruthTrack& fpgaTruthTrack : truthtracks) // loop over FPGA truth tracks
174  {
175  if (fpgaTruthTrack.getBarcode() == static_cast<HepMcParticleLink::barcode_type>(truthParticle->barcode()))
176  {
177  truthLinkVec->push_back(new xAODTruthParticleLink(HepMcParticleLink(truthParticle->barcode(), 0,
179  ATH_MSG_VERBOSE("Truth link added");
180  break;
181  }
182  }
183  }
184  std::stable_sort(truthLinkVec->begin(), truthLinkVec->end(), SortTruthParticleLink());
185  ATH_MSG_VERBOSE("Truth link size: " << truthLinkVec->size());
186  if (truthLinkVec->size() == 0)
187  {
188  ATH_MSG_DEBUG("No truth particles selected. Event skipped...");
189  m_evtSel->setSelectedEvent(false);
190  return StatusCode::SUCCESS;
191  }
192  }
193  }
194  } else {
195  ATH_MSG_DEBUG("No Event Selection applied");
196  }
197  TIME(m_tread);
198 
199  // Event passes cuts, count it
200  m_evt++;
201 
202  // Map, cluster, and filter hits
203  ATH_CHECK(processInputs(FPGAHitUnmapped, FPGAClusters, FPGAClustersFiltered, FPGASpacePoints));
204 
205  // Now that this is done, push truth tracks back to storegate.
206  for (const auto& truthtrack : m_logicEventHeader->optional().getTruthTracks()) {
207  FPGATruthTracks->push_back(truthtrack);
208  }
209 
210  // Need to do the same for offline tracks.
211  for (const auto& offlineTrack : m_logicEventHeader->optional().getOfflineTracks()) {
212  FPGAOfflineTracks->push_back(offlineTrack);
213  }
214 
215  // Get reference to hits
216  unsigned regionID = m_evtSel->getRegionID();
217  // Recording Data
218  auto mon_regionID = Monitored::Scalar<unsigned>("regionID", regionID);
219  Monitored::Group(m_monTool, mon_regionID);
220 
221  TIME(m_tprocess);
222 
223  // If and when we set up code to run over more than one region/tower at a time this will need to be updated
224  std::vector<FPGATrackSimHit> const & hits = m_logicEventHeader->towers().at(0).hits();
225 
226  std::vector<std::shared_ptr<const FPGATrackSimHit>> phits;
227  phits.reserve(hits.size());
228  for (FPGATrackSimHit const& h : hits) {
229  if (h.isReal()) phits.emplace_back(std::make_shared<const FPGATrackSimHit>(h));
230  }
231 
232  for (const auto & Hit : phits) FPGAHits->push_back(*Hit);
233 
234  auto mon_nhits = Monitored::Scalar<unsigned>("nHits", hits.size());
235  auto mon_nhits_unmapped = Monitored::Scalar<unsigned>("nHits_unmapped", m_hits_miss.size());
236  Monitored::Group(m_monTool, mon_nhits, mon_nhits_unmapped);
237 
238  // Write the output and reset
239  ATH_CHECK(m_writeOutputTool->writeData());
240 
241  // Reset data pointers
245 
246  TIME(m_tfin);
247 
248  return StatusCode::SUCCESS;
249 }

◆ extraDeps_update_handler()

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

Add StoreName to extra input/output deps as needed.

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

◆ extraOutputDeps()

const DataObjIDColl & AthAlgorithm::extraOutputDeps ( ) const
overridevirtualinherited

Return the list of extra output dependencies.

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

Definition at line 50 of file AthAlgorithm.cxx.

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

◆ finalize()

StatusCode FPGATrackSimDataPrepAlg::finalize ( )
overridevirtual

Definition at line 366 of file FPGATrackSimDataPrepAlg.cxx.

367 {
368 #ifdef BENCHMARK_LOGICALHITSALG
369  ATH_MSG_INFO("Timings:" <<
370  "\nread input: " << std::setw(10) << m_tread <<
371  "\nprocess hits: " << std::setw(10) << m_tprocess <<
372  "\nfin: " << std::setw(10) << m_tfin
373  );
374 #endif
375 
376  // TODO print out some data prep alg related stats here.s
377 
378  return StatusCode::SUCCESS;
379 }

◆ initialize()

StatusCode FPGATrackSimDataPrepAlg::initialize ( )
overridevirtual

Definition at line 49 of file FPGATrackSimDataPrepAlg.cxx.

50 {
51  std::stringstream ss(m_description);
52  std::string line;
53  ATH_MSG_INFO("Tag config:");
54  if (!m_description.empty()) {
55  while (std::getline(ss, line, '\n')) {
56  ATH_MSG_INFO('\t' << line);
57  }
58  }
59 
60 
61  ATH_CHECK(m_hitSGInputTool.retrieve(EnableTool{!m_hitSGInputTool.empty()}));
62 
63  ATH_CHECK(m_hitInputTool.retrieve(EnableTool{!m_hitInputTool.empty()}));
64  ATH_CHECK(m_hitInputTool2.retrieve(EnableTool{m_secondInputToolN > 0 && !m_hitInputTool2.empty()}));
65  ATH_CHECK(m_hitMapTool.retrieve());
66  ATH_CHECK(m_hitFilteringTool.retrieve(EnableTool{m_doHitFiltering}));
67  ATH_CHECK(m_clusteringTool.retrieve(EnableTool{m_clustering}));
68  ATH_CHECK(m_spacepointsTool.retrieve(EnableTool{m_doSpacepoints}));
69 
70  ATH_CHECK(m_writeOutputTool.retrieve());
71  ATH_CHECK(m_FPGATrackSimMapping.retrieve());
72  if ( m_doEvtSel ) {
73  ATH_CHECK(m_evtSel.retrieve());
74  }
75 
76  ATH_MSG_DEBUG("initialize() Instantiating root objects");
78  m_logicEventHeader = m_writeOutputTool->addInputBranch(m_postClusterBranch.value(), true);
79 
80  ATH_MSG_DEBUG("initialize() Setting branch");
81 
82  if (!m_monTool.empty())
83  ATH_CHECK(m_monTool.retrieve());
84 
85  ATH_CHECK( m_FPGAClusterKey.initialize() );
87  ATH_CHECK( m_FPGAHitKey.initialize() );
88  ATH_CHECK( m_FPGASpacePointsKey.initialize() );
94 
95  ATH_MSG_DEBUG("initialize() Finished");
96 
97 
98  return StatusCode::SUCCESS;
99 }

◆ inputHandles()

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

Return this algorithm's input handles.

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

◆ msg() [1/2]

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

Definition at line 24 of file AthCommonMsg.h.

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

◆ msg() [2/2]

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

Definition at line 27 of file AthCommonMsg.h.

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

◆ msgLvl()

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

Definition at line 30 of file AthCommonMsg.h.

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

◆ outputHandles()

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

Return this algorithm's output handles.

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

◆ processInputs()

StatusCode FPGATrackSimDataPrepAlg::processInputs ( SG::WriteHandle< FPGATrackSimHitCollection > &  FPGAHitUnmapped,
SG::WriteHandle< FPGATrackSimClusterCollection > &  FPGAClusters,
SG::WriteHandle< FPGATrackSimClusterCollection > &  FPGAClustersFiltered,
SG::WriteHandle< FPGATrackSimClusterCollection > &  FPGASpacePoints 
)
private

Definition at line 297 of file FPGATrackSimDataPrepAlg.cxx.

301 {
302  m_clusters.clear();
303  m_spacepoints.clear();
304  m_hits_miss.clear();
305 
306  // Map hits
307  ATH_MSG_DEBUG("Running hits conversion");
311 
312  ATH_CHECK(m_hitMapTool->getUnmapped(m_hits_miss));
313  for (const FPGATrackSimHit& hit : m_hits_miss) FPGAHitUnmapped->push_back(hit);
314 
315 
316 
317  ATH_MSG_DEBUG("Hits conversion done");
318  // Random removal of hits
319  if (m_doHitFiltering) {
320  ATH_MSG_DEBUG("Running hits filtering");
321  ATH_CHECK(m_hitFilteringTool->DoRandomRemoval(*m_logicEventHeader, true));
322  }
323 
324  // At this stage, copy the logicEventHeader.
326 
327  // Clustering
328  if (m_clustering)
329  {
330  ATH_MSG_DEBUG("Running clustering");
333 
334  // I think I also want to pass m_clusters to random removal (but won't work currently)
335  if (m_doHitFiltering) ATH_CHECK(m_hitFilteringTool->DoRandomRemoval(*m_logicEventHeader, false));
336  for (const FPGATrackSimCluster& cluster : m_clusters_original) FPGAClusters->push_back(cluster);
337 
338  }
339 
340  // Filter hits/clusters (untested for hits, ie with m_clustering = false)
341  if (m_doHitFiltering)
342  {
343  // get the sets of layers that we want to filter hits from
344  std::vector<int> filter_pixel_physLayers;
345  std::vector<int> filter_strip_physLayers;
346  const FPGATrackSimPlaneMap *planeMap = m_FPGATrackSimMapping->PlaneMap_1st();
347  ATH_CHECK(m_hitFilteringTool->GetPairedStripPhysLayers(planeMap, filter_strip_physLayers));
348  m_clusters.clear();
349  ATH_CHECK(m_hitFilteringTool->DoHitFiltering(*m_logicEventHeader, filter_pixel_physLayers, filter_strip_physLayers, m_clusters));
350  for (const FPGATrackSimCluster &cluster : m_clusters) FPGAClustersFiltered->push_back(cluster);
351 
352  }
353 
354  // Space points
355  if (m_doSpacepoints) {
357  for (const FPGATrackSimCluster& cluster : m_spacepoints) FPGASpacePoints->push_back(cluster);
358  }
359 
360  return StatusCode::SUCCESS;
361 }

◆ readInputs()

StatusCode FPGATrackSimDataPrepAlg::readInputs ( bool &  done)
private

Definition at line 256 of file FPGATrackSimDataPrepAlg.cxx.

257 {
258 
259  if ( !m_hitSGInputTool.empty()) {
260  ATH_CHECK(m_hitSGInputTool->readData(&m_eventHeader, Gaudi::Hive::currentContext()));
261  ATH_MSG_DEBUG("Loaded " << m_eventHeader.nHits() << " hits in event header from SG");
262 
263  return StatusCode::SUCCESS;
264  }
265 
266  if (m_ev % m_firstInputToolN == 0)
267  {
268  // Read primary input
269  ATH_CHECK(m_hitInputTool->readData(&m_firstInputHeader, done));
270  if (done)
271  {
272  ATH_MSG_INFO("Cannot read more events from file, returning");
273  return StatusCode::SUCCESS; // end of loop over events
274  }
275  }
276 
278 
279  // Read secondary input
280  for (int i = 0; i < m_secondInputToolN; i++)
281  {
282  ATH_CHECK(m_hitInputTool2->readData(&m_eventHeader, done, false));
283  if (done)
284  {
285  ATH_MSG_INFO("Cannot read more events from file, returning");
286  return StatusCode::SUCCESS;
287  }
288  }
289 
290  m_ev++;
291 
292  return StatusCode::SUCCESS;
293 }

◆ renounce()

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

Definition at line 380 of file AthCommonDataStore.h.

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

◆ renounceArray()

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

remove all handles from I/O resolution

Definition at line 364 of file AthCommonDataStore.h.

364  {
365  handlesArray.renounce();
366  }

◆ sysInitialize()

StatusCode AthAlgorithm::sysInitialize ( )
overridevirtualinherited

Override sysInitialize.

Override sysInitialize from the base class.

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

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

Reimplemented from AthCommonDataStore< AthCommonMsg< Algorithm > >.

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

Definition at line 66 of file AthAlgorithm.cxx.

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

◆ sysStart()

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

Handle START transition.

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

◆ updateVHKA()

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

Definition at line 308 of file AthCommonDataStore.h.

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

Member Data Documentation

◆ m_clustering

Gaudi::Property<bool> FPGATrackSimDataPrepAlg::m_clustering {this, "Clustering", false, "flag to enable the clustering"}
private

Definition at line 87 of file FPGATrackSimDataPrepAlg.h.

◆ m_clusteringTool

ToolHandle<FPGATrackSimClusteringToolI> FPGATrackSimDataPrepAlg::m_clusteringTool {this, "ClusteringTool", "FPGATrackSimClusteringTool/FPGATrackSimClusteringTool", "Hit Clustering Tool"}
private

Definition at line 77 of file FPGATrackSimDataPrepAlg.h.

◆ m_clusters

std::vector<FPGATrackSimCluster> FPGATrackSimDataPrepAlg::m_clusters
private

Definition at line 104 of file FPGATrackSimDataPrepAlg.h.

◆ m_clusters_original

std::vector<FPGATrackSimCluster> FPGATrackSimDataPrepAlg::m_clusters_original
private

Definition at line 104 of file FPGATrackSimDataPrepAlg.h.

◆ m_description

std::string FPGATrackSimDataPrepAlg::m_description
private

Definition at line 68 of file FPGATrackSimDataPrepAlg.h.

◆ m_detStore

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

Pointer to StoreGate (detector store by default)

Definition at line 393 of file AthCommonDataStore.h.

◆ m_doEvtSel

Gaudi::Property<bool> FPGATrackSimDataPrepAlg::m_doEvtSel {this, "doEvtSel", true, "do event selection"}
private

Definition at line 90 of file FPGATrackSimDataPrepAlg.h.

◆ m_doHitFiltering

Gaudi::Property<bool> FPGATrackSimDataPrepAlg::m_doHitFiltering {this, "HitFiltering", false, "flag to enable hit/cluster filtering"}
private

Definition at line 86 of file FPGATrackSimDataPrepAlg.h.

◆ m_doSpacepoints

Gaudi::Property<bool> FPGATrackSimDataPrepAlg::m_doSpacepoints {this, "Spacepoints", false, "flag to enable the spacepoint formation"}
private

Definition at line 88 of file FPGATrackSimDataPrepAlg.h.

◆ m_ev

int FPGATrackSimDataPrepAlg::m_ev = 0
private

Definition at line 69 of file FPGATrackSimDataPrepAlg.h.

◆ m_eventHeader

FPGATrackSimEventInputHeader FPGATrackSimDataPrepAlg::m_eventHeader
private

Definition at line 98 of file FPGATrackSimDataPrepAlg.h.

◆ m_evt

double FPGATrackSimDataPrepAlg::m_evt = 0
private

Definition at line 109 of file FPGATrackSimDataPrepAlg.h.

◆ m_evtSel

ServiceHandle<IFPGATrackSimEventSelectionSvc> FPGATrackSimDataPrepAlg::m_evtSel {this, "eventSelector", "FPGATrackSimEventSelectionSvc", "Event selection Svc"}
private

Definition at line 81 of file FPGATrackSimDataPrepAlg.h.

◆ m_evtStore

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

Pointer to StoreGate (event store by default)

Definition at line 390 of file AthCommonDataStore.h.

◆ m_extendedExtraObjects

DataObjIDColl AthAlgorithm::m_extendedExtraObjects
privateinherited

Definition at line 79 of file AthAlgorithm.h.

◆ m_firstInputHeader

FPGATrackSimEventInputHeader FPGATrackSimDataPrepAlg::m_firstInputHeader
private

Definition at line 99 of file FPGATrackSimDataPrepAlg.h.

◆ m_firstInputToolN

Gaudi::Property<int> FPGATrackSimDataPrepAlg::m_firstInputToolN {this, "FirstInputToolN", 1, "number of times to use event from first input tool"}
private

Definition at line 84 of file FPGATrackSimDataPrepAlg.h.

◆ m_FPGAClusterFilteredKey

SG::WriteHandleKey<FPGATrackSimClusterCollection> FPGATrackSimDataPrepAlg::m_FPGAClusterFilteredKey {this, "FPGATrackSimClusterFilteredKey","FPGAClustersFiltered","FPGATrackSim Filtered Clusters key"}
private

Definition at line 120 of file FPGATrackSimDataPrepAlg.h.

◆ m_FPGAClusterKey

SG::WriteHandleKeyArray<FPGATrackSimClusterCollection> FPGATrackSimDataPrepAlg::m_FPGAClusterKey {this, "FPGATrackSimClusterKey",{"FPGAClusters_1st"},"FPGATrackSim Clusters key"}
private

Definition at line 119 of file FPGATrackSimDataPrepAlg.h.

◆ m_FPGAHitKey

SG::WriteHandleKeyArray<FPGATrackSimHitCollection> FPGATrackSimDataPrepAlg::m_FPGAHitKey {this, "FPGATrackSimHitKey",{"FPGAHits_1st"},"FPGATrackSim Hits key"}
private

Definition at line 122 of file FPGATrackSimDataPrepAlg.h.

◆ m_FPGAHitUnmappedKey

SG::WriteHandleKey<FPGATrackSimHitCollection> FPGATrackSimDataPrepAlg::m_FPGAHitUnmappedKey {this, "FPGATrackSimHitUnmappedKey","FPGAHitsUnmapped_1st","FPGATrackSim Unmapped Hits 1st stage key"}
private

Definition at line 123 of file FPGATrackSimDataPrepAlg.h.

◆ m_FPGAOfflineTrackKey

SG::WriteHandleKey<FPGATrackSimOfflineTrackCollection> FPGATrackSimDataPrepAlg::m_FPGAOfflineTrackKey {this, "FPGATrackSimOfflineTrackKey", "FPGAOfflineTracks", "FPGATrackSim offline tracks"}
private

Definition at line 129 of file FPGATrackSimDataPrepAlg.h.

◆ m_FPGASpacePointsKey

SG::WriteHandleKeyArray<FPGATrackSimClusterCollection> FPGATrackSimDataPrepAlg::m_FPGASpacePointsKey {this, "FPGATrackSimSpacePoints1stKey",{"FPGASpacePoints_1st","FPGASpacePoints_2nd"},"FPGATrackSim SpacePoints key"}
private

Definition at line 121 of file FPGATrackSimDataPrepAlg.h.

◆ m_FPGATrackSimMapping

ServiceHandle<IFPGATrackSimMappingSvc> FPGATrackSimDataPrepAlg::m_FPGATrackSimMapping {this, "FPGATrackSimMapping", "FPGATrackSimMappingSvc", "FPGATrackSimMappingSvc"}
private

Definition at line 80 of file FPGATrackSimDataPrepAlg.h.

◆ m_FPGATruthTrackKey

SG::WriteHandleKey<FPGATrackSimTruthTrackCollection> FPGATrackSimDataPrepAlg::m_FPGATruthTrackKey {this, "FPGATrackSimTruthTrackKey", "FPGATruthTracks", "FPGATrackSim truth tracks"}
private

Definition at line 128 of file FPGATrackSimDataPrepAlg.h.

◆ m_hitFilteringTool

ToolHandle<IFPGATrackSimHitFilteringTool> FPGATrackSimDataPrepAlg::m_hitFilteringTool {this, "HitFilteringTool", "FPGATrackSimHitFilteringTool/FPGATrackSimHitFilteringTool", "Hit Filtering Tool"}
private

Definition at line 76 of file FPGATrackSimDataPrepAlg.h.

◆ m_hitInputTool

ToolHandle<IFPGATrackSimEventInputHeaderTool> FPGATrackSimDataPrepAlg::m_hitInputTool {this, "InputTool", "FPGATrackSimSGToRawHitsTool/FPGATrackSimSGToRawHitsTool", "Input Tool"}
private

Definition at line 73 of file FPGATrackSimDataPrepAlg.h.

◆ m_hitInputTool2

ToolHandle<FPGATrackSimReadRawRandomHitsTool> FPGATrackSimDataPrepAlg::m_hitInputTool2 {this, "InputTool2", "FPGATrackSimReadRawRandomHitsTool/FPGATrackSimReadRawRandomHitsTool", "Potential 2nd input Tool to load data from more than one source"}
private

Definition at line 74 of file FPGATrackSimDataPrepAlg.h.

◆ m_hitMapTool

ToolHandle<FPGATrackSimRawToLogicalHitsTool> FPGATrackSimDataPrepAlg::m_hitMapTool {this, "RawToLogicalHitsTool", "FPGATrackSim_RawToLogicalHitsTool/FPGATrackSim_RawToLogicalHitsTool", "Raw To Logical Tool"}
private

Definition at line 75 of file FPGATrackSimDataPrepAlg.h.

◆ m_hits_miss

std::vector<FPGATrackSimHit> FPGATrackSimDataPrepAlg::m_hits_miss
private

Definition at line 106 of file FPGATrackSimDataPrepAlg.h.

◆ m_hitSGInputTool

ToolHandle<IFPGATrackSimInputTool> FPGATrackSimDataPrepAlg::m_hitSGInputTool {this, "SGInputTool", "", "Input tool from SG"}
private

Definition at line 72 of file FPGATrackSimDataPrepAlg.h.

◆ m_inputTruthParticleContainerKey

SG::ReadHandleKey<xAOD::TruthParticleContainer> FPGATrackSimDataPrepAlg::m_inputTruthParticleContainerKey {this, "TruthTrackContainer", "TruthParticles", "Truth Particle Container"}
private

Definition at line 125 of file FPGATrackSimDataPrepAlg.h.

◆ m_logicEventHeader

FPGATrackSimLogicalEventInputHeader* FPGATrackSimDataPrepAlg::m_logicEventHeader = nullptr
private

Definition at line 101 of file FPGATrackSimDataPrepAlg.h.

◆ m_logicEventHeader_precluster

FPGATrackSimLogicalEventInputHeader* FPGATrackSimDataPrepAlg::m_logicEventHeader_precluster = nullptr
private

Definition at line 100 of file FPGATrackSimDataPrepAlg.h.

◆ m_monTool

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

Definition at line 117 of file FPGATrackSimDataPrepAlg.h.

◆ m_postClusterBranch

Gaudi::Property<std::string> FPGATrackSimDataPrepAlg::m_postClusterBranch {this, "postClusterBranch", "LogicalEventInputHeader_PostCluster", "Name of the branch for post-cluster input data in output ROOT file." }
private

Definition at line 95 of file FPGATrackSimDataPrepAlg.h.

◆ m_preClusterBranch

Gaudi::Property<std::string> FPGATrackSimDataPrepAlg::m_preClusterBranch {this, "preClusterBranch", "LogicalEventInputHeader_PreCluster", "Name of the branch for pre-cluster input data in output ROOT file." }
private

Definition at line 94 of file FPGATrackSimDataPrepAlg.h.

◆ m_runOnRDO

Gaudi::Property<bool> FPGATrackSimDataPrepAlg::m_runOnRDO {this,"runOnRDO", false, "case when runnin on RDO file (and not or wrapper)"}
private

Definition at line 91 of file FPGATrackSimDataPrepAlg.h.

◆ m_secondInputToolN

Gaudi::Property<int> FPGATrackSimDataPrepAlg::m_secondInputToolN {this, "SecondInputToolN", 0, "number of times to use event from second input tool"}
private

Definition at line 85 of file FPGATrackSimDataPrepAlg.h.

◆ m_spacepoints

std::vector<FPGATrackSimCluster> FPGATrackSimDataPrepAlg::m_spacepoints
private

Definition at line 105 of file FPGATrackSimDataPrepAlg.h.

◆ m_spacepointsTool

ToolHandle<FPGATrackSimSpacePointsToolI> FPGATrackSimDataPrepAlg::m_spacepointsTool {this, "SpacePointTool", "FPGATrackSimSpacePointsTool/FPGATrackSimSpacePointsTool", "Space Points Tool"}
private

Definition at line 78 of file FPGATrackSimDataPrepAlg.h.

◆ m_truthLinkContainerKey

SG::WriteHandleKey<xAODTruthParticleLinkVector> FPGATrackSimDataPrepAlg::m_truthLinkContainerKey {this, "TruthLinks", "xAODFPGATruthLinks", "Output EF xAODTruthLinks container"}
private

Definition at line 126 of file FPGATrackSimDataPrepAlg.h.

◆ m_varHandleArraysDeclared

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

Definition at line 399 of file AthCommonDataStore.h.

◆ m_vhka

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

Definition at line 398 of file AthCommonDataStore.h.

◆ m_writeOutputData

Gaudi::Property<bool> FPGATrackSimDataPrepAlg::m_writeOutputData {this, "writeOutputData", true,"write the output TTree"}
private

Definition at line 89 of file FPGATrackSimDataPrepAlg.h.

◆ m_writeOutputTool

ToolHandle<FPGATrackSimOutputHeaderTool> FPGATrackSimDataPrepAlg::m_writeOutputTool {this, "OutputTool", "FPGATrackSimOutputHeaderTool/FPGATrackSimOutputHeaderTool", "Output tool"}
private

Definition at line 79 of file FPGATrackSimDataPrepAlg.h.


The documentation for this class was generated from the following files:
FPGATrackSimDataPrepAlg::readInputs
StatusCode readInputs(bool &done)
Definition: FPGATrackSimDataPrepAlg.cxx:256
FPGATrackSimDataPrepAlg::m_evt
double m_evt
Definition: FPGATrackSimDataPrepAlg.h:109
checkFileSG.line
line
Definition: checkFileSG.py:75
FPGATrackSimDataPrepAlg::m_monTool
ToolHandle< GenericMonitoringTool > m_monTool
Definition: FPGATrackSimDataPrepAlg.h:117
TrigDefs::Group
Group
Properties of a chain group.
Definition: GroupProperties.h:13
FPGATrackSimDataPrepAlg::m_hitSGInputTool
ToolHandle< IFPGATrackSimInputTool > m_hitSGInputTool
Definition: FPGATrackSimDataPrepAlg.h:72
FPGATrackSimOptionalEventInfo::getOfflineTracks
const std::vector< FPGATrackSimOfflineTrack > & getOfflineTracks() const
Definition: FPGATrackSimOptionalEventInfo.h:32
TRTCalib_Extractor.hits
hits
Definition: TRTCalib_Extractor.py:35
FPGATrackSimDataPrepAlg::m_hitInputTool2
ToolHandle< FPGATrackSimReadRawRandomHitsTool > m_hitInputTool2
Definition: FPGATrackSimDataPrepAlg.h:74
python.PerfMonSerializer.p
def p
Definition: PerfMonSerializer.py:743
PowhegControl_ttHplus_NLO.ss
ss
Definition: PowhegControl_ttHplus_NLO.py:83
FPGATrackSimDataPrepAlg::m_eventHeader
FPGATrackSimEventInputHeader m_eventHeader
Definition: FPGATrackSimDataPrepAlg.h:98
FPGATrackSimDataPrepAlg::m_hitMapTool
ToolHandle< FPGATrackSimRawToLogicalHitsTool > m_hitMapTool
Definition: FPGATrackSimDataPrepAlg.h:75
ATH_MSG_INFO
#define ATH_MSG_INFO(x)
Definition: AthMsgStreamMacros.h:31
FPGATrackSimCluster
Definition: FPGATrackSimCluster.h:25
FPGATrackSimDataPrepAlg::m_logicEventHeader_precluster
FPGATrackSimLogicalEventInputHeader * m_logicEventHeader_precluster
Definition: FPGATrackSimDataPrepAlg.h:100
SG::ReadHandle
Definition: StoreGate/StoreGate/ReadHandle.h:70
AthCommonDataStore::declareProperty
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
Definition: AthCommonDataStore.h:145
FPGATrackSimDataPrepAlg::m_doSpacepoints
Gaudi::Property< bool > m_doSpacepoints
Definition: FPGATrackSimDataPrepAlg.h:88
FPGATrackSimDataPrepAlg::m_logicEventHeader
FPGATrackSimLogicalEventInputHeader * m_logicEventHeader
Definition: FPGATrackSimDataPrepAlg.h:101
FPGATrackSimTruthTrack
Definition: FPGATrackSimTruthTrack.h:14
TIME
#define TIME(name)
Definition: FPGATrackSimDataPrepAlg.cxx:36
FPGATrackSimDataPrepAlg::m_ev
int m_ev
Definition: FPGATrackSimDataPrepAlg.h:69
AthCommonDataStore< AthCommonMsg< Algorithm > >::m_evtStore
StoreGateSvc_t m_evtStore
Pointer to StoreGate (event store by default)
Definition: AthCommonDataStore.h:390
AthCommonDataStore< AthCommonMsg< Algorithm > >::m_vhka
std::vector< SG::VarHandleKeyArray * > m_vhka
Definition: AthCommonDataStore.h:398
FPGATrackSimDataPrepAlg::m_evtSel
ServiceHandle< IFPGATrackSimEventSelectionSvc > m_evtSel
Definition: FPGATrackSimDataPrepAlg.h:81
read_hist_ntuple.t
t
Definition: read_hist_ntuple.py:5
ATH_MSG_VERBOSE
#define ATH_MSG_VERBOSE(x)
Definition: AthMsgStreamMacros.h:28
FPGATrackSimDataPrepAlg::m_description
std::string m_description
Definition: FPGATrackSimDataPrepAlg.h:68
FPGATrackSimDataPrepAlg::m_FPGAOfflineTrackKey
SG::WriteHandleKey< FPGATrackSimOfflineTrackCollection > m_FPGAOfflineTrackKey
Definition: FPGATrackSimDataPrepAlg.h:129
std::stable_sort
void stable_sort(std::reverse_iterator< DataModel_detail::iterator< DVL > > beg, std::reverse_iterator< DataModel_detail::iterator< DVL > > end, Compare comp)
Specialization of stable_sort for DataVector/List.
Definition: DVL_algorithms.h:711
AthenaPoolTestRead.sc
sc
Definition: AthenaPoolTestRead.py:27
FPGATrackSimOptionalEventInfo::getTruthTracks
const std::vector< FPGATrackSimTruthTrack > & getTruthTracks() const
Definition: FPGATrackSimOptionalEventInfo.h:37
SG::VarHandleKeyArray::setOwner
virtual void setOwner(IDataHandleHolder *o)=0
FPGATrackSimHit
Definition: FPGATrackSimHit.h:41
FPGATrackSimDataPrepAlg::m_FPGAClusterFilteredKey
SG::WriteHandleKey< FPGATrackSimClusterCollection > m_FPGAClusterFilteredKey
Definition: FPGATrackSimDataPrepAlg.h:120
IDTPMcnv.htype
htype
Definition: IDTPMcnv.py:27
FPGATrackSimEventInputHeader::nHits
int nHits() const
Definition: FPGATrackSimEventInputHeader.h:37
FPGATrackSimDataPrepAlg::m_hitFilteringTool
ToolHandle< IFPGATrackSimHitFilteringTool > m_hitFilteringTool
Definition: FPGATrackSimDataPrepAlg.h:76
FPGATrackSimDataPrepAlg::m_spacepointsTool
ToolHandle< FPGATrackSimSpacePointsToolI > m_spacepointsTool
Definition: FPGATrackSimDataPrepAlg.h:78
Hit
Definition: Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloGpu/ISF_FastCaloGpu/Hit.h:16
FPGATrackSimDataPrepAlg::m_doEvtSel
Gaudi::Property< bool > m_doEvtSel
Definition: FPGATrackSimDataPrepAlg.h:90
FPGATrackSimLogicalEventInputHeader::optional
FPGATrackSimOptionalEventInfo const & optional() const
Definition: FPGATrackSimLogicalEventInputHeader.h:32
FPGATrackSimDataPrepAlg::m_spacepoints
std::vector< FPGATrackSimCluster > m_spacepoints
Definition: FPGATrackSimDataPrepAlg.h:105
python.handimod.now
now
Definition: handimod.py:675
AthCommonDataStore
Definition: AthCommonDataStore.h:52
AthAlgorithm::sysInitialize
virtual StatusCode sysInitialize() override
Override sysInitialize.
Definition: AthAlgorithm.cxx:66
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition: AthMsgStreamMacros.h:33
AthCommonDataStore< AthCommonMsg< Algorithm > >::outputHandles
virtual std::vector< Gaudi::DataHandle * > outputHandles() const override
Return this algorithm's output handles.
lumiFormat.i
int i
Definition: lumiFormat.py:85
FPGATrackSimDataPrepAlg::m_doHitFiltering
Gaudi::Property< bool > m_doHitFiltering
Definition: FPGATrackSimDataPrepAlg.h:86
FPGATrackSimDataPrepAlg::m_FPGAHitUnmappedKey
SG::WriteHandleKey< FPGATrackSimHitCollection > m_FPGAHitUnmappedKey
Definition: FPGATrackSimDataPrepAlg.h:123
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
FPGATrackSimDataPrepAlg::m_inputTruthParticleContainerKey
SG::ReadHandleKey< xAOD::TruthParticleContainer > m_inputTruthParticleContainerKey
Definition: FPGATrackSimDataPrepAlg.h:125
xAOD::TruthParticle_v1
Class describing a truth particle in the MC record.
Definition: TruthParticle_v1.h:37
ATH_CHECK
#define ATH_CHECK
Definition: AthCheckMacros.h:40
FPGATrackSimDataPrepAlg::m_clustering
Gaudi::Property< bool > m_clustering
Definition: FPGATrackSimDataPrepAlg.h:87
AthCommonDataStore< AthCommonMsg< Algorithm > >::m_detStore
StoreGateSvc_t m_detStore
Pointer to StoreGate (detector store by default)
Definition: AthCommonDataStore.h:393
SG::VarHandleKey::initialize
StatusCode initialize(bool used=true)
If this object is used as a property, then this should be called during the initialize phase.
Definition: AthToolSupport/AsgDataHandles/Root/VarHandleKey.cxx:103
FPGATrackSimLogicalEventInputHeader::reset
void reset()
SG::VarHandleKeyArray::renounce
virtual void renounce()=0
FPGATrackSimPlaneMap
Definition: FPGATrackSimPlaneMap.h:62
SG::HandleClassifier::type
std::conditional< std::is_base_of< SG::VarHandleKeyArray, T >::value, VarHandleKeyArrayType, type2 >::type type
Definition: HandleClassifier.h:54
merge_scale_histograms.doc
string doc
Definition: merge_scale_histograms.py:9
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:221
FPGATrackSimDataPrepAlg::m_secondInputToolN
Gaudi::Property< int > m_secondInputToolN
Definition: FPGATrackSimDataPrepAlg.h:85
FPGATrackSimDataPrepAlg::m_FPGAClusterKey
SG::WriteHandleKeyArray< FPGATrackSimClusterCollection > m_FPGAClusterKey
Definition: FPGATrackSimDataPrepAlg.h:119
FPGATrackSimDataPrepAlg::m_runOnRDO
Gaudi::Property< bool > m_runOnRDO
Definition: FPGATrackSimDataPrepAlg.h:91
FPGATrackSimDataPrepAlg::m_clusters_original
std::vector< FPGATrackSimCluster > m_clusters_original
Definition: FPGATrackSimDataPrepAlg.h:104
FPGATrackSimDataPrepAlg::m_writeOutputTool
ToolHandle< FPGATrackSimOutputHeaderTool > m_writeOutputTool
Definition: FPGATrackSimDataPrepAlg.h:79
FPGATrackSimEventInputHeader::optional
FPGATrackSimOptionalEventInfo const & optional() const
Definition: FPGATrackSimEventInputHeader.h:33
FPGATrackSimDataPrepAlg::m_clusteringTool
ToolHandle< FPGATrackSimClusteringToolI > m_clusteringTool
Definition: FPGATrackSimDataPrepAlg.h:77
FPGATrackSimDataPrepAlg::m_preClusterBranch
Gaudi::Property< std::string > m_preClusterBranch
Definition: FPGATrackSimDataPrepAlg.h:94
SG::WriteHandle
Definition: StoreGate/StoreGate/WriteHandle.h:76
AthAlgorithm::m_extendedExtraObjects
DataObjIDColl m_extendedExtraObjects
Definition: AthAlgorithm.h:79
FPGATrackSimDataPrepAlg::m_FPGAHitKey
SG::WriteHandleKeyArray< FPGATrackSimHitCollection > m_FPGAHitKey
Definition: FPGATrackSimDataPrepAlg.h:122
FPGATrackSimDataPrepAlg::m_postClusterBranch
Gaudi::Property< std::string > m_postClusterBranch
Definition: FPGATrackSimDataPrepAlg.h:95
a
TList * a
Definition: liststreamerinfos.cxx:10
h
FPGATrackSimDataPrepAlg::m_clusters
std::vector< FPGATrackSimCluster > m_clusters
Definition: FPGATrackSimDataPrepAlg.h:104
FPGATrackSimDataPrepAlg::m_truthLinkContainerKey
SG::WriteHandleKey< xAODTruthParticleLinkVector > m_truthLinkContainerKey
Definition: FPGATrackSimDataPrepAlg.h:126
ATH_MSG_WARNING
#define ATH_MSG_WARNING(x)
Definition: AthMsgStreamMacros.h:32
FPGATrackSimDataPrepAlg::m_firstInputToolN
Gaudi::Property< int > m_firstInputToolN
Definition: FPGATrackSimDataPrepAlg.h:84
FPGATrackSimDataPrepAlg::m_FPGATrackSimMapping
ServiceHandle< IFPGATrackSimMappingSvc > m_FPGATrackSimMapping
Definition: FPGATrackSimDataPrepAlg.h:80
FPGATrackSimDataPrepAlg::m_hits_miss
std::vector< FPGATrackSimHit > m_hits_miss
Definition: FPGATrackSimDataPrepAlg.h:106
SG::VarHandleBase::vhKey
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
Definition: StoreGate/src/VarHandleBase.cxx:623
FPGATrackSimLogicalEventInputHeader::towers
const std::vector< FPGATrackSimTowerInputHeader > & towers() const
Definition: FPGATrackSimLogicalEventInputHeader.h:36
AthAlgorithm::AthAlgorithm
AthAlgorithm()
Default constructor:
FPGATrackSimDataPrepAlg::m_hitInputTool
ToolHandle< IFPGATrackSimEventInputHeaderTool > m_hitInputTool
Definition: FPGATrackSimDataPrepAlg.h:73
python.Bindings.keys
keys
Definition: Control/AthenaPython/python/Bindings.py:798
LHEF::Writer
Pythia8::Writer Writer
Definition: Prophecy4fMerger.cxx:12
Monitored::Scalar
Declare a monitored scalar variable.
Definition: MonitoredScalar.h:34
FPGATrackSimDataPrepAlg::m_firstInputHeader
FPGATrackSimEventInputHeader m_firstInputHeader
Definition: FPGATrackSimDataPrepAlg.h:99
FPGATrackSimEventInputHeader::reset
void reset()
Definition: FPGATrackSimEventInputHeader.cxx:15
FPGATrackSimDataPrepAlg::m_FPGASpacePointsKey
SG::WriteHandleKeyArray< FPGATrackSimClusterCollection > m_FPGASpacePointsKey
Definition: FPGATrackSimDataPrepAlg.h:121
FPGATrackSimDataPrepAlg::processInputs
StatusCode processInputs(SG::WriteHandle< FPGATrackSimHitCollection > &FPGAHitUnmapped, SG::WriteHandle< FPGATrackSimClusterCollection > &FPGAClusters, SG::WriteHandle< FPGATrackSimClusterCollection > &FPGAClustersFiltered, SG::WriteHandle< FPGATrackSimClusterCollection > &FPGASpacePoints)
Definition: FPGATrackSimDataPrepAlg.cxx:297
AthCommonDataStore::declareGaudiProperty
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>
Definition: AthCommonDataStore.h:156
FPGATrackSimDataPrepAlg::m_FPGATruthTrackKey
SG::WriteHandleKey< FPGATrackSimTruthTrackCollection > m_FPGATruthTrackKey
Definition: FPGATrackSimDataPrepAlg.h:128
fitman.k
k
Definition: fitman.py:528
ServiceHandle< ICondSvc >