25 {
26
27 typedef struct SpIndexPair {
28 public:
29
30 struct compareZ {
31 public:
32 bool operator()(const std::pair<int, const TrigSiSpacePointBase*>& p1, const std::pair<int, const TrigSiSpacePointBase*>& p2) {
33 return p1.second->z() <
p2.second->z();
34 }
35 };
36
37 struct compareR {
38 public:
39 bool operator()(const std::pair<int, const TrigSiSpacePointBase*>& p1, const std::pair<int, const TrigSiSpacePointBase*>& p2) {
40 return p1.second->r() <
p2.second->r();
41 }
42 };
43
44 } SP_INDEX_PAIR;
45
46
47
48
49 const std::vector<short>& pixelLayers =
m_accelSvc->getLayerInformation(1);
50 const std::vector<short>& layerTypes =
m_accelSvc->getLayerInformation(0);
51
52
53
54
56 const size_t bufferOffset = 256;
57 size_t totalSize = bufferOffset+dataTypeSize;
59
61
62
63 memset(pJ,0,dataTypeSize);
64
66
74
76
86
87
88 bool isRoiFullscan = ((roi->
etaPlus() >= 4) && (roi->
etaMinus() <= -4));
89 if(!(isRoiFullscan || roi->
composite() )){
90
91
93
96 }
97
100
102
103 unsigned int nSP = vsp.size();
106 ATH_MSG_WARNING(
"MAX_NUMBER_SPACEPOINTS exceeded, exported data truncated ...");
107 }
108
109
110
112 int nLayers = static_cast<int>(layerTypes.size());
114
115 std::vector<std::vector<std::pair<int, const TrigSiSpacePointBase*> > > phiLArray;
116 phiLArray.resize(nLayers*nSlices);
117
118 for(
unsigned int i=0;
i<nSP;
i++) {
119 const TrigSiSpacePointBase&
sp = vsp[
i];
120 const std::pair<IdentifierHash, IdentifierHash>& els =
sp.offlineSpacePoint()->elementIdList();
121
122 IdentifierHash hashId = els.first;
123 short layerId = pixelLayers[hashId];
124
125 int phiIdx = (
sp.phi()+
M_PI)/phiSliceWidth;
128 }
129 else if (phiIdx < 0) {
132 }
133
134 std::vector<std::pair<int, const TrigSiSpacePointBase*> >&
v = phiLArray[layerId + phiIdx*nLayers];
135 v.push_back(std::pair<int, const TrigSiSpacePointBase*>(i,&
sp));
136 }
137
138
139 int layerIdx=0;
140 for(std::vector<short>::const_iterator it = layerTypes.begin();it!=layerTypes.end();++it, layerIdx++) {
141 short barrel_ec = (*it);
143 std::vector<std::pair<int, const TrigSiSpacePointBase*> >&
v = phiLArray[layerIdx +
slice*nLayers];
144 if(barrel_ec==0)
std::sort(
v.begin(),
v.end(), SP_INDEX_PAIR::compareZ());
145 else std::sort(
v.begin(),
v.end(), SP_INDEX_PAIR::compareR());
146 }
147 }
148
153
154 int spIdx=0;
157 int layerStart = spIdx;
159 std::vector<std::pair<int, const TrigSiSpacePointBase*> >&
v = phiLArray[
layer +
slice*nLayers];
160 for(std::vector<std::pair<int, const TrigSiSpacePointBase*> >::iterator it =
v.begin();it!=
v.end();++it) {
161 const TrigSiSpacePointBase*
sp = (*it).second;
162 const Trk::SpacePoint* osp =
sp->offlineSpacePoint();
163 const InDet::PixelCluster* pCL =
dynamic_cast<const InDet::PixelCluster*
>(osp->
clusterList().first);
165 if (!isBarrel && clusterWidth > 0.2) continue;
166
167 sps.
m_index[spIdx] = (*it).first;
169 sps.
m_x[spIdx] =
sp->x();
170 sps.
m_y[spIdx] =
sp->y();
171 sps.
m_z[spIdx] =
sp->z();
172 sps.
m_r[spIdx] =
sp->r();
177 spIdx++;
178 }
179 int layerEnd = spIdx;
182 }
183 }
184
186
187}
#define ATH_MSG_WARNING(x)
static unsigned int totalSize(const MultiDimArray< T, N > &ht)
virtual double phiPlus() const =0
extreme phi values
virtual double zedPlus() const =0
the zed and eta values at the most forward and most rear ends of the RoI
virtual double phiMinus() const =0
virtual double zedMinus() const =0
virtual double etaMinus() const =0
virtual double etaPlus() const =0
virtual bool composite() const =0
Super RoI access methods.
const InDet::SiWidth & width() const
return width class reference
const Amg::Vector2D & widthPhiRZ() const
const std::pair< const PrepRawData *, const PrepRawData * > & clusterList() const
return the pair of cluster pointers by reference
struct TrigAccel::ITk::SeedMakingJob SEED_MAKING_JOB
struct TrigAccel::ITk::SeedFinderSettings SEED_FINDER_SETTINGS
struct TrigAccel::ITk::SpacePointStorage SPACEPOINT_STORAGE
static constexpr unsigned int MAX_NUMBER_SPACEPOINTS
void sort(typename DataModel_detail::iterator< DVL > beg, typename DataModel_detail::iterator< DVL > end)
Specialization of sort for DataVector/List.
unsigned int m_minEndcapPix
float m_tripletD0_PPS_Max
unsigned int m_maxTripletBufferLength
unsigned int m_maxEndcapPix
unsigned int m_maxSiliconLayer
unsigned int m_maxBarrelPix
SPACEPOINT_STORAGE m_data
SEED_FINDER_SETTINGS m_settings
int m_layerEnd[MAX_SILICON_LAYERS]
int m_layerBegin[MAX_SILICON_LAYERS]
int m_type[MAX_NUMBER_SPACEPOINTS]
float m_clusterWidth[MAX_NUMBER_SPACEPOINTS]
float m_z[MAX_NUMBER_SPACEPOINTS]
SPACEPOINT_LAYER_RANGE m_phiSlices[MAX_PHI_SLICES]
int m_index[MAX_NUMBER_SPACEPOINTS]
float m_phi[MAX_NUMBER_SPACEPOINTS]
float m_x[MAX_NUMBER_SPACEPOINTS]
float m_covZ[MAX_NUMBER_SPACEPOINTS]
float m_covR[MAX_NUMBER_SPACEPOINTS]
float m_y[MAX_NUMBER_SPACEPOINTS]
float m_r[MAX_NUMBER_SPACEPOINTS]
unsigned int m_maxTripletBufferLength
float m_tripletD0_PPS_Max