DataFormats
EcalDigi
src
EcalTrigPrimCompactColl.cc
Go to the documentation of this file.
1
#include "
DataFormats/EcalDigi/interface/EcalTrigPrimCompactColl.h
"
2
3
void
EcalTrigPrimCompactColl::toEcalTrigPrimDigiCollection
(
EcalTrigPrimDigiCollection
&
dest
)
const
{
4
const
int
nTtEtaBins = 56;
5
const
int
nTtPhiBins = 72;
6
EcalTrigPrimDigiCollection
tpColl;
7
tpColl.
reserve
(nTtEtaBins * nTtPhiBins);
8
9
for
(
int
zside
= -1;
zside
<= 1;
zside
+= 2) {
10
for
(
int
iabseta = 1; iabseta <= nTtEtaBins / 2; ++iabseta) {
11
EcalSubdetector
subdet = (iabseta <= 17) ?
EcalBarrel
:
EcalEndcap
;
12
for
(
int
iphi
= 1;
iphi
<= 72; ++
iphi
) {
13
const
EcalTrigTowerDetId
ttId
(
zside
, subdet, iabseta,
iphi
,
EcalTrigTowerDetId::SUBDETIJMODE
);
14
EcalTriggerPrimitiveDigi
tp
(
ttId
);
15
const
int
rawTp =
raw
(
ttId
.ieta(),
ttId
.iphi());
16
const
EcalTriggerPrimitiveSample
tps(rawTp);
17
tp
.setSize(1);
18
tp
.setSample(0, tps);
19
tpColl.
push_back
(
tp
);
20
}
21
}
22
}
23
tpColl.
sort
();
24
dest
.swap(tpColl);
25
}
EcalTrigTowerDetId::SUBDETIJMODE
static const int SUBDETIJMODE
Definition:
EcalTrigTowerDetId.h:107
edm::SortedCollection::sort
void sort()
Definition:
SortedCollection.h:302
ecaldqm::zside
int zside(DetId const &)
Definition:
EcalDQMCommonUtils.cc:189
ecaldqm::ttId
unsigned ttId(DetId const &)
Definition:
EcalDQMCommonUtils.cc:101
edm::SortedCollection
Definition:
SortedCollection.h:49
EcalSubdetector
EcalSubdetector
Definition:
EcalSubdetector.h:10
EcalTrigTowerDetId
Definition:
EcalTrigTowerDetId.h:14
edm::SortedCollection::push_back
void push_back(T const &t)
Definition:
SortedCollection.h:188
EcalBarrel
Definition:
EcalSubdetector.h:10
LEDCalibrationChannels.iphi
iphi
Definition:
LEDCalibrationChannels.py:64
cmsswSequenceInfo.tp
tp
Definition:
cmsswSequenceInfo.py:17
EcalEndcap
Definition:
EcalSubdetector.h:10
EcalTrigPrimCompactColl.h
EcalTrigPrimCompactColl::toEcalTrigPrimDigiCollection
void toEcalTrigPrimDigiCollection(EcalTrigPrimDigiCollection &dest) const
Definition:
EcalTrigPrimCompactColl.cc:3
edm::SortedCollection::reserve
void reserve(size_type n)
Definition:
SortedCollection.h:225
EcalTriggerPrimitiveDigi
Definition:
EcalTriggerPrimitiveDigi.h:16
EcalTriggerPrimitiveSample
Definition:
EcalTriggerPrimitiveSample.h:12
EcalTrigPrimCompactColl::raw
uint16_t raw(int ieta, int iphi) const
get the raw word
Definition:
EcalTrigPrimCompactColl.h:50
mps_fire.dest
dest
Definition:
mps_fire.py:179
Generated for CMSSW Reference Manual by
1.8.16