CMS 3D CMS Logo

/data/refman/pasoursint/CMSSW_4_1_8_patch13/src/RecoParticleFlow/PFClusterProducer/plugins/PFRecHitProducerHCAL.h

Go to the documentation of this file.
00001 #ifndef RecoParticleFlow_PFClusterProducer_PFRecHitProducerHCAL_h_
00002 #define RecoParticleFlow_PFClusterProducer_PFRecHitProducerHCAL_h_
00003 
00004 // system include files
00005 #include <memory>
00006 #include <vector>
00007 
00008 // user include files
00009 #include "FWCore/Framework/interface/Frameworkfwd.h"
00010 #include "FWCore/Framework/interface/EDProducer.h"
00011 
00012 #include "FWCore/Framework/interface/Event.h"
00013 #include "FWCore/Framework/interface/MakerMacros.h"
00014 
00015 #include "FWCore/ParameterSet/interface/ParameterSet.h"
00016 
00017 #include "Geometry/CaloTopology/interface/CaloDirection.h"
00018 #include "RecoParticleFlow/PFClusterProducer/plugins/PFRecHitProducer.h"
00019 #include "DataFormats/ParticleFlowReco/interface/PFLayer.h"
00020 
00028 class CaloSubdetectorTopology;
00029 class CaloSubdetectorGeometry;
00030 class DetId;
00031 
00032 
00033 class PFRecHitProducerHCAL : public PFRecHitProducer {
00034  public:
00035   explicit PFRecHitProducerHCAL(const edm::ParameterSet&);
00036   ~PFRecHitProducerHCAL();
00037  
00038  private:
00039 
00040 
00043   void createRecHits(std::vector<reco::PFRecHit>& rechits,
00044                      std::vector<reco::PFRecHit>& rechitsCleaned,
00045                      edm::Event&, const edm::EventSetup&);
00046 
00047 
00048 
00049 
00050   reco::PFRecHit*  createHcalRecHit( const DetId& detid, 
00051                                      double energy,
00052                                      PFLayer::Layer layer,
00053                                      const CaloSubdetectorGeometry* geom,
00054                                      unsigned newDetId=0);
00055   
00056 
00057   
00058 
00061   void 
00062     findRecHitNeighbours( reco::PFRecHit& rh, 
00063                           const std::map<unsigned,unsigned >& sortedHits, 
00064                           const CaloSubdetectorTopology& barrelTopo,
00065                           const CaloSubdetectorGeometry& barrelGeom, 
00066                           const CaloSubdetectorTopology& endcapTopo,
00067                           const CaloSubdetectorGeometry& endcapGeom );
00068   
00072   void 
00073     findRecHitNeighboursCT( reco::PFRecHit& rh, 
00074                             const std::map<unsigned,unsigned >& sortedHits,
00075                             const CaloSubdetectorTopology& topology );
00076   
00077   DetId getNorth(const DetId& id, const CaloSubdetectorTopology& topology);
00078   DetId getSouth(const DetId& id, const CaloSubdetectorTopology& topology);
00079   
00080 
00081   // ----------member data ---------------------------
00082   
00083   // ----------access to event data
00084   edm::InputTag    inputTagHcalRecHitsHBHE_;
00085   edm::InputTag    inputTagHcalRecHitsHF_;
00086   edm::InputTag    inputTagCaloTowers_;
00087   
00089   double           thresh_HF_;
00090   // Navigation in HF:  False = no real clustering in HF; True  = do clustering 
00091   bool   navigation_HF_;
00092   double weight_HFem_;
00093   double weight_HFhad_;
00094 
00095   // Apply HCAL DPG rechit calibration
00096   bool HCAL_Calib_;
00097   bool HF_Calib_;
00098   float max_Calib_;
00099 
00100   // Don't allow large energy in short fibres if there is no energy in long fibres
00101   double shortFibre_Cut;  
00102   double longFibre_Fraction;
00103 
00104   // Don't allow large energy in long fibres if there is no energy in short fibres
00105   double longFibre_Cut;  
00106   double shortFibre_Fraction;
00107 
00108   // Also apply HCAL DPG cleaning
00109   bool applyLongShortDPG_;
00110 
00111   // Don't allow too large timing excursion if energy in long/short fibres is large enough
00112   double longShortFibre_Cut;  
00113   double minShortTiming_Cut;
00114   double maxShortTiming_Cut;
00115   double minLongTiming_Cut;
00116   double maxLongTiming_Cut;
00117 
00118   bool applyTimeDPG_;
00119   bool applyPulseDPG_;
00120 
00121   // Compensate for dead ECAL channels
00122   bool ECAL_Compensate_;
00123   double ECAL_Threshold_;
00124   double ECAL_Compensation_;
00125   unsigned int ECAL_Dead_Code_;
00126 
00127   // Depth correction for EM and HAD rechits in the HF
00128   double EM_Depth_;
00129   double HAD_Depth_;
00130 
00131 };
00132 
00133 #endif