|
ATLAS Offline Software
|
#include <FPGATrackSimMatrixReductionAlgo.h>
|
| FPGATrackSimMatrixReductionAlgo (const std::string &name, ISvcLocator *pSvcLocator) |
|
virtual | ~FPGATrackSimMatrixReductionAlgo ()=default |
|
StatusCode | initialize () override |
|
StatusCode | finalize () override |
|
StatusCode | execute () 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 |
|
|
ServiceHandle< IFPGATrackSimMappingSvc > | m_FPGATrackSimMapping {this, "FPGATrackSimMappingSvc","FPGATrackSimMappingSvc"} |
|
ServiceHandle< ITHistSvc > | m_tHistSvc {this, "THistSvc","THistSvc"} |
|
FPGATrackSimPlaneMap const * | m_pmap_1st = nullptr |
|
FPGATrackSimPlaneMap const * | m_pmap_2nd = nullptr |
|
Gaudi::Property< bool > | m_allregion {this, "allregion", false,"Run all regions?"} |
|
Gaudi::Property< std::string > | m_filePath {this, "LayerChange_path", "default filepath"} |
|
Gaudi::Property< int > | m_region {this, "region", 0, "Region to run"} |
|
Gaudi::Property< int > | m_nRegions {this, "nbank", 96, "Number of regions and thus banks to create"} |
|
int | m_region_start = 0 |
|
int | m_region_end = 0 |
|
std::vector< AccumulateMap > | m_sector_cum |
|
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 |
|
◆ StoreGateSvc_t
◆ FPGATrackSimMatrixReductionAlgo()
FPGATrackSimMatrixReductionAlgo::FPGATrackSimMatrixReductionAlgo |
( |
const std::string & |
name, |
|
|
ISvcLocator * |
pSvcLocator |
|
) |
| |
◆ ~FPGATrackSimMatrixReductionAlgo()
virtual FPGATrackSimMatrixReductionAlgo::~FPGATrackSimMatrixReductionAlgo |
( |
| ) |
|
|
virtualdefault |
◆ copySliceTree()
StatusCode FPGATrackSimMatrixReductionAlgo::copySliceTree |
( |
TFile * |
file | ) |
|
|
private |
Definition at line 62 of file FPGATrackSimMatrixReductionAlgo.cxx.
70 TTree *old_tree = (TTree*)
file->Get(
"slice");
71 old_tree->SetBranchAddress(
"c_max", &
max.qOverPt);
72 old_tree->SetBranchAddress(
"c_min", &
min.qOverPt);
73 old_tree->SetBranchAddress(
"c_slices", &
nBins.qOverPt);
75 old_tree->SetBranchAddress(
"phi_max", &
max.phi);
76 old_tree->SetBranchAddress(
"phi_min", &
min.phi);
77 old_tree->SetBranchAddress(
"phi_slices", &
nBins.phi);
79 old_tree->SetBranchAddress(
"d0_max", &
max.d0);
80 old_tree->SetBranchAddress(
"d0_min", &
min.d0);
81 old_tree->SetBranchAddress(
"d0_slices", &
nBins.d0);
83 old_tree->SetBranchAddress(
"z0_max", &
max.z0);
84 old_tree->SetBranchAddress(
"z0_min", &
min.z0);
85 old_tree->SetBranchAddress(
"z0_slices", &
nBins.z0);
87 old_tree->SetBranchAddress(
"eta_max", &
max.eta);
88 old_tree->SetBranchAddress(
"eta_min", &
min.eta);
89 old_tree->SetBranchAddress(
"eta_slices", &
nBins.eta);
91 old_tree->GetEntry(0);
94 TTree *new_tree =
new TTree(
"slice",
"Slice boundaries");
97 new_tree->Branch(
"c_max", &
max.qOverPt);
98 new_tree->Branch(
"c_min", &
min.qOverPt);
99 new_tree->Branch(
"c_slices", &
nBins.qOverPt);
101 new_tree->Branch(
"phi_max", &
max.phi);
102 new_tree->Branch(
"phi_min", &
min.phi);
103 new_tree->Branch(
"phi_slices", &
nBins.phi);
105 new_tree->Branch(
"d0_max", &
max.d0);
106 new_tree->Branch(
"d0_min", &
min.d0);
107 new_tree->Branch(
"d0_slices", &
nBins.d0);
109 new_tree->Branch(
"z0_max", &
max.z0);
110 new_tree->Branch(
"z0_min", &
min.z0);
111 new_tree->Branch(
"z0_slices", &
nBins.z0);
113 new_tree->Branch(
"eta_max", &
max.eta);
114 new_tree->Branch(
"eta_min", &
min.eta);
115 new_tree->Branch(
"eta_slices", &
nBins.eta);
119 return StatusCode::SUCCESS;
◆ declareGaudiProperty() [1/4]
specialization for handling Gaudi::Property<SG::VarHandleKeyArray>
Definition at line 170 of file AthCommonDataStore.h.
175 hndl.documentation());
◆ declareGaudiProperty() [2/4]
specialization for handling Gaudi::Property<SG::VarHandleKey>
Definition at line 156 of file AthCommonDataStore.h.
161 hndl.documentation());
◆ declareGaudiProperty() [3/4]
specialization for handling Gaudi::Property<SG::VarHandleBase>
Definition at line 184 of file AthCommonDataStore.h.
189 hndl.documentation());
◆ declareGaudiProperty() [4/4]
◆ declareProperty() [1/6]
Declare a new Gaudi property.
- Parameters
-
name | Name of the property. |
hndl | Object holding the property value. |
doc | Documentation string for the property. |
This is the version for types that derive from SG::VarHandleBase
. The property value object is put on the input and output lists as appropriate; then we forward to the base class.
Definition at line 245 of file AthCommonDataStore.h.
250 this->declare(hndl.
vhKey());
251 hndl.
vhKey().setOwner(
this);
253 return PBASE::declareProperty(
name,hndl,
doc);
◆ declareProperty() [2/6]
Declare a new Gaudi property.
- Parameters
-
name | Name of the property. |
hndl | Object holding the property value. |
doc | Documentation string for the property. |
This is the version for types that derive from SG::VarHandleKey
. The property value object is put on the input and output lists as appropriate; then we forward to the base class.
Definition at line 221 of file AthCommonDataStore.h.
229 return PBASE::declareProperty(
name,hndl,
doc);
◆ declareProperty() [3/6]
◆ declareProperty() [4/6]
Declare a new Gaudi property.
- Parameters
-
name | Name of the property. |
property | Object holding the property value. |
doc | Documentation string for the property. |
This is the generic version, for types that do not derive from SG::VarHandleKey
. It just forwards to the base class version of declareProperty
.
Definition at line 333 of file AthCommonDataStore.h.
338 return PBASE::declareProperty(
name, property,
doc);
◆ declareProperty() [5/6]
Declare a new Gaudi property.
- Parameters
-
name | Name of the property. |
property | Object holding the property value. |
doc | Documentation string for the property. |
This dispatches to either the generic declareProperty
or the one for VarHandle/Key/KeyArray.
Definition at line 352 of file AthCommonDataStore.h.
◆ declareProperty() [6/6]
◆ detStore()
◆ evtStore() [1/2]
◆ evtStore() [2/2]
◆ execute()
StatusCode FPGATrackSimMatrixReductionAlgo::execute |
( |
| ) |
|
|
override |
◆ extract_1stStage()
void FPGATrackSimMatrixReductionAlgo::extract_1stStage |
( |
TFile * |
file | ) |
|
|
private |
◆ extraDeps_update_handler()
Add StoreName to extra input/output deps as needed.
use the logic of the VarHandleKey to parse the DataObjID keys supplied via the ExtraInputs and ExtraOuputs Properties to add the StoreName if it's not explicitly given
◆ extraOutputDeps()
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.
57 return Algorithm::extraOutputDeps();
◆ finalize()
StatusCode FPGATrackSimMatrixReductionAlgo::finalize |
( |
| ) |
|
|
override |
◆ initialize()
StatusCode FPGATrackSimMatrixReductionAlgo::initialize |
( |
| ) |
|
|
override |
◆ inputHandles()
Return this algorithm's input handles.
We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.
◆ matchStages()
std::pair< std::vector< size_t >, std::vector< size_t > > FPGATrackSimMatrixReductionAlgo::matchStages |
( |
| ) |
|
|
private |
ultimately we may want a function to get inversion for each specific layer, aka getInversion(ls_2nd.layer), so this is a placeholder;
Definition at line 136 of file FPGATrackSimMatrixReductionAlgo.cxx.
138 size_t iCoord_1st = 0;
150 layers_1st_to_2nd[layer_1st] = ls_2nd.
layer + inversion;
159 return { layers_1st_to_2nd, coords_1st_to_2nd };
◆ msg() [1/2]
◆ msg() [2/2]
◆ msgLvl()
◆ outputHandles()
Return this algorithm's output handles.
We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.
◆ reduce()
Definition at line 181 of file FPGATrackSimMatrixReductionAlgo.cxx.
188 acc_1st.pars = acc_2nd.pars;
189 acc_1st.track_bins = acc_2nd.track_bins;
194 size_t layer_2nd = layers_1st_to_2nd[layer_1st];
195 modules_1st[layer_1st] = modules_2nd[layer_2nd];
196 acc_1st.FTK_modules[layer_1st] = acc_2nd.FTK_modules[layer_2nd];
202 size_t iCoord_2nd = coords_1st_to_2nd[iCoord_1st];
204 acc_1st.hit_coords[iCoord_1st] = acc_2nd.hit_coords[iCoord_2nd];
205 acc_1st.hit_x_QoP [iCoord_1st] = acc_2nd.hit_x_QoP [iCoord_2nd];
206 acc_1st.hit_x_d0 [iCoord_1st] = acc_2nd.hit_x_d0 [iCoord_2nd];
207 acc_1st.hit_x_z0 [iCoord_1st] = acc_2nd.hit_x_z0 [iCoord_2nd];
208 acc_1st.hit_x_eta [iCoord_1st] = acc_2nd.hit_x_eta [iCoord_2nd];
209 acc_1st.hit_x_phi [iCoord_1st] = acc_2nd.hit_x_phi [iCoord_2nd];
216 size_t iCoord_2nd_j = coords_1st_to_2nd[iCoord_1st_j];
222 return { modules_1st, acc_1st };
◆ renounce()
◆ renounceArray()
◆ sysInitialize()
StatusCode AthAlgorithm::sysInitialize |
( |
| ) |
|
|
overridevirtualinherited |
◆ sysStart()
Handle START transition.
We override this in order to make sure that conditions handle keys can cache a pointer to the conditions container.
◆ updateVHKA()
◆ m_allregion
Gaudi::Property<bool> FPGATrackSimMatrixReductionAlgo::m_allregion {this, "allregion", false,"Run all regions?"} |
|
private |
◆ m_detStore
◆ m_evtStore
◆ m_extendedExtraObjects
DataObjIDColl AthAlgorithm::m_extendedExtraObjects |
|
privateinherited |
◆ m_filePath
Gaudi::Property<std::string> FPGATrackSimMatrixReductionAlgo::m_filePath {this, "LayerChange_path", "default filepath"} |
|
private |
◆ m_FPGATrackSimMapping
◆ m_nRegions
Gaudi::Property<int> FPGATrackSimMatrixReductionAlgo::m_nRegions {this, "nbank", 96, "Number of regions and thus banks to create"} |
|
private |
◆ m_pmap_1st
◆ m_pmap_2nd
◆ m_region
Gaudi::Property<int> FPGATrackSimMatrixReductionAlgo::m_region {this, "region", 0, "Region to run"} |
|
private |
◆ m_region_end
int FPGATrackSimMatrixReductionAlgo::m_region_end = 0 |
|
private |
◆ m_region_start
int FPGATrackSimMatrixReductionAlgo::m_region_start = 0 |
|
private |
◆ m_sector_cum
std::vector<AccumulateMap> FPGATrackSimMatrixReductionAlgo::m_sector_cum |
|
private |
◆ m_tHistSvc
ServiceHandle<ITHistSvc> FPGATrackSimMatrixReductionAlgo::m_tHistSvc {this, "THistSvc","THistSvc"} |
|
private |
◆ m_varHandleArraysDeclared
◆ m_vhka
The documentation for this class was generated from the following files:
FPGATrackSimPlaneMap const * m_pmap_2nd
uint32_t getNLogiLayers() const
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
bool accumulate(AccumulateMap &map, std::vector< module_t > const &modules, FPGATrackSimMatrixAccumulator const &acc)
Accumulates an accumulator (e.g.
ServiceHandle< ITHistSvc > m_tHistSvc
void extract_1stStage(TFile *file)
StoreGateSvc_t m_evtStore
Pointer to StoreGate (event store by default)
std::vector< SG::VarHandleKeyArray * > m_vhka
uint32_t getNCoords() const
Gaudi::Property< int > m_nRegions
const LayerSection & getLayerSection(SiliconTech siTech, DetectorZone zone, uint32_t physLayer) const
std::pair< std::vector< module_t >, FPGATrackSimMatrixAccumulator > reduce(std::vector< module_t > const &modules_2nd, FPGATrackSimMatrixAccumulator const &acc_2nd, std::vector< size_t > const &layers_1st_to_2nd, std::vector< size_t > const &coords_1st_to_2nd)
virtual void setOwner(IDataHandleHolder *o)=0
uint32_t getDim(size_t logiLayer) const
Gaudi::Property< std::string > m_filePath
uint32_t getCoordOffset(size_t logiLayer) const
void fillTree(AccumulateMap &map, TTree *tree, int nLayers, int nCoords)
Writes the contents of an AccumulateMap into the supplied tree (one entry per sector).
std::pair< std::vector< size_t >, std::vector< size_t > > matchStages()
virtual StatusCode sysInitialize() override
Override sysInitialize.
virtual std::vector< Gaudi::DataHandle * > outputHandles() const override
Return this algorithm's output handles.
::StatusCode StatusCode
StatusCode definition for legacy code.
const LayerInfo & getLayerInfo(uint32_t layer, uint32_t section) const
Gaudi::Property< int > m_region
StoreGateSvc_t m_detStore
Pointer to StoreGate (detector store by default)
ServiceHandle< IFPGATrackSimMappingSvc > m_FPGATrackSimMapping
Gaudi::Property< bool > m_allregion
virtual void renounce()=0
std::conditional< std::is_base_of< SG::VarHandleKeyArray, T >::value, VarHandleKeyArrayType, type2 >::type type
DataObjIDColl m_extendedExtraObjects
#define ATH_MSG_WARNING(x)
FPGATrackSimPlaneMap const * m_pmap_1st
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
std::vector< AccumulateMap > m_sector_cum
AthAlgorithm()
Default constructor:
reader
read the goodrunslist xml file(s)
StatusCode copySliceTree(TFile *file)
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>