CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
V0Fitter.h
Go to the documentation of this file.
1 // -*- C++ -*-
2 //
3 // Package: V0Producer
4 // Class: V0Fitter
5 //
13 //
14 // Original Author: Brian Drell
15 // Created: Fri May 18 22:57:40 CEST 2007
16 // $Id: V0Fitter.h,v 1.25 2013/04/11 23:17:44 wmtan Exp $
17 //
18 //
19 
20 #ifndef RECOVERTEX__V0_FITTER_H
21 #define RECOVERTEX__V0_FITTER_H
22 
26 
28 
35 
38 
41 
43 
50 
52 
53 #include <string>
54 #include <fstream>
55 
56 
57 class V0Fitter {
58  public:
59  V0Fitter(const edm::ParameterSet& theParams,
60  const edm::Event& iEvent, const edm::EventSetup& iSetup);
61  ~V0Fitter();
62 
63  // Switching to L. Lista's reco::Candidate infrastructure for V0 storage
66 
67  private:
68  // STL vector of VertexCompositeCandidate that will be filled with VertexCompositeCandidates by fitAll()
71 
72  // Tracker geometry for discerning hit positions
74 
76 
78  bool useRefTrax;
80  bool doKshorts;
81  bool doLambdas;
82 
83  /*bool doPostFitCuts;
84  bool doTkQualCuts;*/
85 
86  // Cuts
87  double chi2Cut;
88  double tkChi2Cut;
90  double rVtxCut;
91  double vtxSigCut;
92  double vtxSigCut3D;
93  double collinCut;
94  double kShortMassCut;
95  double lambdaMassCut;
97  double mPiPiCut;
98  double tkDCACut;
100 
101  std::vector<reco::TrackBase::TrackQuality> qualities;
102 
104 
105  // Helper method that does the actual fitting using the KalmanVertexFitter
106  void fitAll(const edm::Event& iEvent, const edm::EventSetup& iSetup);
107  double findV0MassError(const GlobalPoint &vtxPos, const std::vector<reco::TransientTrack> &dauTracks);
108 
109  // Applies cuts to the VertexCompositeCandidates after they are fitted/created.
110  //void applyPostFitCuts();
111 
112  // Stuff for debug file output.
113  std::ofstream mPiPiMassOut;
114 
115  inline void initFileOutput() {
116  mPiPiMassOut.open("mPiPi.txt", std::ios::app);
117  }
118  inline void cleanupFileOutput() {
119  mPiPiMassOut.close();
120  }
121 };
122 
123 #endif
bool useRefTrax
Definition: V0Fitter.h:78
void cleanupFileOutput()
Definition: V0Fitter.h:118
reco::VertexCompositeCandidateCollection theLambdas
Definition: V0Fitter.h:70
std::vector< VertexCompositeCandidate > VertexCompositeCandidateCollection
collection of Candidate objects
bool storeRefTrax
Definition: V0Fitter.h:79
int tkNhitsCut
Definition: V0Fitter.h:89
~V0Fitter()
Definition: V0Fitter.cc:102
void fitAll(const edm::Event &iEvent, const edm::EventSetup &iSetup)
Definition: V0Fitter.cc:106
const MagneticField * magField
Definition: V0Fitter.h:75
double chi2Cut
Definition: V0Fitter.h:87
edm::InputTag vtxFitter
Definition: V0Fitter.h:103
double rVtxCut
Definition: V0Fitter.h:90
double collinCut
Definition: V0Fitter.h:93
bool doKshorts
Definition: V0Fitter.h:80
double findV0MassError(const GlobalPoint &vtxPos, const std::vector< reco::TransientTrack > &dauTracks)
Definition: V0Fitter.cc:508
double tkChi2Cut
Definition: V0Fitter.h:88
int iEvent
Definition: GenABIO.cc:243
const reco::VertexCompositeCandidateCollection & getLambdas() const
Definition: V0Fitter.cc:502
double impactParameterSigCut
Definition: V0Fitter.h:96
bool doLambdas
Definition: V0Fitter.h:81
const reco::VertexCompositeCandidateCollection & getKshorts() const
Definition: V0Fitter.cc:498
const TrackerGeometry * trackerGeom
Definition: V0Fitter.h:73
void initFileOutput()
Definition: V0Fitter.h:115
std::vector< reco::TrackBase::TrackQuality > qualities
Definition: V0Fitter.h:101
double tkDCACut
Definition: V0Fitter.h:98
V0Fitter(const edm::ParameterSet &theParams, const edm::Event &iEvent, const edm::EventSetup &iSetup)
Definition: V0Fitter.cc:49
reco::VertexCompositeCandidateCollection theKshorts
Definition: V0Fitter.h:69
double kShortMassCut
Definition: V0Fitter.h:94
double vtxSigCut3D
Definition: V0Fitter.h:92
double mPiPiCut
Definition: V0Fitter.h:97
std::ofstream mPiPiMassOut
Definition: V0Fitter.h:113
edm::InputTag recoAlg
Definition: V0Fitter.h:77
double vtxSigCut
Definition: V0Fitter.h:91
double innerHitPosCut
Definition: V0Fitter.h:99
double lambdaMassCut
Definition: V0Fitter.h:95