64 consumes<SiStripRecHit2DCollection>(
edm::InputTag(siHitProducer_,siRphiHitCollection_));
66 consumes<SiStripRecHit2DCollection>(
edm::InputTag(siHitProducer_,siStereoHitCollection_));
68 consumes<SiStripMatchedRecHit2DCollection>(
edm::InputTag(siHitProducer_,siMatchedHitCollection_));
70 consumes<reco::SuperClusterCollection>(
edm::InputTag(superClusterProducer_,superClusterCollection_));
80 LogDebug(
"") <<
" Welcome to SiStripElectronProducer " ;
137 algo_p->
prepareEvent(trackerHandle, rphiHitsHandle, stereoHitsHandle, matchedHitsHandle, magneticFieldHandle);
140 auto electronOut = std::make_unique<reco::SiStripElectronCollection>();
141 auto trackCandidateOut = std::make_unique<TrackCandidateCollection>();
149 int siStripElectCands = 0 ;
151 std::ostringstream
str;
155 str <<
"Starting loop over superclusters."<<
"\n" << std::endl;
156 for (
unsigned int i = 0;
i < superClusterHandle.
product()->size();
i++) {
158 double energy = sc->
energy();
161 str <<
"Supercluster energy: " << energy <<
", FOUND an electron." <<
"\n" << std::endl;
162 ++siStripElectCands ;
165 str <<
"Supercluster energy: " << energy <<
", DID NOT FIND an electron."<<
"\n" << std::endl;
168 str <<
"Ending loop over superclusters." <<
"\n" << std::endl;
170 str <<
" Found " << siStripElectCands
171 <<
" SiStripElectron Candidates before track fit " 172 <<
"\n" << std::endl ;
174 LogDebug(
"SiStripElectronProducer") << str.str();
T getParameter(std::string const &) const
OrphanHandle< PROD > put(std::unique_ptr< PROD > product)
Put a new product.
bool getByToken(EDGetToken token, Handle< PROD > &result) const
std::string siRphiHitCollection_
SiStripElectronProducer(const edm::ParameterSet &)
edm::EDGetTokenT< reco::SuperClusterCollection > superClustertag_
std::string siHitProducer_
std::string siStereoHitCollection_
std::string siStripElectronsLabel_
edm::Ref< SuperClusterCollection > SuperClusterRef
reference to an object in a collection of SuperCluster objects
std::string siMatchedHitCollection_
std::string superClusterCollection_
~SiStripElectronProducer()
double energy() const
cluster energy
bool findElectron(reco::SiStripElectronCollection &electronOut, TrackCandidateCollection &trackCandidateOut, const reco::SuperClusterRef &superclusterIn, const TrackerTopology *tTopo)
edm::EDGetTokenT< SiStripMatchedRecHit2DCollection > matched_sistrips2dtag_
T const * product() const
std::string trackCandidatesLabel_
virtual void produce(edm::Event &, const edm::EventSetup &)
edm::EDGetTokenT< SiStripRecHit2DCollection > stereo_sistrips2dtag_
SiStripElectronAlgo * algo_p
edm::EDGetTokenT< SiStripRecHit2DCollection > rphi_sistrips2dtag_
std::string superClusterProducer_
void prepareEvent(const edm::ESHandle< TrackerGeometry > &tracker, const edm::Handle< SiStripRecHit2DCollection > &rphiHits, const edm::Handle< SiStripRecHit2DCollection > &stereoHits, const edm::Handle< SiStripMatchedRecHit2DCollection > &matchedHits, const edm::ESHandle< MagneticField > &magneticField)