34 if ( minimalPhiSize_ % 2 == 0 || minimalEtaSize_ % 2 == 0)
35 edm::LogError(
"InterestingDetIdCollectionProducerError") <<
"Size of eta/phi should be odd numbers";
75 std::auto_ptr< DetIdCollection > detIdCollection (
new DetIdCollection() ) ;
77 reco::BasicClusterCollection::const_iterator clusIt;
79 for (clusIt=pClusters->begin(); clusIt!=pClusters->end(); clusIt++) {
85 std::vector<std::pair<DetId,float> > clusterDetIds = (*clusIt).hitsAndFractions();
86 std::vector<std::pair<DetId,float> >::iterator posCurrent;
90 for(posCurrent = clusterDetIds.begin(); posCurrent != clusterDetIds.end(); posCurrent++)
93 if ((!((*posCurrent).first.null())) && (itt != recHitsHandle->end()) && ((*itt).energy() >
eMax) )
105 std::vector<std::pair<DetId,float > > xtalsInClus=(*clusIt).hitsAndFractions();
107 for (
unsigned int ii=0;ii<xtalsInClus.size();ii++)
109 if (
std::find(xtalsToStore.begin(),xtalsToStore.end(),xtalsInClus[ii].first) == xtalsToStore.end())
110 xtalsToStore.push_back(xtalsInClus[ii].first);
113 for (
unsigned int iCry=0;iCry<xtalsToStore.size();iCry++)
116 std::find(detIdCollection->begin(),detIdCollection->end(),xtalsToStore[iCry]) == detIdCollection->end()
118 detIdCollection->push_back(xtalsToStore[iCry]);
125 if (
std::find( detIdCollection->begin(), detIdCollection->end(), it->id() ) == detIdCollection->end()
127 detIdCollection->push_back( it->id() );
130 detIdCollection->push_back( it->id() );
T getParameter(std::string const &) const
virtual void produce(edm::Event &, const edm::EventSetup &)
producer
~InterestingDetIdCollectionProducer()
std::vector< T >::const_iterator const_iterator
const EcalSeverityLevelAlgo * severity_
void find(edm::Handle< EcalRecHitCollection > &hits, DetId thisDet, std::vector< EcalRecHitCollection::const_iterator > &hit, bool debug=false)
EcalSeverityLevel severityLevel(const DetId &id, const EcalRecHitCollection &rhs) const
Evaluate status from id.
OrphanHandle< PROD > put(std::auto_ptr< PROD > product)
Put a new product.
InterestingDetIdCollectionProducer(const edm::ParameterSet &)
ctor
int subdetId() const
get the contents of the subdetector field (not cast into any detector's numbering enum) ...
bool getByLabel(InputTag const &tag, Handle< PROD > &result) const
edm::InputTag recHitsLabel_
virtual std::vector< DetId > getWindow(const DetId &id, const int &northSouthSize, const int &eastWestSize) const
void beginRun(edm::Run &, const edm::EventSetup &)
bool null() const
is this a null id ?
T const * product() const
const CaloSubdetectorTopology * getSubdetectorTopology(const DetId &id) const
access the subdetector Topology for the given subdetector directly
edm::InputTag basicClusters_
const CaloTopology * caloTopology_
std::string interestingDetIdCollection_
edm::EDCollection< DetId > DetIdCollection
Detector det() const
get the detector field from this detid