27 reco_(conf.getParameter<int>(
"firstSample"),conf.getParameter<int>(
"samplesToAdd"),conf.getParameter<bool>(
"correctForTimeslew"),
28 conf.getParameter<bool>(
"correctForPhaseContainment"),conf.getParameter<double>(
"correctionPhaseNS")),
30 inputLabel_(conf.getParameter<edm::InputTag>(
"digiLabel")),
31 firstSample_(conf.getParameter<int>(
"firstSample")),
32 samplesToAdd_(conf.getParameter<int>(
"samplesToAdd")),
33 maxADCvalue_(conf.getParameter<int>(
"maxADCvalue")),
34 tsFromDB_(conf.getParameter<bool>(
"tsFromDB")),
35 setSaturationFlag_(conf.getParameter<bool>(
"setSaturationFlag")),
36 doSaturationCorr_(conf.getParameter<bool>(
"doSaturationCorr"))
39 if (!strcasecmp(subd.c_str(),
"CASTOR")) {
42 produces<CastorRecHitCollection>();
44 edm::LogWarning(
"CastorSimpleReconstructor") <<
"CastorSimpleReconstructor is not associated with CASTOR subdetector!" << std::endl;
67 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;
77 edm::LogWarning(
"CastorSimpleReconstructor") <<
"Could not handle the CastorSaturationCorrsRcd correctly. We'll not try the saturation correction from this event onwards..." << std::endl;
90 for (i=digi->begin(); i!=digi->end(); i++) {
99 const CastorQIECoder* channelCoder = conditions->getCastorCoder (cell);
113 double satCorrConst = 1.;
114 satCorrConst = saturationCorr->
getValue();
T getParameter(std::string const &) const
void resetTimeSamples(int f, int t)
std::vector< T >::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
edm::InputTag inputLabel_
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
static const int SubdetectorId
bool getByLabel(InputTag const &tag, Handle< PROD > &result) const
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()