7 for (
int i = 0;
i < 2; ++
i)
8 for (
int j = 0;
j < 2; ++
j)
9 for (
int k = 0;
k < 40; ++
k)
10 for (
int m = 0;
m < 40; ++
m) {
16 int nLines,
z, iz, ip, ix, iy, fed, kchip, pace, bundle, fiber, optorx;
23 file >> iz >> ip >> ix >> iy >> fed >> kchip >> pace >> bundle >> fiber >> optorx;
30 fed_[
z - 1][ip - 1][ix - 1][iy - 1] = fed;
31 kchip_[
z - 1][ip - 1][ix - 1][iy - 1] = kchip;
36 <<
"ESElectronicsMapper::ESElectronicsMapper : Look up table file can not be found in " 41 int eefed[18] = {601, 602, 603, 604, 605, 606, 607, 608, 609, 646, 647, 648, 649, 650, 651, 652, 653, 654};
42 int nesfed[18] = {10, 7, 9, 10, 8, 10, 8, 10, 8, 10, 7, 8, 8, 8, 9, 8, 10, 10};
43 int esfed[18][10] = {{520, 522, 523, 531, 532, 534, 535, 545, 546, 547},
44 {520, 522, 523, 534, 535, 546, 547},
45 {520, 522, 523, 524, 525, 534, 535, 537, 539},
46 {520, 522, 523, 524, 525, 534, 535, 537, 539, 540},
47 {522, 523, 524, 525, 535, 537, 539, 540},
48 {524, 525, 528, 529, 530, 537, 539, 540, 541, 542},
49 {528, 529, 530, 531, 532, 541, 542, 545},
50 {528, 529, 530, 531, 532, 541, 542, 545, 546, 547},
51 {529, 530, 531, 532, 542, 545, 546, 547},
52 {548, 549, 551, 560, 561, 563, 564, 572, 573, 574},
53 {548, 549, 560, 561, 563, 564, 574},
54 {548, 549, 551, 553, 563, 564, 565, 566},
55 {551, 553, 554, 563, 564, 565, 566, 568},
56 {553, 554, 555, 556, 565, 566, 568, 570},
57 {553, 554, 555, 556, 565, 566, 568, 570, 571},
58 {553, 554, 555, 556, 557, 568, 570, 571},
59 {555, 556, 557, 560, 561, 570, 571, 572, 573, 574},
60 {548, 549, 557, 560, 561, 570, 571, 572, 573, 574}};
62 for (
int i = 0;
i < 18; ++
i) {
63 std::vector<int> esFeds;
64 esFeds.reserve(nesfed[
i]);
65 for (
int esFed = 0; esFed < nesfed[
i]; esFed++)
66 esFeds.emplace_back(esfed[
i][esFed]);
78 return fed_[
zside - 1][
id.plane() - 1][
id.six() - 1][
id.siy() - 1];
84 std::vector<int> esFEDs;
90 for (
int eeFED : eeFEDs) {
91 std::map<int, std::vector<int> >::const_iterator itr =
ee_es_map_.find(eeFED);
94 std::vector<int> fed = itr->second;
96 esFEDs.emplace_back(
j);
100 sort(esFEDs.begin(), esFEDs.end());
101 std::vector<int>::iterator it =
unique(esFEDs.begin(), esFEDs.end());
102 esFEDs.erase(it, esFEDs.end());
112 return kchip_[
zside - 1][
id.plane() - 1][
id.six() - 1][
id.siy() - 1];
Log< level::Info, true > LogVerbatim
T getParameter(std::string const &) const
std::string fullPath() const
int getKCHIP(const ESDetId &id)
std::vector< int > GetListofFEDs(const std::vector< int > &eeFEDs) const
def unique(seq, keepstr=True)
ESElectronicsMapper(const edm::ParameterSet &ps)
std::map< int, std::vector< int > > ee_es_map_
int getFED(const ESDetId &id)