CMS 3D CMS Logo

/data/refman/pasoursint/CMSSW_5_3_0/src/RecoEcal/EgammaClusterProducers/interface/IslandClusterProducer.h

Go to the documentation of this file.
00001 #ifndef RecoEcal_EgammaClusterProducers_IslandClusterProducer_h_
00002 #define RecoEcal_EgammaClusterProducers_IslandClusterProducer_h_
00003 
00004 #include <memory>
00005 #include <time.h>
00006 
00007 #include "FWCore/Framework/interface/Frameworkfwd.h"
00008 #include "FWCore/Framework/interface/EDProducer.h"
00009 #include "FWCore/Framework/interface/Event.h"
00010 #include "FWCore/Framework/interface/EventSetup.h"
00011 
00012 #include "FWCore/ParameterSet/interface/ParameterSet.h"
00013 
00014 #include "DataFormats/EcalRecHit/interface/EcalRecHitCollections.h"
00015 #include "RecoEcal/EgammaClusterAlgos/interface/IslandClusterAlgo.h"
00016 #include "RecoEcal/EgammaCoreTools/interface/PositionCalc.h"
00017 #include "RecoEcal/EgammaCoreTools/interface/ClusterShapeAlgo.h"
00018 #include "Geometry/CaloTopology/interface/CaloSubdetectorTopology.h"
00019 
00020 #include "DataFormats/EgammaReco/interface/BasicClusterFwd.h"
00021 #include "DataFormats/CaloRecHit/interface/CaloClusterFwd.h"
00022 
00023 //
00024 
00025 
00026 class IslandClusterProducer : public edm::EDProducer 
00027 {
00028   public:
00029 
00030       IslandClusterProducer(const edm::ParameterSet& ps);
00031 
00032       ~IslandClusterProducer();
00033 
00034       virtual void produce(edm::Event&, const edm::EventSetup&);
00035 
00036    private:
00037 
00038       int nMaxPrintout_; // max # of printouts
00039       int nEvt_;         // internal counter of events
00040 
00041       IslandClusterAlgo::VerbosityLevel verbosity;
00042 
00043       std::string barrelHitProducer_;
00044       std::string endcapHitProducer_;
00045       std::string barrelHitCollection_;
00046       std::string endcapHitCollection_;
00047 
00048       std::string barrelClusterCollection_;
00049       std::string endcapClusterCollection_;
00050 
00051       std::string clustershapecollectionEB_;
00052       std::string clustershapecollectionEE_;
00053 
00054       //BasicClusterShape AssociationMap
00055       std::string barrelClusterShapeAssociation_;
00056       std::string endcapClusterShapeAssociation_; 
00057 
00058       PositionCalc posCalculator_; // position calculation algorithm
00059       ClusterShapeAlgo shapeAlgo_; // cluster shape algorithm
00060       IslandClusterAlgo * island_p;
00061 
00062       bool counterExceeded() const { return ((nEvt_ > nMaxPrintout_) || (nMaxPrintout_ < 0)); }
00063 
00064       const EcalRecHitCollection * getCollection(edm::Event& evt,
00065                                                  const std::string& hitProducer_,
00066                                                  const std::string& hitCollection_);
00067 
00068 
00069       void clusterizeECALPart(edm::Event &evt, const edm::EventSetup &es,
00070                               const std::string& hitProducer,
00071                               const std::string& hitCollection,
00072                               const std::string& clusterCollection,
00073                               const std::string& clusterShapeAssociation,
00074                               const IslandClusterAlgo::EcalPart& ecalPart);
00075 
00076       void outputValidationInfo(reco::CaloClusterPtrVector &clusterPtrVector);
00077 };
00078 
00079 
00080 #endif