CMS 3D CMS Logo

/afs/cern.ch/work/a/aaltunda/public/www/CMSSW_6_2_5/src/RecoParticleFlow/PFClusterProducer/plugins/PFHCALDualTimeRecHitProducer.h

Go to the documentation of this file.
00001 #ifndef RecoParticleFlow_PFClusterProducer_PFHCALDualTimeRecHitProducer_h_
00002 #define RecoParticleFlow_PFClusterProducer_PFHCALDualTimeRecHitProducer_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 PFHCALDualTimeRecHitProducer : public PFRecHitProducer {
00034  public:
00035   explicit PFHCALDualTimeRecHitProducer(const edm::ParameterSet&);
00036   ~PFHCALDualTimeRecHitProducer();
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 HCAL_Calib_29;
00099   float HF_Calib_29;
00100 
00101   // Don't allow large energy in short fibres if there is no energy in long fibres
00102   double shortFibre_Cut;  
00103   double longFibre_Fraction;
00104 
00105   // Don't allow large energy in long fibres if there is no energy in short fibres
00106   double longFibre_Cut;  
00107   double shortFibre_Fraction;
00108 
00109   // Also apply HCAL DPG cleaning
00110   bool applyLongShortDPG_;
00111 
00112   // Don't allow too large timing excursion if energy in long/short fibres is large enough
00113   double longShortFibre_Cut;  
00114   double minShortTiming_Cut;
00115   double maxShortTiming_Cut;
00116   double minLongTiming_Cut;
00117   double maxLongTiming_Cut;
00118 
00119   bool applyTimeDPG_;
00120   bool applyPulseDPG_;
00121 
00122   // Compensate for dead ECAL channels
00123   bool ECAL_Compensate_;
00124   double ECAL_Threshold_;
00125   double ECAL_Compensation_;
00126   unsigned int ECAL_Dead_Code_;
00127 
00128   // Depth correction for EM and HAD rechits in the HF
00129   double EM_Depth_;
00130   double HAD_Depth_;
00131 
00132 };
00133 
00134 #endif