CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
ggPFPhotons.h
Go to the documentation of this file.
1 #ifndef ggPFPhotons_h
2 #define ggPFPhotons_h
4 
12 #include <memory>
13 using namespace edm;
14 using namespace std;
15 using namespace reco;
16 //PFPHOTON CLASS BY RISHI PATEL FOR HiggsToGammaGamma rpatel@cern.ch
17 class ggPFPhotons {
18 
19  public:
20 
21  explicit ggPFPhotons(
22  reco::Photon phot,
26  edm::Handle<EcalRecHitCollection>& EBReducedRecHits,
27  edm::Handle<EcalRecHitCollection>& EEReducedRecHits,
29  const CaloSubdetectorGeometry* geomBar,
30  const CaloSubdetectorGeometry* geomEnd,
31  edm::Handle<BeamSpot>& beamSpotHandle
32  );
33  //add Geometry for Cluster Shape Calculation??
34  virtual ~ggPFPhotons();
35  bool MatchPFReco(){ return matchPFReco_;}
36  bool isConv(){ return isConv_;}
37  bool hasSLConv(){return hasSLConv_;}
38  bool isPFEle(){return isPFEle_;}
39  bool EleVeto(){return EleVeto_;}
40  float PFPS1(){return PFPreShower1_;}
41  float PFPS2(){return PFPreShower2_;}
42  float MustE(){return EinMustache_;}
43  float MustEOut(){return MustacheEOut_;}
44  float MustEtOut(){return MustacheEtOut_;}
45  float PFLowE(){return PFLowClusE_;}
46  double PFdEta(){return dEtaLowestC_;}
47  double PFdPhi(){return dPhiLowestC_;}
48  double PFClusRMSTot(){return PFClPhiRMS_;}
49  double PFClusRMSMust(){return PFClPhiRMSMust_;}
50  std::vector<reco::CaloCluster>PFClusters(){return PFClusters_;}
51  std::vector<reco::CaloCluster>PFClustersSCFP(){return PFSCFootprintClusters_;}//Electron Veto:
52  bool PFElectronVeto(edm::Handle<reco::ConversionCollection>& convH,
53  edm::Handle<reco::GsfElectronCollection>& gsfElectronsHandle);
54  //for Vertex
55  std::pair<float, float> SLPoint();
56  //fill PFCLuster Variables
57  void fillPFClusters();
58  //Local Containment Correction
59  double getPFPhoECorr( std::vector<reco::CaloCluster>PFClusters, const GBRForest *ReaderLCEB, const GBRForest *ReaderLCEE);
60  std::pair<double, double>CalcRMS(vector<reco::CaloCluster> PFClust, reco::Photon PFPhoton);
61  std::vector<reco::CaloCluster>recoPhotonClusterLink(
62  reco::Photon phot,
64  );
65  std::pair<double, double>SuperClusterSize(reco::Photon phot
66  );
67  static void recoPhotonClusterLink(
69  std::vector<reco::PFCandidatePtr>&insideMust,
70  std::vector<reco::PFCandidatePtr>&outsideMust,
72  double etabound,
73  double phibound
74  );
75  static std::pair<double, double>SuperClusterSize(reco::SuperCluster sc,
76  Handle<EcalRecHitCollection>& EBReducedRecHits,
77  Handle<EcalRecHitCollection>& EEReducedRecHits,
78  const CaloSubdetectorGeometry* geomBar,
79  const CaloSubdetectorGeometry* geomEnd
80  );
81  void PhotonPFCandMatch(
83  std::vector<reco::PFCandidatePtr>&insideBox,
85  vector<reco::CaloCluster> &PFClust,
86  std::vector<DetId>& MatchedRH
87  );
88  //for filling PFCluster Variables
89  private:
102  bool isPFEle_;
103  bool EleVeto_;
104  bool isConv_;
106  std::vector<reco::CaloCluster>PFClusters_;
107  std::vector<reco::CaloCluster>PFSCFootprintClusters_;
113  float PFLowClusE_;
114  double dEtaLowestC_;
115  double dPhiLowestC_;
116  double PFClPhiRMS_;
119 };
120 #endif
bool hasSLConv_
Definition: ggPFPhotons.h:105
bool matchPFReco_
Definition: ggPFPhotons.h:101
double PFClusRMSMust()
Definition: ggPFPhotons.h:49
reco::GsfElectron PFElectron_
Definition: ggPFPhotons.h:100
float MustEtOut()
Definition: ggPFPhotons.h:44
double PFdPhi()
Definition: ggPFPhotons.h:47
const CaloSubdetectorGeometry * geomBar_
Definition: ggPFPhotons.h:96
double PFdEta()
Definition: ggPFPhotons.h:46
float MustE()
Definition: ggPFPhotons.h:42
bool isPFEle()
Definition: ggPFPhotons.h:38
float MustacheEOut_
Definition: ggPFPhotons.h:109
float MustacheEtOut_
Definition: ggPFPhotons.h:110
std::vector< reco::CaloCluster > PFClusters_
Definition: ggPFPhotons.h:106
float PFPreShower2_
Definition: ggPFPhotons.h:112
bool hasSLConv()
Definition: ggPFPhotons.h:37
float PFPreShower1_
Definition: ggPFPhotons.h:111
std::vector< PFCandidatePtr > pfCandidates(const PFJet &jet, int particleId, bool sort=true)
std::vector< reco::CaloCluster > PFClusters()
Definition: ggPFPhotons.h:50
const CaloSubdetectorGeometry * geomEnd_
Definition: ggPFPhotons.h:97
double PFClPhiRMS_
Definition: ggPFPhotons.h:116
Handle< reco::GsfElectronCollection > pfElectrons_
Definition: ggPFPhotons.h:92
float EinMustache_
Definition: ggPFPhotons.h:108
float MustEOut()
Definition: ggPFPhotons.h:43
Handle< BeamSpot > beamSpotHandle_
Definition: ggPFPhotons.h:98
reco::Photon matchedPhot_
Definition: ggPFPhotons.h:90
bool MatchPFReco()
Definition: ggPFPhotons.h:35
double dPhiLowestC_
Definition: ggPFPhotons.h:115
double dEtaLowestC_
Definition: ggPFPhotons.h:114
float PFLowE()
Definition: ggPFPhotons.h:45
bool isConv()
Definition: ggPFPhotons.h:36
Handle< EcalRecHitCollection > ESRecHits_
Definition: ggPFPhotons.h:95
float PFLowClusE_
Definition: ggPFPhotons.h:113
double PFPhoLocallyCorrE_
Definition: ggPFPhotons.h:118
double PFClPhiRMSMust_
Definition: ggPFPhotons.h:117
Handle< EcalRecHitCollection > EBReducedRecHits_
Definition: ggPFPhotons.h:93
Handle< reco::PhotonCollection > pfPhotons_
Definition: ggPFPhotons.h:91
reco::Photon PFPhoton_
Definition: ggPFPhotons.h:99
double PFClusRMSTot()
Definition: ggPFPhotons.h:48
float PFPS1()
Definition: ggPFPhotons.h:40
float PFPS2()
Definition: ggPFPhotons.h:41
bool EleVeto()
Definition: ggPFPhotons.h:39
Handle< EcalRecHitCollection > EEReducedRecHits_
Definition: ggPFPhotons.h:94
std::vector< reco::CaloCluster > PFSCFootprintClusters_
Definition: ggPFPhotons.h:107
std::vector< reco::CaloCluster > PFClustersSCFP()
Definition: ggPFPhotons.h:51