CMS 3D CMS Logo

FFTJetInterface.h
Go to the documentation of this file.
1 // -*- C++ -*-
2 //
3 // Package: FFTJetProducers
4 // Class: FFTJetInterface
5 //
11 //
12 // Original Author: Igor Volobouev
13 // Created: June 29 2010
14 //
15 //
16 
17 #ifndef RecoJets_FFTJetProducers_FFTJetInterface_h
18 #define RecoJets_FFTJetProducers_FFTJetInterface_h
19 
20 #include <memory>
21 #include <vector>
22 #include <cassert>
23 
24 // FFTJet headers
25 #include "fftjet/Grid2d.hh"
26 
27 // framework include files
32 
34 
36 
40 
43 
44 // local FFTJet-related definitions
47 
48 //
49 // class declaration
50 //
51 namespace fftjetcms {
53  public:
54  // Explicitly disable other ways to construct this object
55  FFTJetInterface() = delete;
56  FFTJetInterface(const FFTJetInterface&) = delete;
57  FFTJetInterface& operator=(const FFTJetInterface&) = delete;
58  ~FFTJetInterface() override {}
59 
60  protected:
61  explicit FFTJetInterface(const edm::ParameterSet&);
62 
63  template <class Ptr>
64  void checkConfig(const Ptr& ptr, const char* message) {
65  if (ptr.get() == nullptr)
66  throw cms::Exception("FFTJetBadConfig") << message << std::endl;
67  }
68 
69  void loadInputCollection(const edm::Event&);
70  void discretizeEnergyFlow();
71  double getEventScale() const;
72  bool storeInSinglePrecision() const;
73 
74  const reco::Particle::Point& vertexUsed() const { return vertex_; }
75 
76  // Label for the input collection
78 
79  // Label for the output objects
81 
82  // Jet type to produce
84 
85  // Vertex correction-related stuff
86  const bool doPVCorrection;
87 
88  // Label for the vertices
90 
91  // Try to equalize magnitudes in the energy flow grid?
92  const std::vector<double> etaDependentMagnutideFactors;
93 
94  // Functor for finding anomalous towers
96 
97  // Event data 4-vectors
98  std::vector<fftjetcms::VectorLike> eventData;
99 
100  // Candidate number which corresponds to the item in the "eventData"
101  std::vector<unsigned> candidateIndex;
102 
103  // The energy discretization grid
104  std::unique_ptr<fftjet::Grid2d<fftjetcms::Real> > energyFlow;
105 
106  // The input handle for the collection of candidates
108 
109  private:
111  const double completeEventScale;
113 
116  };
117 } // namespace fftjetcms
118 
119 #endif // RecoJets_FFTJetProducers_FFTJetInterface_h
edm::EDGetTokenT< reco::CandidateView > inputToken
const edm::InputTag inputLabel
edm::Handle< reco::CandidateView > inputCollection
FFTJetInterface & operator=(const FFTJetInterface &)=delete
void loadInputCollection(const edm::Event &)
const edm::InputTag srcPVs
const reco::Particle::Point & vertexUsed() const
void checkConfig(const Ptr &ptr, const char *message)
std::vector< unsigned > candidateIndex
reco::Particle::Point vertex_
std::unique_ptr< fftjet::Grid2d< fftjetcms::Real > > energyFlow
const std::vector< double > etaDependentMagnutideFactors
edm::EDGetTokenT< reco::VertexCollection > srcPVsToken
math::XYZPoint Point
point in the space
Definition: Particle.h:25
const AnomalousTower anomalous
std::vector< fftjetcms::VectorLike > eventData
const std::string outputLabel