51 hitProducer_ = ps.
getParameter<std::string>(
"hitProducer");
52 hitCollection_ = ps.
getParameter<std::string>(
"hitCollection");
53 reducedHitCollection_ = ps.
getParameter<std::string>(
"reducedHitCollection");
54 DeadChannelFileName_ = ps.
getParameter<std::string>(
"DeadChannelsFile");
56 produces< EcalRecHitCollection >(reducedHitCollection_);
83 iEvent.
getByLabel(hitProducer_, hitCollection_, rhcHandle);
84 if (!(rhcHandle.isValid()))
99 double NewEnergy =it->energy();
102 std::vector<EBDetId>::const_iterator DeadCell;
103 for(DeadCell=ChannelsDeadID.begin();DeadCell<ChannelsDeadID.end();DeadCell++){
104 if(it->detid()==*DeadCell){
118 EcalRecHit NewHit(it->id(),NewEnergy,it->time());
119 redCollection->push_back( NewHit );
124 iEvent.
put(redCollection, reducedHitCollection_);
138 printf(
"Dead Channels FILE: %s\n",DeadChannelFileName_.c_str());
139 DeadCha = fopen(DeadChannelFileName_.c_str(),
"r");
144 while(fileStatus != EOF) {
145 fileStatus = fscanf(DeadCha,
"%d %d\n",&ieta,&iphi);
147 if(ieta==-10000||iphi==-10000){
break;}
149 ChannelsDeadID.push_back(cell);
T getParameter(std::string const &) const
DEFINE_FWK_MODULE(TauMET)
std::vector< EcalRecHit >::const_iterator const_iterator
OrphanHandle< PROD > put(std::auto_ptr< PROD > product)
Put a new product.
bool getByLabel(InputTag const &tag, Handle< PROD > &result) const
virtual void produce(edm::Event &, const edm::EventSetup &)
EcalChannelKiller(const edm::ParameterSet &)