RecoLocalTracker
SiStripZeroSuppression
interface
SiStripPedestalsSubtractor.h
Go to the documentation of this file.
1
#ifndef RECOLOCALTRACKER_SISTRIPZEROSUPPRESSION_SISTRIPPEDESTALSSUBTRACTOR_H
2
#define RECOLOCALTRACKER_SISTRIPZEROSUPPRESSION_SISTRIPPEDESTALSSUBTRACTOR_H
3
4
#include "
FWCore/Framework/interface/EventSetup.h
"
5
#include "
FWCore/Framework/interface/ESWatcher.h
"
6
#include "
FWCore/Framework/interface/ConsumesCollector.h
"
7
8
#include "
DataFormats/Common/interface/DetSetVector.h
"
9
#include "
DataFormats/SiStripDigi/interface/SiStripRawDigi.h
"
10
#include "
CondFormats/SiStripObjects/interface/SiStripPedestals.h
"
11
#include "
CondFormats/DataRecord/interface/SiStripPedestalsRcd.h
"
12
#include <vector>
13
14
class
SiStripPedestalsSubtractor
{
15
friend
class
SiStripRawProcessingFactory
;
16
17
public
:
18
void
subtract
(
const
edm::DetSet<SiStripRawDigi>
&
input
, std::vector<int16_t>&
output
);
19
void
subtract
(uint32_t detId, uint16_t firstAPV, std::vector<int16_t>& adcs);
20
void
init
(
const
edm::EventSetup
&);
21
22
private
:
23
SiStripPedestalsSubtractor
(
bool
mode
,
edm::ConsumesCollector
iC)
24
:
pedestalsToken_
(iC.esConsumes<
SiStripPedestals
,
SiStripPedestalsRcd
>()),
fedmode_
(
mode
) {}
25
edm::ESGetToken<SiStripPedestals, SiStripPedestalsRcd>
pedestalsToken_
;
26
edm::ESWatcher<SiStripPedestalsRcd>
pedestalsWatcher_
;
27
const
SiStripPedestals
*
pedestalsHandle
;
28
std::vector<int>
pedestals
;
29
bool
fedmode_
;
30
31
template
<
class
input_t>
32
void
subtract_
(uint32_t detId, uint16_t firstAPV,
const
input_t&
input
, std::vector<int16_t>&
output
);
33
int16_t
eval
(int16_t
in
) {
return
in
; }
34
uint16_t
eval
(
SiStripRawDigi
in
) {
return
in
.adc(); }
35
};
36
#endif
input
static const std::string input
Definition:
EdmProvDump.cc:48
edm::ESWatcher< SiStripPedestalsRcd >
edm::DetSet
Definition:
DetSet.h:23
convertSQLitetoXML_cfg.output
output
Definition:
convertSQLitetoXML_cfg.py:72
SiStripRawProcessingFactory
Definition:
SiStripRawProcessingFactory.h:15
SiStripPedestalsSubtractor::pedestals
std::vector< int > pedestals
Definition:
SiStripPedestalsSubtractor.h:28
SiStripRawDigi.h
ALCARECOPromptCalibProdSiPixelAli0T_cff.mode
mode
Definition:
ALCARECOPromptCalibProdSiPixelAli0T_cff.py:96
SiStripPedestalsSubtractor::SiStripPedestalsSubtractor
SiStripPedestalsSubtractor(bool mode, edm::ConsumesCollector iC)
Definition:
SiStripPedestalsSubtractor.h:23
SiStripPedestalsSubtractor::fedmode_
bool fedmode_
Definition:
SiStripPedestalsSubtractor.h:29
SiStripPedestalsSubtractor::pedestalsToken_
edm::ESGetToken< SiStripPedestals, SiStripPedestalsRcd > pedestalsToken_
Definition:
SiStripPedestalsSubtractor.h:25
SiStripPedestalsSubtractor::pedestalsHandle
const SiStripPedestals * pedestalsHandle
Definition:
SiStripPedestalsSubtractor.h:27
SiStripPedestalsSubtractor::pedestalsWatcher_
edm::ESWatcher< SiStripPedestalsRcd > pedestalsWatcher_
Definition:
SiStripPedestalsSubtractor.h:26
SiStripPedestalsSubtractor
Definition:
SiStripPedestalsSubtractor.h:14
SiStripPedestalsRcd
Definition:
SiStripCondDataRecords.h:43
SiStripRawDigi
A Digi for the silicon strip detector, containing only adc information, and suitable for storing raw ...
Definition:
SiStripRawDigi.h:15
SiStripPedestalsRcd.h
SiStripPedestalsSubtractor::subtract_
void subtract_(uint32_t detId, uint16_t firstAPV, const input_t &input, std::vector< int16_t > &output)
Definition:
SiStripPedestalsSubtractor.cc:19
recoMuon::in
Definition:
RecoMuonEnumerators.h:6
edm::EventSetup
Definition:
EventSetup.h:57
DetSetVector.h
edm::ESGetToken< SiStripPedestals, SiStripPedestalsRcd >
SiStripPedestalsSubtractor::subtract
void subtract(const edm::DetSet< SiStripRawDigi > &input, std::vector< int16_t > &output)
Definition:
SiStripPedestalsSubtractor.cc:14
ESWatcher.h
SiStripPedestalsSubtractor::eval
int16_t eval(int16_t in)
Definition:
SiStripPedestalsSubtractor.h:33
SiStripPedestals.h
EventSetup.h
SiStripPedestalsSubtractor::eval
uint16_t eval(SiStripRawDigi in)
Definition:
SiStripPedestalsSubtractor.h:34
SiStripPedestals
Definition:
SiStripPedestals.h:27
ConsumesCollector.h
edm::ConsumesCollector
Definition:
ConsumesCollector.h:45
SiStripPedestalsSubtractor::init
void init(const edm::EventSetup &)
Definition:
SiStripPedestalsSubtractor.cc:5
Generated for CMSSW Reference Manual by
1.8.16