HiggsAnalysis-KITHiggsToTauTau
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros
TaggedJetUncertaintyShiftProducer.h
Go to the documentation of this file.
1 
2 #pragma once
3 
4 #include "HiggsAnalysis/KITHiggsToTauTau/interface/HttTypes.h"
5 #include "HiggsAnalysis/KITHiggsToTauTau/interface/HttEnumTypes.h"
6 
7 #include "CondFormats/JetMETObjects/interface/JetCorrectionUncertainty.h"
8 #include "CondFormats/JetMETObjects/interface/JetCorrectorParameters.h"
9 
10 #include "Artus/KappaAnalysis/interface/Utility/BTagSF.h"
11 #include "Artus/KappaAnalysis/interface/Producers/GenParticleMatchingProducers.h"
12 
22 class TaggedJetUncertaintyShiftProducer: public ProducerBase<HttTypes>
23 {
24 public:
25 
26  virtual void Init(setting_type const& settings, metadata_type& metadata) override;
27  std::string GetProducerId() const override;
28  virtual void Produce(event_type const& event, product_type& product, setting_type const& settings, metadata_type const& metadata) const override;
29 
30 private:
31  std::string uncertaintyFile;
32  std::vector<std::string> individualUncertainties;
33  std::vector<HttEnumTypes::JetEnergyUncertaintyShiftName> individualUncertaintyEnums;
34 
35  std::map<HttEnumTypes::JetEnergyUncertaintyShiftName, JetCorrectionUncertainty*> jetUncMap;
36 
37  KappaEnumTypes::JetIDVersion jetIDVersion;
38  KappaEnumTypes::JetID jetID;
39 
40  std::map<std::string, std::vector<float> > lowerPtCuts;
41  std::map<std::string, std::vector<float> > upperAbsEtaCuts;
42 
43  std::map<size_t, std::vector<std::string> > puJetIdsByIndex;
44  std::map<std::string, std::vector<std::string> > puJetIdsByHltName;
45  std::map<std::string, std::vector<float> > jetTaggerLowerCutsByTaggerName;
46  std::map<std::string, std::vector<float> > jetTaggerUpperCutsByTaggerName;
47 
48  RecoJetGenParticleMatchingProducer::JetMatchingAlgorithm m_jetMatchingAlgorithm;
49 
50  KappaEnumTypes::BTagScaleFactorMethod m_bTagSFMethod;
51  float m_bTagWorkingPoint;
52  BTagSF m_bTagSf;
53 
54  void ProduceShift(event_type const& event, product_type& product, setting_type const& settings, metadata_type const& metadata, bool shiftUp,
55  std::map<HttEnumTypes::JetEnergyUncertaintyShiftName, std::vector<KJet>>& correctedJetsBySplitUncertainty,
56  std::map<HttEnumTypes::JetEnergyUncertaintyShiftName, std::vector<KJet>>& correctedBTaggedJetsBySplitUncertainty) const;
57 };
58 
virtual void Produce(event_type const &event, product_type &product, setting_type const &settings, metadata_type const &metadata) const override
Definition: TaggedJetUncertaintyShiftProducer.cc:200
Producer for jet energy scale corrections (Htt version).
Definition: TaggedJetUncertaintyShiftProducer.h:22
std::string GetProducerId() const override
Definition: TaggedJetUncertaintyShiftProducer.cc:16
virtual void Init(setting_type const &settings, metadata_type &metadata) override
Definition: TaggedJetUncertaintyShiftProducer.cc:21
JetEnergyUncertaintyShiftName
Definition: HttEnumTypes.h:106