CMS 3D CMS Logo

List of all members | Public Types | Public Member Functions
SiPixelGainCalibrationServiceBase Class Referenceabstract

#include <SiPixelGainCalibrationServiceBase.h>

Inheritance diagram for SiPixelGainCalibrationServiceBase:
SiPixelGainCalibrationServicePayloadGetter< thePayloadObject, theDBRecordType > SiPixelGainCalibrationServicePayloadGetter< SiPixelGainCalibration, SiPixelGainCalibrationRcd > SiPixelGainCalibrationServicePayloadGetter< SiPixelGainCalibrationForHLT, SiPixelGainCalibrationForHLTRcd > SiPixelGainCalibrationServicePayloadGetter< SiPixelGainCalibrationForHLT, SiPixelGainCalibrationForHLTSimRcd > SiPixelGainCalibrationServicePayloadGetter< SiPixelGainCalibrationOffline, SiPixelGainCalibrationOfflineRcd > SiPixelGainCalibrationServicePayloadGetter< SiPixelGainCalibrationOffline, SiPixelGainCalibrationOfflineSimRcd > SiPixelGainCalibrationService SiPixelGainCalibrationForHLTService SiPixelGainCalibrationForHLTSimService SiPixelGainCalibrationOfflineService SiPixelGainCalibrationOfflineSimService

Public Types

typedef edm::DetSet< PixelDigi >::const_iterator DigiIterator
 

Public Member Functions

virtual void calibrate (uint32_t detID, DigiIterator b, DigiIterator e, float conversionFactor, float offset, int *electron)
 
virtual std::vector< uint32_t > getDetIds ()=0
 
virtual float getGain (const uint32_t &detID, const int &col, const int &row)=0
 
virtual double getGainHigh ()=0
 
virtual double getGainLow ()=0
 
virtual float getPedestal (const uint32_t &detID, const int &col, const int &row)=0
 
virtual double getPedHigh ()=0
 
virtual double getPedLow ()=0
 
virtual bool isDead (const uint32_t &detID, const int &col, const int &row)=0
 
virtual bool isDeadColumn (const uint32_t &detID, const int &col, const int &row)=0
 
virtual bool isNoisy (const uint32_t &detID, const int &col, const int &row)=0
 
virtual bool isNoisyColumn (const uint32_t &detID, const int &col, const int &row)=0
 
virtual void setESObjects (const edm::EventSetup &es)=0
 
 SiPixelGainCalibrationServiceBase ()
 
virtual ~SiPixelGainCalibrationServiceBase ()
 

Detailed Description

Definition at line 28 of file SiPixelGainCalibrationServiceBase.h.

Member Typedef Documentation

Definition at line 31 of file SiPixelGainCalibrationServiceBase.h.

Constructor & Destructor Documentation

SiPixelGainCalibrationServiceBase::SiPixelGainCalibrationServiceBase ( )
inline

Definition at line 34 of file SiPixelGainCalibrationServiceBase.h.

34 {};
virtual SiPixelGainCalibrationServiceBase::~SiPixelGainCalibrationServiceBase ( )
inlinevirtual

Member Function Documentation

void SiPixelGainCalibrationServiceBase::calibrate ( uint32_t  detID,
DigiIterator  b,
DigiIterator  e,
float  conversionFactor,
float  offset,
int *  electron 
)
virtual

Reimplemented in SiPixelGainCalibrationForHLTService.

Definition at line 21 of file SiPixelGainCalibrationService.cc.

References cuy::col, MillePedeFileConverter_cfg::e, getGain(), getPedestal(), i, createfilelist::int, isDead(), and isNoisy().

Referenced by ~SiPixelGainCalibrationServiceBase().

21  {
22  int i=0;
23  for(DigiIterator di = b; di != e; ++di) {
24  int row = di->row();
25  int col = di->column();
26 
27  if ( isDead(detID,col,row) || isNoisy(detID,col,row) ) electron[i++] =0;
28  else {
29  float DBgain = getGain(detID, col, row);
30  float DBpedestal = getPedestal(detID, col, row) * DBgain;
31  float vcal = di->adc() * DBgain - DBpedestal;
32  // float vcal = (di->adc() - DBpedestal) * DBgain;
33  electron[i++] = int( vcal * conversionFactor + offset);
34  }
35  }
36  assert(i==(e-b));
37 }
int i
Definition: DBlmapReader.cc:9
edm::DetSet< PixelDigi >::const_iterator DigiIterator
virtual bool isDead(const uint32_t &detID, const int &col, const int &row)=0
virtual float getPedestal(const uint32_t &detID, const int &col, const int &row)=0
double b
Definition: hdecay.h:120
col
Definition: cuy.py:1008
virtual float getGain(const uint32_t &detID, const int &col, const int &row)=0
virtual bool isNoisy(const uint32_t &detID, const int &col, const int &row)=0
virtual std::vector<uint32_t> SiPixelGainCalibrationServiceBase::getDetIds ( )
pure virtual
virtual float SiPixelGainCalibrationServiceBase::getGain ( const uint32_t &  detID,
const int &  col,
const int &  row 
)
pure virtual
virtual double SiPixelGainCalibrationServiceBase::getGainHigh ( )
pure virtual
virtual double SiPixelGainCalibrationServiceBase::getGainLow ( )
pure virtual
virtual float SiPixelGainCalibrationServiceBase::getPedestal ( const uint32_t &  detID,
const int &  col,
const int &  row 
)
pure virtual
virtual double SiPixelGainCalibrationServiceBase::getPedHigh ( )
pure virtual
virtual double SiPixelGainCalibrationServiceBase::getPedLow ( )
pure virtual
virtual bool SiPixelGainCalibrationServiceBase::isDead ( const uint32_t &  detID,
const int &  col,
const int &  row 
)
pure virtual
virtual bool SiPixelGainCalibrationServiceBase::isDeadColumn ( const uint32_t &  detID,
const int &  col,
const int &  row 
)
pure virtual
virtual bool SiPixelGainCalibrationServiceBase::isNoisy ( const uint32_t &  detID,
const int &  col,
const int &  row 
)
pure virtual
virtual bool SiPixelGainCalibrationServiceBase::isNoisyColumn ( const uint32_t &  detID,
const int &  col,
const int &  row 
)
pure virtual
virtual void SiPixelGainCalibrationServiceBase::setESObjects ( const edm::EventSetup es)
pure virtual