#include <ProvidedPedestalAdditionService.h>
Definition at line 23 of file ProvidedPedestalAdditionService_service.cc.
28 const string myname =
"ProvidedPedestalAdditionService::ctor: ";
30 bool haveSeed = pset.get_if_present<
int>(
"RandomSeed",
m_RandomSeed);
31 pset.get_if_present<
int>(
"LogLevel",
m_LogLevel);
34 if (
m_LogLevel > 0 ) cout << myname <<
"WARNING: Using hardwired seed." <<
endl;
37 string rname =
"ProvidedPedestalAdditionService";
38 if (
m_LogLevel > 0 ) cout << myname <<
"Using NuRandomService." <<
endl;
40 m_pran =
new HepJamesRandom;
42 seedSvc->registerEngine(NuRandomService::CLHEPengineSeeder(
m_pran), rname);
46 m_PedNoiseHist = tfs->make<TH1F>(
"PedNoise",
";Pedestal noise (ADC);", 1000, -10., 10.);
TH1 * m_PedNoiseHist
Histogram of pedestal noise counts.
const lariov::DetPedestalProvider & m_PedestalProvider
CLHEP::HepRandomEngine * m_pran
QTextStream & endl(QTextStream &s)
ProvidedPedestalAdditionService::~ProvidedPedestalAdditionService |
( |
| ) |
|
Definition at line 51 of file ProvidedPedestalAdditionService_service.cc.
52 const string myname =
"ProvidedPedestalAdditionService::dtor: ";
54 cout << myname <<
"Deleting random engine with seed " <<
m_pran->getSeed() <<
endl;
CLHEP::HepRandomEngine * m_pran
QTextStream & endl(QTextStream &s)
int ProvidedPedestalAdditionService::addPedestal |
( |
Channel |
chan, |
|
|
AdcSignalVector & |
sigs, |
|
|
float & |
ped, |
|
|
float & |
pedrms |
|
) |
| const |
|
virtual |
Implements PedestalAdditionService.
Definition at line 62 of file ProvidedPedestalAdditionService_service.cc.
66 for (
unsigned int itck=0; itck<sigs.size(); ++itck ) {
67 sigs[itck] += ped_mean;
71 for (
unsigned int itck=0; itck<sigs.size(); ++itck ) {
72 double ped_variation = rGauss_Ped.fire();
74 sigs[itck] += ped_variation;
virtual float PedRms(raw::ChannelID_t ch) const =0
TH1 * m_PedNoiseHist
Histogram of pedestal noise counts.
const lariov::DetPedestalProvider & m_PedestalProvider
CLHEP::HepRandomEngine * m_pran
virtual float PedMean(raw::ChannelID_t ch) const =0
Retrieve pedestal information.
ostream & ProvidedPedestalAdditionService::print |
( |
std::ostream & |
out = std::cout , |
|
|
std::string |
prefix = "" |
|
) |
| const |
|
virtual |
int ProvidedPedestalAdditionService::m_LogLevel |
|
private |
float ProvidedPedestalAdditionService::m_NoiseScale |
|
private |
TH1* ProvidedPedestalAdditionService::m_PedNoiseHist |
|
private |
CLHEP::HepRandomEngine* ProvidedPedestalAdditionService::m_pran |
|
private |
int ProvidedPedestalAdditionService::m_RandomSeed |
|
private |
The documentation for this class was generated from the following files: