26 reco_(conf.getParameter<int>(
"firstSample"),conf.getParameter<int>(
"samplesToAdd"),conf.getParameter<bool>(
"correctForTimeslew"),
27 conf.getParameter<bool>(
"correctForPhaseContainment"),conf.getParameter<double>(
"correctionPhaseNS")),
29 firstSample_(conf.getParameter<int>(
"firstSample")),
30 samplesToAdd_(conf.getParameter<int>(
"samplesToAdd")),
31 maxADCvalue_(conf.getParameter<int>(
"maxADCvalue")),
32 tsFromDB_(conf.getParameter<bool>(
"tsFromDB")),
33 setSaturationFlag_(conf.getParameter<bool>(
"setSaturationFlag")),
34 doSaturationCorr_(conf.getParameter<bool>(
"doSaturationCorr"))
40 if (!strcasecmp(subd.c_str(),
"CASTOR")) {
43 produces<CastorRecHitCollection>();
45 edm::LogWarning(
"CastorSimpleReconstructor") <<
"CastorSimpleReconstructor is not associated with CASTOR subdetector!" << std::endl;
68 edm::LogWarning(
"CastorSimpleReconstructor") <<
"Could not handle the CastorRecoParamsRcd correctly, using parameters from cfg file from this event onwards... These parameters could be wrong for this run... please check" << std::endl;
78 edm::LogWarning(
"CastorSimpleReconstructor") <<
"Could not handle the CastorSaturationCorrsRcd correctly. We'll not try the saturation correction from this event onwards..." << std::endl;
91 for (i=digi->begin(); i!=digi->end(); i++) {
100 const CastorQIECoder* channelCoder = conditions->getCastorCoder (cell);
114 double satCorrConst = 1.;
115 satCorrConst = saturationCorr->
getValue();
T getParameter(std::string const &) const
void resetTimeSamples(int f, int t)
bool getByToken(EDGetToken token, Handle< PROD > &result) const
std::vector< CastorDataFrame >::const_iterator const_iterator
virtual void produce(edm::Event &e, const edm::EventSetup &c)
CastorSimpleReconstructor(const edm::ParameterSet &ps)
CastorRecHit reconstruct(const CastorDataFrame &digi, const CastorCoder &coder, const CastorCalibrations &calibs) const
uint32_t rawId() const
get the raw id
CastorSimpleRecAlgo reco_
OrphanHandle< PROD > put(std::auto_ptr< PROD > product)
Put a new product.
unsigned int samplesToAdd() const
edm::EDGetTokenT< CastorDigiCollection > tok_input_
static const int SubdetectorId
unsigned int firstSample() const
void recoverADCSaturation(CastorRecHit &rechit, const CastorCoder &coder, const CastorCalibrations &calibs, const CastorDataFrame &digi, const int &maxADCvalue, const double &satCorrConst) const
void checkADCSaturation(CastorRecHit &rechit, const CastorDataFrame &digi, const int &maxADCvalue) const
virtual ~CastorSimpleReconstructor()