24 : tunePhaseShift(ps.getUntrackedParameter<double>(
"tunePhaseShiftTB", 1.)),
25 ecalTBInfoLabel(ps.getUntrackedParameter<
std::
string>(
"EcalTBInfoLabel",
"SimEcalTBG4Object")),
30 theHBHEResponse(new
CaloHitResponse(theParameterMap, theHcalIntegratedShape)),
31 theHOResponse(new
CaloHitResponse(theParameterMap, theHcalIntegratedShape)),
32 theAmplifier(nullptr),
33 theCoderFactory(nullptr),
34 theElectronicsSim(nullptr),
35 theTimeSlewSim(nullptr),
139 LogDebug(
"HcalSim") <<
"HcalTBDigiProducer::accumulate trying to get SimHit";
141 if (hcalHandle.isValid()) {
142 std::vector<PCaloHit>
hits = *hcalHandle.product();
143 LogDebug(
"HcalSim") <<
"HcalTBDigiProducer::accumulate Hits corrected";
165 e.getByLabel(hcalTag, hcalHandle);
174 LogDebug(
"HcalSim") <<
"HcalTBDigiProducer::produce Empty collection created";
177 edm::LogVerbatim(
"HcalSim") <<
"HcalTBDigiProducer: HBHE digis : " << hbheResult->size();
179 edm::LogVerbatim(
"HcalSim") <<
"HcalTBDigiProducer: HO digis : " << hoResult->size();
190 for (edm::PCaloHitContainer::const_iterator hitItr =
hits.begin(); hitItr !=
hits.end(); ++hitItr) {
197 edm::LogError(
"HcalSim") <<
"Bad HcalHit subdetector " << subdet;
226 <<
" cells in HB/HE and " <<
hoCells.size() <<
" cells in HO";
229 LogDebug(
"HcalSim") <<
"HcalTBDigiProducer: Set DetID's for HB/HE";
231 LogDebug(
"HcalSim") <<
"HcalTBDigiProducer: Set DetID's for HO";
void setPhaseShift(const DetId &detId)
EDGetTokenT< ProductType > consumes(edm::InputTag const &tag)
Log< level::Info, true > LogVerbatim
void setGeometry(const CaloGeometry *geometry)
geometry needed for time-of-flight
void setDbService(const HcalDbService *service)
the Producer will probably update this every event
void finalizeEvent(edm::Event &e, edm::EventSetup const &c) override
T getParameter(std::string const &) const
void sortHits(const edm::PCaloHitContainer &hits)
fills the vectors for each subdetector
std::vector< PCaloHit > PCaloHitContainer
std::vector< DetId > hoCells
CaloHitResponse * theHBHEResponse
ProductRegistryHelper::BranchAliasSetterT< ProductType > produces()
static PFTauRenderPlugin instance
HBHEHitFilter theHBHEHitFilter
double phaseShift() const
const CaloSimParameters & simParameters(const DetId &id) const override
HcalSimParameterMap * paraMap
HcalElectronicsSim * theElectronicsSim
const edm::ESGetToken< HcalTimeSlew, HcalTimeSlewRecord > hcalTimeSlew_delay_token_
HOHitFilter theHOHitFilter
Log< level::Error, false > LogError
virtual CLHEP::HepRandomEngine & getEngine(StreamID const &)=0
Use this engine in event methods.
HcalTBSimParameterMap * theParameterMap
Main class for Parameters in different subdetectors.
const CaloGeometry * theGeometry
void setPhaseShift(const double &thePhaseShift)
setting the phase shift for asynchronous trigger (e.g. test beams)
const edm::ESGetToken< HcalDbService, HcalDbRecord > conditionsToken_
std::vector< PCaloHit > theHBHEHits
edm::SortedCollection< HODataFrame > HODigiCollection
const edm::EDGetTokenT< std::vector< PCaloHit > > hcalToken_
CaloVShape * theHcalIntegratedShape
void setHitFilter(const CaloVHitFilter *filter)
Creates electronics signals from hits.
void setTimeSlew(const HcalTimeSlew *timeSlew)
void checkGeometry(const edm::EventSetup &eventSetup)
shaper for Hcal (not for HF)
constexpr int subdetId() const
get the contents of the subdetector field (not cast into any detector's numbering enum) ...
HcalTBDigiProducer(const edm::ParameterSet &ps, edm::ProducesCollector, edm::ConsumesCollector &iC)
std::vector< DetId > hbheCells
void accumulate(edm::Event const &e, edm::EventSetup const &c) override
std::vector< PCaloHit > theHOHits
edm::ESWatcher< CaloGeometryRecord > geometryWatcher_
const std::string ecalTBInfoLabel
CaloHitResponse * theHOResponse
void setTimeSlewSim(HcalTimeSlewSim *timeSlewSim)
~HcalTBDigiProducer() override
void setDbService(const HcalDbService *service)
std::vector< DetId > getValidDetIds() const
Get the list of all valid detector ids.
HcalAmplifier * theAmplifier
std::unique_ptr< HBHEDigitizer > theHBHEDigitizer
bool check(const edm::EventSetup &iSetup)
edm::EDGetTokenT< PEcalTBInfo > theEcalTBToken_
CLHEP::HepRandomEngine * randomEngine_
HcalCoderFactory * theCoderFactory
CaloVShape * theHcalShape
void initializeEvent(edm::Event const &e, edm::EventSetup const &c) override
const double tunePhaseShift
std::unique_ptr< HODigitizer > theHODigitizer
const edm::ESGetToken< CaloGeometry, CaloGeometryRecord > geometryToken_
const HcalTimeSlew * hcalTimeSlew_delay_
void accumulateCaloHits(edm::Handle< std::vector< PCaloHit >> const &hits, int bunchCrossing)
edm::SortedCollection< HBHEDataFrame > HBHEDigiCollection
HcalTimeSlewSim * theTimeSlewSim