CMS 3D CMS Logo

PFTauPrimaryVertexProducerBase.h
Go to the documentation of this file.
1 #ifndef RecoTauTag_RecoTau_PFTauPrimaryVertexProducerBase_H_
2 #define RecoTauTag_RecoTau_PFTauPrimaryVertexProducerBase_H_
3 
4 /* class PFTauPrimaryVertexProducerBase
5  * EDProducer of the
6  * authors: Ian M. Nugent
7  * This work is based on the impact parameter work by Rosamaria Venditti and reconstructing the 3 prong taus.
8  * The idea of the fully reconstructing the tau using a kinematic fit comes from
9  * Lars Perchalla and Philip Sauerland Theses under Achim Stahl supervision. This
10  * work was continued by Ian M. Nugent and Vladimir Cherepanov.
11  * Thanks goes to Christian Veelken and Evan Klose Friis for their help and suggestions.
12  */
13 
20 
32 
36 
37 #include <TFormula.h>
38 
40  public:
42 
43  struct DiscCutPair{
48  double cut_;
49  TFormula* cutFormula_;
50  };
51  typedef std::vector<DiscCutPair*> DiscCutPairVec;
52 
53  explicit PFTauPrimaryVertexProducerBase(const edm::ParameterSet& iConfig);
55  void produce(edm::Event&,const edm::EventSetup&) override;
56 
58 
59  // called at the beginning of every event - override if necessary
60  virtual void beginEvent(const edm::Event&, const edm::EventSetup&) {}
61 
62  protected:
63  // abstract function implemented in derived classes
64  virtual void nonTauTracksInPV(const reco::VertexRef&,
65  const std::vector<edm::Ptr<reco::TrackBase> >&,
66  std::vector<const reco::Track*>&) = 0;
67 
68  private:
80  DiscCutPairVec discriminators_;
81  std::unique_ptr<StringCutObjectSelector<reco::PFTau> > cut_;
82  std::unique_ptr<reco::tau::RecoTauVertexAssociator> vertexAssociator_;
83 };
84 
85 #endif
edm::EDGetTokenT< reco::BeamSpot > beamSpotToken_
edm::EDGetTokenT< edm::View< reco::Muon > > muonToken_
virtual void nonTauTracksInPV(const reco::VertexRef &, const std::vector< edm::Ptr< reco::TrackBase > > &, std::vector< const reco::Track * > &)=0
edm::EDGetTokenT< reco::VertexCollection > pvToken_
#define nullptr
virtual void beginEvent(const edm::Event &, const edm::EventSetup &)
std::vector< DiscCutPair * > DiscCutPairVec
edm::EDGetTokenT< std::vector< reco::PFTau > > pftauToken_
std::unique_ptr< reco::tau::RecoTauVertexAssociator > vertexAssociator_
PFTauPrimaryVertexProducerBase(const edm::ParameterSet &iConfig)
static edm::ParameterSetDescription getDescriptionsBase()
void produce(edm::Event &, const edm::EventSetup &) override
std::unique_ptr< StringCutObjectSelector< reco::PFTau > > cut_
edm::EDGetTokenT< reco::PFTauDiscriminator > inputToken_
edm::EDGetTokenT< edm::View< reco::Electron > > electronToken_