src
CalibFormats
CaloTPG
src
EcalTPGCompressor.cc
Go to the documentation of this file.
1
#include "
CalibFormats/CaloTPG/interface/CaloTPGTranscoder.h
"
2
#include "
CalibFormats/CaloTPG/interface/EcalTPGCompressor.h
"
3
4
EcalTPGCompressor::EcalTPGCompressor
(
const
CaloTPGTranscoder
* coder) : coder_(coder) {}
5
6
void
EcalTPGCompressor::compress
(
const
IntegerCaloSamples
&
ics
,
7
const
std::vector<bool>& fineGrain,
8
EcalTriggerPrimitiveDigi
& digi)
const
{
9
digi.
setSize
(
ics
.size());
10
for
(
int
i
= 0;
i
<
ics
.size();
i
++)
11
digi.
setSample
(
i
,
coder_
->
ecalCompress
(
ics
.id(),
ics
[
i
], fineGrain[
i
]));
12
}
13
14
EcalTriggerPrimitiveSample
EcalTPGCompressor::compress
(
const
EcalTrigTowerDetId
&
id
,
15
unsigned
int
sample
,
16
bool
fineGrain)
const
{
17
return
coder_
->
ecalCompress
(
id
,
sample
, fineGrain);
18
}
EcalTriggerPrimitiveDigi
Definition:
EcalTriggerPrimitiveDigi.h:16
EcalTPGCompressor::EcalTPGCompressor
EcalTPGCompressor(const CaloTPGTranscoder *coder)
Definition:
EcalTPGCompressor.cc:4
IntegerCaloSamples
Definition:
IntegerCaloSamples.h:16
mps_fire.i
i
Definition:
mps_fire.py:429
EcalTrigTowerDetId
Definition:
EcalTrigTowerDetId.h:14
unpacker2007h4_cff.ics
ics
Definition:
unpacker2007h4_cff.py:8
CaloTPGTranscoder.h
EcalTriggerPrimitiveSample
Definition:
EcalTriggerPrimitiveSample.h:12
ecalGpuTask_cfi.sample
sample
Definition:
ecalGpuTask_cfi.py:48
EcalTriggerPrimitiveDigi::setSize
void setSize(int size)
Definition:
EcalTriggerPrimitiveDigi.cc:60
EcalTriggerPrimitiveDigi::setSample
void setSample(int i, const EcalTriggerPrimitiveSample &sam)
Definition:
EcalTriggerPrimitiveDigi.h:36
EcalTPGCompressor::compress
void compress(const IntegerCaloSamples &ics, const std::vector< bool > &fineGrain, EcalTriggerPrimitiveDigi &digi) const
Definition:
EcalTPGCompressor.cc:6
CaloTPGTranscoder::ecalCompress
virtual EcalTriggerPrimitiveSample ecalCompress(const EcalTrigTowerDetId &id, unsigned int sample, bool fineGrain) const =0
Compression from linear samples+fine grain in the ECAL.
EcalTPGCompressor.h
EcalTPGCompressor::coder_
const CaloTPGTranscoder * coder_
Definition:
EcalTPGCompressor.h:21
CaloTPGTranscoder
Definition:
CaloTPGTranscoder.h:24
Generated for CMSSW Reference Manual by
1.8.14