00001 #ifndef HZZ2L2NU_INCLUDE_PHOTONWEIGHT_H_ 00002 #define HZZ2L2NU_INCLUDE_PHOTONWEIGHT_H_ 00003 00004 #include <WeightBase.h> 00005 00006 #include <filesystem> 00007 #include <memory> 00008 #include <string> 00009 00010 #include <TH2.h> 00011 00012 #include <Dataset.h> 00013 #include <Options.h> 00014 #include <PhotonBuilder.h> 00015 #include <PhysicsObjects.h> 00016 00025 class PhotonWeight : public WeightBase { 00026 public: 00028 PhotonWeight(Dataset &dataset, Options const &options, 00029 PhotonBuilder const *photonBuilder); 00030 00032 virtual double NominalWeight() const override; 00040 double PhotonSF(Photon const &photon) const; 00041 00042 private: 00049 static std::unique_ptr<TH2> ReadHistogram(std::string const &pathsWithNames); 00050 00056 std::vector<std::unique_ptr<TH2>> photonTable_; 00057 00059 PhotonBuilder const *photonBuilder_; 00060 }; 00061 00062 #endif // HZZ2L2NU_INCLUDE_PHOTONWEIGHT_H_