CMS 3D CMS Logo

TrackClassifier.h
Go to the documentation of this file.
1 
2 #ifndef TrackClassifier_h
3 #define TrackClassifier_h
4 
8 
11 
13 
15 
20 
25 
26 class TrackTopology;
27 
30 public:
33 
36 
38  void newEvent(edm::Event const &, edm::EventSetup const &);
39 
42 
45 
48 
50  TrackHistory const &history() const { return tracer_; }
51 
53  TrackQuality const &quality() const { return quality_; }
54 
55 private:
58 
59  double badPull_;
62  unsigned int numberOfInnerLayers_;
63  unsigned int minTrackerSimHits_;
64 
66 
68 
70 
72 
74 
76 
78 
80 
82 
86 
88  void simulationInformation();
89 
92 
94  void hadronFlavor();
95 
97  void processesAtGenerator();
98 
100  void processesAtSimulation();
101 
103  void vertexInformation();
104 
107  GeneratedPrimaryVertex(double x1, double y1, double z1) : x(x1), y(y1), z(z1), ptsq(0), nGenTrk(0) {}
108 
109  bool operator<(GeneratedPrimaryVertex const &reference) const { return ptsq < reference.ptsq; }
110 
111  double x, y, z;
112  double ptsq;
113  int nGenTrk;
114 
115  HepMC::FourVector ptot;
116 
117  std::vector<int> finalstateParticles;
118  std::vector<int> simTrackIndex;
119  std::vector<int> genVertex;
120  };
121 
122  std::vector<GeneratedPrimaryVertex> genpvs_;
123 
124  // Auxiliary function to get the generated primary vertex
126  bool isCharged(const HepMC::GenParticle *);
127  void genPrimaryVertices();
128 };
129 
130 #endif
G4toCMSLegacyProcTypeMap
Definition: Utils.h:35
TrackClassifier::magneticField_
edm::ESHandle< MagneticField > magneticField_
Definition: TrackClassifier.h:71
TrackClassifier::TrackClassifier
TrackClassifier(edm::ParameterSet const &, edm::ConsumesCollector &&)
Constructor by ParameterSet.
Definition: TrackClassifier.cc:15
TrackClassifier::quality_
TrackQuality quality_
Definition: TrackClassifier.h:67
TrackClassifier::GeneratedPrimaryVertex::y
double y
Definition: TrackClassifier.h:111
FreeTrajectoryState.h
HLT_FULL_cff.track
track
Definition: HLT_FULL_cff.py:11713
TrackClassifier::beamSpot_
edm::Handle< reco::BeamSpot > beamSpot_
Definition: TrackClassifier.h:79
TrackClassifier::GeneratedPrimaryVertex::finalstateParticles
std::vector< int > finalstateParticles
Definition: TrackClassifier.h:117
TrackClassifier::GeneratedPrimaryVertex::operator<
bool operator<(GeneratedPrimaryVertex const &reference) const
Definition: TrackClassifier.h:109
TrackClassifier::history
const TrackHistory & history() const
Returns a reference to the track history used in the classification.
Definition: TrackClassifier.h:50
TrackQuality.h
TrackClassifier::GeneratedPrimaryVertex::ptot
HepMC::FourVector ptot
Definition: TrackClassifier.h:115
TrackerTopology
Definition: TrackerTopology.h:16
TrackClassifier::tTopo_
const TrackerTopology * tTopo_
Definition: TrackClassifier.h:81
TrackCategories
Definition: TrackCategories.h:8
TrackClassifier::GeneratedPrimaryVertex::z
double z
Definition: TrackClassifier.h:111
TrackClassifier::minTrackerSimHits_
unsigned int minTrackerSimHits_
Definition: TrackClassifier.h:63
TrackClassifier::GeneratedPrimaryVertex::GeneratedPrimaryVertex
GeneratedPrimaryVertex(double x1, double y1, double z1)
Definition: TrackClassifier.h:107
edm::Handle< edm::HepMCProduct >
TrackClassifier::beamSpotLabel_
const edm::InputTag beamSpotLabel_
Definition: TrackClassifier.h:57
edm::Ref< TrackingParticleCollection >
TrackClassifier::hepMCLabel_
const edm::InputTag hepMCLabel_
Definition: TrackClassifier.h:56
testProducerWithPsetDescEmpty_cfi.x1
x1
Definition: testProducerWithPsetDescEmpty_cfi.py:33
TrackClassifier::GeneratedPrimaryVertex
Auxiliary class holding simulated primary vertices.
Definition: TrackClassifier.h:106
testProducerWithPsetDescEmpty_cfi.y1
y1
Definition: testProducerWithPsetDescEmpty_cfi.py:29
TrackClassifier::isCharged
bool isCharged(const HepMC::GenParticle *)
Definition: TrackClassifier.cc:491
TrackClassifier::mcInformation_
edm::Handle< edm::HepMCProduct > mcInformation_
Definition: TrackClassifier.h:73
BeamSpot.h
TrackClassifier::processesAtSimulation
void processesAtSimulation()
Get information about conversion and other interactions.
Definition: TrackClassifier.cc:303
TrackClassifier::tracer_
TrackHistory tracer_
Definition: TrackClassifier.h:65
TrackClassifier::evaluate
const TrackClassifier & evaluate(reco::TrackBaseRef const &)
Classify the RecoTrack in categories.
Definition: TrackClassifier.cc:75
IdealMagneticFieldRecord.h
edm::ESHandle< MagneticField >
TrackHistory.h
TrackClassifier::numberOfInnerLayers_
unsigned int numberOfInnerLayers_
Definition: TrackClassifier.h:62
TrackClassifier::hadronFlavor
void hadronFlavor()
Get hadron flavor of the initial hadron.
Definition: TrackClassifier.cc:234
TrackQuality
This class analyses the reconstruction quality for a given track.
Definition: TrackQuality.h:29
TrackClassifier::badPull_
double badPull_
Definition: TrackClassifier.h:59
TrackClassifier::quality
const TrackQuality & quality() const
Returns a reference to the track quality used in the classification.
Definition: TrackClassifier.h:53
CMSProcessTypes.h
TrackClassifier::genpvs_
std::vector< GeneratedPrimaryVertex > genpvs_
Definition: TrackClassifier.h:122
TrackClassifier::processesAtGenerator
void processesAtGenerator()
Get all the information related to decay process.
Definition: TrackClassifier.cc:247
TrackClassifier::GeneratedPrimaryVertex::simTrackIndex
std::vector< int > simTrackIndex
Definition: TrackClassifier.h:118
TransientTrackBuilder.h
edm::ParameterSet
Definition: ParameterSet.h:47
ParticleDataTable.h
TrackClassifier::newEvent
void newEvent(edm::Event const &, edm::EventSetup const &)
Pre-process event information (for accessing reconstraction information)
Definition: TrackClassifier.cc:44
RecoTauValidation_cfi.reference
reference
Definition: RecoTauValidation_cfi.py:234
TrackClassifier::particleDataTable_
edm::ESHandle< ParticleDataTable > particleDataTable_
Definition: TrackClassifier.h:75
TrackClassifier::vertexInformation
void vertexInformation()
Get geometrical information about the vertices.
Definition: TrackClassifier.cc:413
MagneticField.h
edm::EventSetup
Definition: EventSetup.h:58
TrackClassifier::qualityInformation
void qualityInformation(reco::TrackBaseRef const &)
Classify all the tracks by their reconstruction quality.
Definition: TrackClassifier.cc:211
TransientTrackRecord.h
TSCPBuilderNoMaterial.h
TrackClassifier::vertexClusteringSqDistance_
double vertexClusteringSqDistance_
Definition: TrackClassifier.h:61
InputTag.h
GenParticle.GenParticle
GenParticle
Definition: GenParticle.py:18
TrackClassifier::evaluate
const TrackClassifier & evaluate(reco::TrackRef const &track)
Classify the RecoTrack in categories.
Definition: TrackClassifier.h:47
TrackClassifier::reconstructionInformation
void reconstructionInformation(reco::TrackBaseRef const &)
Definition: TrackClassifier.cc:153
TrackClassifier::transientTrackBuilder_
edm::ESHandle< TransientTrackBuilder > transientTrackBuilder_
Definition: TrackClassifier.h:77
TrackClassifier::longLivedDecayLength_
double longLivedDecayLength_
Definition: TrackClassifier.h:60
TrackHistory
This class traces the simulated and generated history of a given track.
Definition: TrackHistory.h:17
TrackClassifier::simulationInformation
void simulationInformation()
Get all the information related to the simulation details.
Definition: TrackClassifier.cc:200
edm::RefToBase< reco::Track >
ConsumesCollector.h
TrackClassifier::g4toCMSProcMap_
const G4toCMSLegacyProcTypeMap g4toCMSProcMap_
Definition: TrackClassifier.h:69
ParameterSet.h
TrackClassifier::GeneratedPrimaryVertex::nGenTrk
int nGenTrk
Definition: TrackClassifier.h:113
TrackClassifier
Get track history and classify it in function of their .
Definition: TrackClassifier.h:29
TrackClassifier::GeneratedPrimaryVertex::ptsq
double ptsq
Definition: TrackClassifier.h:112
edm::Event
Definition: Event.h:73
TrackClassifier::genPrimaryVertices
void genPrimaryVertices()
Definition: TrackClassifier.cc:501
TrackCategories.h
TrackClassifier::GeneratedPrimaryVertex::x
double x
Definition: TrackClassifier.h:111
TrackClassifier::isFinalstateParticle
bool isFinalstateParticle(const HepMC::GenParticle *)
Definition: TrackClassifier.cc:489
edm::InputTag
Definition: InputTag.h:15
edm::ConsumesCollector
Definition: ConsumesCollector.h:45
TrackClassifier::GeneratedPrimaryVertex::genVertex
std::vector< int > genVertex
Definition: TrackClassifier.h:119
TrackClassifier::Categories
TrackCategories Categories
Type to the associate category.
Definition: TrackClassifier.h:32