30 trackerGeometry_(&trackerGeometry),
31 trackerTopology_(&trackerTopology),
32 cablingMap_(&cablingMap),
33 stubAlgorithm_(&stubAlgorithm),
34 pSetSA_(&pSetStubAlgorithm),
35 pSetGC_(&pSetGeometryConfiguration),
36 pSetIdTTStubAlgorithm_(pSetIdTTStubAlgorithm),
37 pSetIdGeometryConfiguration_(pSetIdGeometryConfiguration),
39 pSetSG_(iConfig.getParameter<
ParameterSet>(
"SupportedGeometry")),
40 sgXMLLabel_(pSetSG_.getParameter<
string>(
"XMLLabel")),
41 sgXMLPath_(pSetSG_.getParameter<
string>(
"XMLPath")),
42 sgXMLFile_(pSetSG_.getParameter<
string>(
"XMLFile")),
43 sgXMLVersions_(pSetSG_.getParameter<vector<
string>>(
"XMLVersions")),
45 pSetPH_(iConfig.getParameter<
ParameterSet>(
"ProcessHistory")),
46 phGeometryConfiguration_(pSetPH_.getParameter<
string>(
"GeometryConfiguration")),
47 phTTStubAlgorithm_(pSetPH_.getParameter<
string>(
"TTStubAlgorithm")),
49 pSetTF_(iConfig.getParameter<
ParameterSet>(
"TrackFinding")),
50 beamWindowZ_(pSetTF_.getParameter<double>(
"BeamWindowZ")),
51 matchedLayers_(pSetTF_.getParameter<
int>(
"MatchedLayers")),
52 matchedLayersPS_(pSetTF_.getParameter<
int>(
"MatchedLayersPS")),
53 unMatchedStubs_(pSetTF_.getParameter<
int>(
"UnMatchedStubs")),
54 unMatchedStubsPS_(pSetTF_.getParameter<
int>(
"UnMatchedStubsPS")),
57 minPt_(pSetTMTT_.getParameter<double>(
"MinPt")),
58 maxEta_(pSetTMTT_.getParameter<double>(
"MaxEta")),
59 chosenRofPhi_(pSetTMTT_.getParameter<double>(
"ChosenRofPhi")),
60 numLayers_(pSetTMTT_.getParameter<
int>(
"NumLayers")),
61 widthR_(pSetTMTT_.getParameter<
int>(
"WidthR")),
62 widthPhi_(pSetTMTT_.getParameter<
int>(
"WidthPhi")),
63 widthZ_(pSetTMTT_.getParameter<
int>(
"WidthZ")),
65 pSetHybrid_(iConfig.getParameter<
ParameterSet>(
"Hybrid")),
66 hybridMinPt_(pSetHybrid_.getParameter<double>(
"MinPt")),
67 hybridMaxEta_(pSetHybrid_.getParameter<double>(
"MaxEta")),
68 hybridChosenRofPhi_(pSetHybrid_.getParameter<double>(
"ChosenRofPhi")),
69 hybridNumLayers_(pSetHybrid_.getParameter<
int>(
"NumLayers")),
70 hybridNumRingsPS_(pSetHybrid_.getParameter<vector<
int>>(
"NumRingsPS")),
71 hybridWidthsR_(pSetHybrid_.getParameter<vector<
int>>(
"WidthsR")),
72 hybridWidthsZ_(pSetHybrid_.getParameter<vector<
int>>(
"WidthsZ")),
73 hybridWidthsPhi_(pSetHybrid_.getParameter<vector<
int>>(
"WidthsPhi")),
74 hybridWidthsAlpha_(pSetHybrid_.getParameter<vector<
int>>(
"WidthsAlpha")),
75 hybridWidthsBend_(pSetHybrid_.getParameter<vector<
int>>(
"WidthsBend")),
76 hybridRangesR_(pSetHybrid_.getParameter<vector<double>>(
"RangesR")),
77 hybridRangesZ_(pSetHybrid_.getParameter<vector<double>>(
"RangesZ")),
78 hybridRangesAlpha_(pSetHybrid_.getParameter<vector<double>>(
"RangesAlpha")),
79 hybridLayerRs_(pSetHybrid_.getParameter<vector<double>>(
"LayerRs")),
80 hybridDiskZs_(pSetHybrid_.getParameter<vector<double>>(
"DiskZs")),
81 hybridDisk2SRsSet_(pSetHybrid_.getParameter<vector<
ParameterSet>>(
"Disk2SRsSet")),
83 pSetTP_(iConfig.getParameter<
ParameterSet>(
"TrackingParticle")),
84 tpMaxEta_(pSetTP_.getParameter<double>(
"MaxEta")),
85 tpMaxVertR_(pSetTP_.getParameter<double>(
"MaxVertR")),
86 tpMaxVertZ_(pSetTP_.getParameter<double>(
"MaxVertZ")),
87 tpMaxD0_(pSetTP_.getParameter<double>(
"MaxD0")),
88 tpMinLayers_(pSetTP_.getParameter<
int>(
"MinLayers")),
89 tpMinLayersPS_(pSetTP_.getParameter<
int>(
"MinLayersPS")),
92 numFramesInfra_(pSetFW_.getParameter<
int>(
"NumFramesInfra")),
93 freqLHC_(pSetFW_.getParameter<double>(
"FreqLHC")),
94 freqBE_(pSetFW_.getParameter<double>(
"FreqBE")),
95 tmpFE_(pSetFW_.getParameter<
int>(
"TMP_FE")),
96 tmpTFP_(pSetFW_.getParameter<
int>(
"TMP_TFP")),
97 speedOfLight_(pSetFW_.getParameter<double>(
"SpeedOfLight")),
98 bField_(pSetFW_.getParameter<double>(
"BField")),
99 bFieldError_(pSetFW_.getParameter<double>(
"BFieldError")),
100 outerRadius_(pSetFW_.getParameter<double>(
"OuterRadius")),
101 innerRadius_(pSetFW_.getParameter<double>(
"InnerRadius")),
102 halfLength_(pSetFW_.getParameter<double>(
"HalfLength")),
103 maxPitch_(pSetFW_.getParameter<double>(
"MaxPitch")),
105 pSetFE_(iConfig.getParameter<
ParameterSet>(
"FrontEnd")),
106 widthBend_(pSetFE_.getParameter<
int>(
"WidthBend")),
107 widthCol_(pSetFE_.getParameter<
int>(
"WidthCol")),
108 widthRow_(pSetFE_.getParameter<
int>(
"WidthRow")),
109 baseBend_(pSetFE_.getParameter<double>(
"BaseBend")),
110 baseCol_(pSetFE_.getParameter<double>(
"BaseCol")),
111 baseRow_(pSetFE_.getParameter<double>(
"BaseRow")),
112 baseWindowSize_(pSetFE_.getParameter<double>(
"BaseWindowSize")),
113 bendCut_(pSetFE_.getParameter<double>(
"BendCut")),
116 numRegions_(pSetDTC_.getParameter<
int>(
"NumRegions")),
117 numOverlappingRegions_(pSetDTC_.getParameter<
int>(
"NumOverlappingRegions")),
118 numATCASlots_(pSetDTC_.getParameter<
int>(
"NumATCASlots")),
119 numDTCsPerRegion_(pSetDTC_.getParameter<
int>(
"NumDTCsPerRegion")),
120 numModulesPerDTC_(pSetDTC_.getParameter<
int>(
"NumModulesPerDTC")),
121 dtcNumRoutingBlocks_(pSetDTC_.getParameter<
int>(
"NumRoutingBlocks")),
122 dtcDepthMemory_(pSetDTC_.getParameter<
int>(
"DepthMemory")),
123 dtcWidthRowLUT_(pSetDTC_.getParameter<
int>(
"WidthRowLUT")),
124 dtcWidthQoverPt_(pSetDTC_.getParameter<
int>(
"WidthQoverPt")),
125 offsetDetIdDSV_(pSetDTC_.getParameter<
int>(
"OffsetDetIdDSV")),
126 offsetDetIdTP_(pSetDTC_.getParameter<
int>(
"OffsetDetIdTP")),
127 offsetLayerDisks_(pSetDTC_.getParameter<
int>(
"OffsetLayerDisks")),
128 offsetLayerId_(pSetDTC_.getParameter<
int>(
"OffsetLayerId")),
130 pSetGP_(iConfig.getParameter<
ParameterSet>(
"GeometricProcessor")),
131 numSectorsPhi_(pSetGP_.getParameter<
int>(
"NumSectorsPhi")),
132 chosenRofZ_(pSetGP_.getParameter<double>(
"ChosenRofZ")),
133 neededRangeChiZ_(pSetGP_.getParameter<double>(
"RangeChiZ")),
134 gpDepthMemory_(pSetGP_.getParameter<
int>(
"DepthMemory")),
135 boundariesEta_(pSetGP_.getParameter<vector<double>>(
"BoundariesEta")),
137 pSetHT_(iConfig.getParameter<
ParameterSet>(
"HoughTransform")),
138 htNumBinsQoverPt_(pSetHT_.getParameter<
int>(
"NumBinsQoverPt")),
139 htNumBinsPhiT_(pSetHT_.getParameter<
int>(
"NumBinsPhiT")),
140 htMinLayers_(pSetHT_.getParameter<
int>(
"MinLayers")),
141 htDepthMemory_(pSetHT_.getParameter<
int>(
"DepthMemory")),
143 pSetMHT_(iConfig.getParameter<
ParameterSet>(
"MiniHoughTransform")),
144 mhtNumBinsQoverPt_(pSetMHT_.getParameter<
int>(
"NumBinsQoverPt")),
145 mhtNumBinsPhiT_(pSetMHT_.getParameter<
int>(
"NumBinsPhiT")),
146 mhtNumDLB_(pSetMHT_.getParameter<
int>(
"NumDLB")),
147 mhtMinLayers_(pSetMHT_.getParameter<
int>(
"MinLayers")),
149 pSetSF_(iConfig.getParameter<
ParameterSet>(
"SeedFilter")),
150 sfPowerBaseCot_(pSetSF_.getParameter<
int>(
"PowerBaseCot")),
151 sfBaseDiffZ_(pSetSF_.getParameter<
int>(
"BaseDiffZ")),
152 sfMinLayers_(pSetSF_.getParameter<
int>(
"MinLayers")),
154 pSetKF_(iConfig.getParameter<
ParameterSet>(
"KalmanFilter")),
155 kfWidthLutInvPhi_(pSetKF_.getParameter<
int>(
"WidthLutInvPhi")),
156 kfWidthLutInvZ_(pSetKF_.getParameter<
int>(
"WidthLutInvZ")),
157 kfNumTracks_(pSetKF_.getParameter<
int>(
"NumTracks")),
158 kfMinLayers_(pSetKF_.getParameter<
int>(
"MinLayers")),
159 kfMaxLayers_(pSetKF_.getParameter<
int>(
"MaxLayers")),
160 kfMaxStubsPerLayer_(pSetKF_.getParameter<
int>(
"MaxStubsPerLayer")),
161 kfMaxSkippedLayers_(pSetKF_.getParameter<
int>(
"MaxSkippedLayers")),
162 kfBaseShiftr0_(pSetKF_.getParameter<
int>(
"BaseShiftr0")),
163 kfBaseShiftr02_(pSetKF_.getParameter<
int>(
"BaseShiftr02")),
164 kfBaseShiftv0_(pSetKF_.getParameter<
int>(
"BaseShiftv0")),
165 kfBaseShiftS00_(pSetKF_.getParameter<
int>(
"BaseShiftS00")),
166 kfBaseShiftS01_(pSetKF_.getParameter<
int>(
"BaseShiftS01")),
167 kfBaseShiftK00_(pSetKF_.getParameter<
int>(
"BaseShiftK00")),
168 kfBaseShiftK10_(pSetKF_.getParameter<
int>(
"BaseShiftK10")),
169 kfBaseShiftR00_(pSetKF_.getParameter<
int>(
"BaseShiftR00")),
170 kfBaseShiftInvR00_(pSetKF_.getParameter<
int>(
"BaseShiftInvR00")),
171 kfBaseShiftChi20_(pSetKF_.getParameter<
int>(
"BaseShiftChi20")),
172 kfBaseShiftC00_(pSetKF_.getParameter<
int>(
"BaseShiftC00")),
173 kfBaseShiftC01_(pSetKF_.getParameter<
int>(
"BaseShiftC01")),
174 kfBaseShiftC11_(pSetKF_.getParameter<
int>(
"BaseShiftC11")),
175 kfBaseShiftr1_(pSetKF_.getParameter<
int>(
"BaseShiftr1")),
176 kfBaseShiftr12_(pSetKF_.getParameter<
int>(
"BaseShiftr12")),
177 kfBaseShiftv1_(pSetKF_.getParameter<
int>(
"BaseShiftv1")),
178 kfBaseShiftS12_(pSetKF_.getParameter<
int>(
"BaseShiftS12")),
179 kfBaseShiftS13_(pSetKF_.getParameter<
int>(
"BaseShiftS13")),
180 kfBaseShiftK21_(pSetKF_.getParameter<
int>(
"BaseShiftK21")),
181 kfBaseShiftK31_(pSetKF_.getParameter<
int>(
"BaseShiftK31")),
182 kfBaseShiftR11_(pSetKF_.getParameter<
int>(
"BaseShiftR11")),
183 kfBaseShiftInvR11_(pSetKF_.getParameter<
int>(
"BaseShiftInvR11")),
184 kfBaseShiftChi21_(pSetKF_.getParameter<
int>(
"BaseShiftChi21")),
185 kfBaseShiftC22_(pSetKF_.getParameter<
int>(
"BaseShiftC22")),
186 kfBaseShiftC23_(pSetKF_.getParameter<
int>(
"BaseShiftC23")),
187 kfBaseShiftC33_(pSetKF_.getParameter<
int>(
"BaseShiftC33")),
188 kfBaseShiftChi2_(pSetKF_.getParameter<
int>(
"BaseShiftChi2")),
190 pSetDR_(iConfig.getParameter<
ParameterSet>(
"DuplicateRemoval")),
191 drDepthMemory_(pSetDR_.getParameter<
int>(
"DepthMemory")),
192 drWidthPhi0_(pSetDR_.getParameter<
int>(
"WidthPhi0")),
193 drWidthQoverPt_(pSetDR_.getParameter<
int>(
"WidthQoverPt")),
194 drWidthCot_(pSetDR_.getParameter<
int>(
"WidthCot")),
195 drWidthZ0_(pSetDR_.getParameter<
int>(
"WidthZ0")) {
233 vector<pair<string, ParameterSet>> pSets;
234 pSets.reserve(ph.
size());
243 exception.addContext(
"tt::Setup::checkHistory");
246 auto consistent = [&pSetId](
const pair<string, ParameterSet>&
p) {
return p.second.id() == pSetId; };
247 if (!all_of(pSets.begin(), pSets.end(), consistent)) {
250 exception.addContext(
"tt::Setup::checkHistory");
252 exception <<
"Current Configuration:" << endl << pSetProcess.
dump() << endl;
253 for (
const pair<string, ParameterSet>&
p : pSets)
255 exception <<
"Process " <<
p.first <<
" Configuration:" << endl <<
dumpDiff(
p.second, pSetProcess) << endl;
262 stringstream ssHistory, ssProcess,
ss;
263 ssHistory << pSetHistory.
dump();
264 ssProcess << pSetProcess.
dump();
265 string lineHistory, lineProcess;
266 for (; getline(ssHistory, lineHistory) && getline(ssProcess, lineProcess);)
267 ss << (lineHistory != lineProcess ?
"\033[1;31m" :
"") << lineHistory <<
"\033[0m" << endl;
295 const int dtcRegion = tfpRegion - dtcChannel >= 0 ? tfpRegion - dtcChannel : tfpRegion - dtcChannel +
numRegions_;
326 exception.addContext(
"tt::Setup::sensorModule");
335 return encodingsBend.at(windowSize);
350 <<
"Magnetic Field from EventSetup (" << bFieldES <<
") differs more then " <<
bFieldError_
351 <<
" from supported value (" <<
bField_ <<
"). ";
362 if (
begin != string::npos &&
end != string::npos)
368 exception.addContext(
"tt::Setup::checkGeometry");
382 const auto& pSetsTiltedLayer =
pSetSA_->
getParameter<vector<ParameterSet>>(
"TiltedBarrelCutSet");
385 for (
const auto& pSet : pSetsTiltedLayer)
388 for (
const auto& pSet : pSetsEncapDisks)
392 for (
const auto& windows : windowss)
393 for (
const auto&
window : windows)
400 set<double> encoding;
403 encodings.emplace_back(encoding.begin(), encoding.end());
409 vector<vector<DTCELinkId>> dtcELinkIds(
numDTCs_);
410 for (vector<DTCELinkId>& dtcELinkId : dtcELinkIds)
413 dtcELinkIds[
dtcId(dtcLinkId.dtc_id())].push_back(dtcLinkId);
430 exception.addContext(
"tt::Setup::Setup");
473 exception.addContext(
"tt::Setup::Setup");
506 const int baseShiftR =
ceil(log2(rangeR / baseRgen /
pow(2.,
widthR_)));
519 const double hybridRangeR =
521 const double hybridRangePhi =
baseRegion_ + hybridRangeR * hybridRangeQoverPt / 2.;
551 const double maxRangeQoverPt =
max(rangeQoverPt, hybridRangeQoverPt);
617 if (
frame.first.isNull())
683 dynamic_cast<const PixelTopology*>(&(dynamic_cast<const PixelGeomDetUnit*>(det)->specificTopology()));
684 const Plane& plane = dynamic_cast<const PixelGeomDetUnit*>(det)->surface();
685 const MeasurementPoint& mp = ttStubRef->clusterRef(0)->findAverageLocalCoordinatesCentered();
693 exception.addContext(
"trackerDTC::Setup::checkDTCId");
704 exception.addContext(
"trackerDTC::Setup::checkTKLayoutId");
713 const bool oorRegion = tfpRegion >=
numRegions_ || tfpRegion < 0;
714 const bool oorChannel = tfpChannel >=
numDTCsPerTFP_ || tfpChannel < 0;
715 if (oorRegion || oorChannel) {
717 exception.addContext(
"trackerDTC::Setup::checkTFPIdentifier");
719 exception <<
"Requested Processing Region "
720 <<
"(" << tfpRegion <<
") "
721 <<
"is out of range 0 to " <<
numRegions_ - 1 <<
".";
724 <<
"(" << tfpChannel <<
") "