CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions | Private Member Functions | Private Attributes
TrackingMonitor Class Reference

#include <DQM/TrackerMonitorTrack/src/TrackingMonitor.cc>

Inheritance diagram for TrackingMonitor:
edm::EDAnalyzer

Public Member Functions

virtual void analyze (const edm::Event &, const edm::EventSetup &)
 
virtual void beginJob (void)
 
virtual void beginLuminosityBlock (const edm::LuminosityBlock &lumi, const edm::EventSetup &eSetup)
 
virtual void beginRun (const edm::Run &, const edm::EventSetup &)
 
virtual void endJob (void)
 
virtual void endRun (const edm::Run &, const edm::EventSetup &)
 
 TrackingMonitor (const edm::ParameterSet &)
 
 ~TrackingMonitor ()
 
- Public Member Functions inherited from edm::EDAnalyzer
 EDAnalyzer ()
 
std::string workerType () const
 
virtual ~EDAnalyzer ()
 

Private Member Functions

void doProfileX (TH2 *th2, MonitorElement *me)
 
void doProfileX (MonitorElement *th2m, MonitorElement *me)
 

Private Attributes

edm::InputTag bsSrc
 
std::string builderName
 
edm::ParameterSet conf_
 
bool doLumiAnalysis
 
bool doProfilesVsLS_
 
bool doTrackerSpecific_
 
DQMStoredqmStore_
 
MonitorElementFractionOfGoodTracks
 
GenericTriggerEventFlaggenTriggerEventFlag_
 
MonitorElementGoodTracksFractionVsLS
 
MonitorElementGoodTracksNumberOfRecHitsPerTrackVsLS
 
std::string histname
 
MonitorElementNumberOfGoodTracks
 
MonitorElementNumberOfMeanLayersPerTrack
 
MonitorElementNumberOfMeanRecHitsPerTrack
 
MonitorElementNumberOfPixelClus
 
MonitorElementNumberOfSeeds
 
MonitorElementNumberOfStripClus
 
MonitorElementNumberOfTrackCandidates
 
MonitorElementNumberOfTracks
 
MonitorElementNumberOfTrkVsClus
 
MonitorElementRatioOfPixelAndStripClus
 
TrackAnalyzertheTrackAnalyzer
 
TrackBuildingAnalyzertheTrackBuildingAnalyzer
 
edm::ESHandle
< TransientTrackingRecHitBuilder
theTTRHBuilder
 

Additional Inherited Members

- Public Types inherited from edm::EDAnalyzer
typedef EDAnalyzer ModuleType
 
typedef WorkerT< EDAnalyzerWorkerType
 
- Static Public Member Functions inherited from edm::EDAnalyzer
static const std::string & baseType ()
 
static void fillDescriptions (ConfigurationDescriptions &descriptions)
 
- Protected Member Functions inherited from edm::EDAnalyzer
CurrentProcessingContext const * currentContext () const
 

Detailed Description

Monitoring source for general quantities related to tracks.

Definition at line 32 of file TrackingMonitor.h.

Constructor & Destructor Documentation

TrackingMonitor::TrackingMonitor ( const edm::ParameterSet iConfig)
explicit

Definition at line 43 of file TrackingMonitor.cc.

45  , conf_ ( iConfig )
57  , builderName( conf_.getParameter<std::string>("TTRHBuilder"))
58  , doTrackerSpecific_( conf_.getParameter<bool>("doTrackerSpecific") )
59  , doLumiAnalysis( conf_.getParameter<bool>("doLumiAnalysis"))
60  , doProfilesVsLS_( conf_.getParameter<bool>("doProfilesVsLS"))
62 {
63 }
T getParameter(std::string const &) const
MonitorElement * FractionOfGoodTracks
DQMStore * dqmStore_
TrackAnalyzer * theTrackAnalyzer
edm::ParameterSet conf_
MonitorElement * NumberOfGoodTracks
#define NULL
Definition: scimark2.h:8
Provides a code based selection for trigger and DCS information in order to have no failing filters i...
MonitorElement * NumberOfMeanRecHitsPerTrack
MonitorElement * GoodTracksFractionVsLS
MonitorElement * NumberOfSeeds
TrackBuildingAnalyzer * theTrackBuildingAnalyzer
MonitorElement * NumberOfMeanLayersPerTrack
GenericTriggerEventFlag * genTriggerEventFlag_
MonitorElement * GoodTracksNumberOfRecHitsPerTrackVsLS
MonitorElement * NumberOfTrackCandidates
MonitorElement * NumberOfTracks
std::string builderName
TrackingMonitor::~TrackingMonitor ( )

Definition at line 66 of file TrackingMonitor.cc.

References genTriggerEventFlag_, theTrackAnalyzer, and theTrackBuildingAnalyzer.

67 {
71 }
TrackAnalyzer * theTrackAnalyzer
TrackBuildingAnalyzer * theTrackBuildingAnalyzer
GenericTriggerEventFlag * genTriggerEventFlag_

Member Function Documentation

void TrackingMonitor::analyze ( const edm::Event iEvent,
const edm::EventSetup iSetup 
)
virtual

Implements edm::EDAnalyzer.

Definition at line 274 of file TrackingMonitor.cc.

References GenericTriggerEventFlag::accept(), TrackAnalyzer::analyze(), TrackBuildingAnalyzer::analyze(), bsSrc, builderName, conf_, doProfilesVsLS_, doTrackerSpecific_, MonitorElement::Fill(), cropTnPTrees::frac, FractionOfGoodTracks, genTriggerEventFlag_, edm::EventSetup::get(), edm::Event::getByLabel(), edm::ParameterSet::getParameter(), GoodTracksFractionVsLS, GoodTracksNumberOfRecHitsPerTrackVsLS, reco::TrackBase::highPurity, i, edm::EventBase::id(), edm::HandleBase::isValid(), reco::TrackBase::loose, edm::EventID::luminosityBlock(), NumberOfGoodTracks, NumberOfMeanLayersPerTrack, NumberOfMeanRecHitsPerTrack, NumberOfPixelClus, NumberOfSeeds, NumberOfStripClus, NumberOfTrackCandidates, NumberOfTracks, NumberOfTrkVsClus, GenericTriggerEventFlag::on(), RatioOfPixelAndStripClus, edm::View< T >::size(), theTrackAnalyzer, theTrackBuildingAnalyzer, theTTRHBuilder, and reco::TrackBase::tight.

275 {
276  // Filter out events if Trigger Filtering is requested
277  if (genTriggerEventFlag_->on()&& ! genTriggerEventFlag_->accept( iEvent, iSetup) ) return;
278 
279  // input tags for collections from the configuration
280  edm::InputTag trackProducer = conf_.getParameter<edm::InputTag>("TrackProducer");
281  edm::InputTag seedProducer = conf_.getParameter<edm::InputTag>("SeedProducer");
282  edm::InputTag tcProducer = conf_.getParameter<edm::InputTag>("TCProducer");
284  std::string Quality = conf_.getParameter<std::string>("Quality");
285  std::string Algo = conf_.getParameter<std::string>("AlgoName");
286 
287  // Analyse the tracks
288  // if the collection is empty, do not fill anything
289  // ---------------------------------------------------------------------------------//
290 
291  // get the track collection
293  iEvent.getByLabel(trackProducer, trackHandle);
294 
295  if (trackHandle.isValid())
296  {
297 
298  reco::TrackCollection trackCollection = *trackHandle;
299  // calculate the mean # rechits and layers
300  int totalNumTracks = 0, totalRecHits = 0, totalLayers = 0;
301  int totalNumHPTracks = 0, totalNumPt1Tracks = 0, totalNumHPPt1Tracks = 0;
302 
303  for (reco::TrackCollection::const_iterator track = trackCollection.begin(); track!=trackCollection.end(); ++track)
304  {
305 
306  if( track->quality(reco::TrackBase::highPurity) ) {
307  ++totalNumHPTracks;
308  if ( track->pt() >= 1. ) {
309  ++totalNumHPPt1Tracks;
310  if ( doProfilesVsLS_ )
311  GoodTracksNumberOfRecHitsPerTrackVsLS->Fill(static_cast<double>(iEvent.id().luminosityBlock()),track->recHitsSize());
312  }
313  }
314 
315  if ( track->pt() >= 1. ) ++totalNumPt1Tracks;
316 
317 
318  if( Quality == "highPurity")
319  {
320  if( !track->quality(reco::TrackBase::highPurity) ) continue;
321  }
322  else if( Quality == "tight")
323  {
324  if( !track->quality(reco::TrackBase::tight) ) continue;
325  }
326  else if( Quality == "loose")
327  {
328  if( !track->quality(reco::TrackBase::loose) ) continue;
329  }
330 
331  totalNumTracks++;
332  totalRecHits += track->found();
333  totalLayers += track->hitPattern().trackerLayersWithMeasurement();
334 
335  // do analysis per track
336  theTrackAnalyzer->analyze(iEvent, iSetup, *track);
337  }
338 
339  NumberOfTracks->Fill(totalNumTracks);
340  NumberOfGoodTracks->Fill(totalNumHPPt1Tracks);
341 
342  double frac = 0.;
343  if (totalNumPt1Tracks > 0) frac = static_cast<double>(totalNumHPPt1Tracks)/static_cast<double>(totalNumPt1Tracks);
344  FractionOfGoodTracks->Fill(frac);
345  if ( doProfilesVsLS_ )
346  GoodTracksFractionVsLS->Fill(static_cast<double>(iEvent.id().luminosityBlock()),frac);
347 
348  if( totalNumTracks > 0 )
349  {
350  double meanRecHits = static_cast<double>(totalRecHits) / static_cast<double>(totalNumTracks);
351  double meanLayers = static_cast<double>(totalLayers) / static_cast<double>(totalNumTracks);
352  NumberOfMeanRecHitsPerTrack->Fill(meanRecHits);
353  NumberOfMeanLayersPerTrack->Fill(meanLayers);
354  }
355 
356 
357  // Analyse the Track Building variables
358  // if the collection is empty, do not fill anything
359  // ---------------------------------------------------------------------------------//
360 
361  if (conf_.getParameter<bool>("doSeedParameterHistos"))
362  {
363 
364  // magnetic field
366  iSetup.get<IdealMagneticFieldRecord>().get(theMF);
367 
368  // get the beam spot
369  edm::Handle<reco::BeamSpot> recoBeamSpotHandle;
370  iEvent.getByLabel(bsSrc,recoBeamSpotHandle);
371  const reco::BeamSpot& bs = *recoBeamSpotHandle;
372 
373  // get the candidate collection
375  iEvent.getByLabel(tcProducer, theTCHandle );
376  const TrackCandidateCollection& theTCCollection = *theTCHandle;
377 
378  // fill the TrackCandidate info
379  if (theTCHandle.isValid())
380  {
381  NumberOfTrackCandidates->Fill(theTCCollection.size());
383  for( TrackCandidateCollection::const_iterator cand = theTCCollection.begin(); cand != theTCCollection.end(); ++cand)
384  {
385  theTrackBuildingAnalyzer->analyze(iEvent, iSetup, *cand, bs, theMF, theTTRHBuilder);
386  }
387  }
388  else
389  {
390  edm::LogWarning("TrackingMonitor") << "No Track Candidates in the event. Not filling associated histograms";
391  }
392 
393  // get the seed collection
395  iEvent.getByLabel(seedProducer, seedHandle);
396  const edm::View<TrajectorySeed>& seedCollection = *seedHandle;
397 
398  // fill the seed info
399  if (seedHandle.isValid())
400  {
401  NumberOfSeeds->Fill(seedCollection.size());
402 
404  for(size_t i=0; i < seedHandle->size(); ++i)
405  {
406  edm::RefToBase<TrajectorySeed> seed(seedHandle, i);
407  theTrackBuildingAnalyzer->analyze(iEvent, iSetup, *seed, bs, theMF, theTTRHBuilder);
408  }
409  }
410  else
411  {
412  edm::LogWarning("TrackingMonitor") << "No Trajectory seeds in the event. Not filling associated histograms";
413  }
414  }
415  if ( doTrackerSpecific_)
416  {
418  iEvent.getByLabel("siStripClusters", strip_clusters);
420  iEvent.getByLabel("siPixelClusters", pixel_clusters);
421  if (strip_clusters.isValid() && pixel_clusters.isValid())
422  {
423  unsigned int ncluster_pix = (*pixel_clusters).dataSize();
424  unsigned int ncluster_strip = (*strip_clusters).dataSize();
425  double ratio = 0.0;
426  if ( ncluster_pix > 0) ratio = atan(ncluster_pix*1.0/ncluster_strip);
427 
428  NumberOfStripClus->Fill(ncluster_strip);
429  NumberOfPixelClus->Fill(ncluster_pix);
431  NumberOfTrkVsClus->Fill(totalNumTracks, ncluster_strip+ncluster_pix);
432  }
433  }
434 
435  }
436  else
437  {
438  return;
439  }
440 }
T getParameter(std::string const &) const
int i
Definition: DBlmapReader.cc:9
MonitorElement * FractionOfGoodTracks
TrackAnalyzer * theTrackAnalyzer
edm::ParameterSet conf_
MonitorElement * NumberOfGoodTracks
std::vector< TrackCandidate > TrackCandidateCollection
std::vector< Track > TrackCollection
collection of Tracks
Definition: TrackFwd.h:10
MonitorElement * NumberOfMeanRecHitsPerTrack
LuminosityBlockNumber_t luminosityBlock() const
Definition: EventID.h:43
MonitorElement * GoodTracksFractionVsLS
void Fill(long long x)
virtual void analyze(const edm::Event &iEvent, const edm::EventSetup &iSetup, const TrajectorySeed &seed, const reco::BeamSpot &bs, const edm::ESHandle< MagneticField > &theMF, const edm::ESHandle< TransientTrackingRecHitBuilder > &theTTRHBuilder)
MonitorElement * NumberOfPixelClus
MonitorElement * NumberOfSeeds
bool accept(const edm::Event &event, const edm::EventSetup &setup)
To be called from analyze/filter() methods.
bool isValid() const
Definition: HandleBase.h:76
bool getByLabel(InputTag const &tag, Handle< PROD > &result) const
Definition: Event.h:355
edm::InputTag bsSrc
TrackBuildingAnalyzer * theTrackBuildingAnalyzer
virtual void analyze(const edm::Event &iEvent, const edm::EventSetup &iSetup, const reco::Track &track)
MonitorElement * NumberOfMeanLayersPerTrack
MonitorElement * NumberOfStripClus
const T & get() const
Definition: EventSetup.h:55
MonitorElement * RatioOfPixelAndStripClus
size_type size() const
GenericTriggerEventFlag * genTriggerEventFlag_
edm::EventID id() const
Definition: EventBase.h:56
MonitorElement * GoodTracksNumberOfRecHitsPerTrackVsLS
edm::ESHandle< TransientTrackingRecHitBuilder > theTTRHBuilder
MonitorElement * NumberOfTrackCandidates
MonitorElement * NumberOfTrkVsClus
Definition: fakeMenu.h:4
MonitorElement * NumberOfTracks
std::string builderName
void TrackingMonitor::beginJob ( void  )
virtual

Reimplemented from edm::EDAnalyzer.

Definition at line 74 of file TrackingMonitor.cc.

References TrackAnalyzer::beginJob(), TrackBuildingAnalyzer::beginJob(), DQMStore::book1D(), DQMStore::book2D(), DQMStore::bookProfile(), conf_, doLumiAnalysis, doProfilesVsLS_, doTrackerSpecific_, dqmStore_, FractionOfGoodTracks, edm::ParameterSet::getParameter(), MonitorElement::getTH1(), GoodTracksFractionVsLS, GoodTracksNumberOfRecHitsPerTrackVsLS, histname, NumberOfGoodTracks, NumberOfMeanLayersPerTrack, NumberOfMeanRecHitsPerTrack, NumberOfPixelClus, NumberOfSeeds, NumberOfStripClus, NumberOfTrackCandidates, NumberOfTracks, NumberOfTrkVsClus, RatioOfPixelAndStripClus, MonitorElement::setAxisTitle(), DQMStore::setCurrentFolder(), TrackAnalyzer::setLumiFlag(), MonitorElement::setLumiFlag(), theTrackAnalyzer, and theTrackBuildingAnalyzer.

75 {
76 
77  // parameters from the configuration
78  std::string Quality = conf_.getParameter<std::string>("Quality");
79  std::string AlgoName = conf_.getParameter<std::string>("AlgoName");
80  std::string MEFolderName = conf_.getParameter<std::string>("FolderName");
81 
82  // test for the Quality veriable validity
83  if( Quality != "")
84  {
85  if( Quality != "highPurity" && Quality != "tight" && Quality != "loose")
86  {
87  edm::LogWarning("TrackingMonitor") << "Qualty Name is invalid, using no quality criterea by default";
88  Quality = "";
89  }
90  }
91 
92  // use the AlgoName and Quality Name
93  std::string CatagoryName = Quality != "" ? AlgoName + "_" + Quality : AlgoName;
94 
95  // get binning from the configuration
96  int TKNoBin = conf_.getParameter<int>( "TkSizeBin");
97  double TKNoMin = conf_.getParameter<double>("TkSizeMin");
98  double TKNoMax = conf_.getParameter<double>("TkSizeMax");
99 
100  int TCNoBin = conf_.getParameter<int>( "TCSizeBin");
101  double TCNoMin = conf_.getParameter<double>("TCSizeMin");
102  double TCNoMax = conf_.getParameter<double>("TCSizeMax");
103 
104  int TKNoSeedBin = conf_.getParameter<int>( "TkSeedSizeBin");
105  double TKNoSeedMin = conf_.getParameter<double>("TkSeedSizeMin");
106  double TKNoSeedMax = conf_.getParameter<double>("TkSeedSizeMax");
107 
108  int MeanHitBin = conf_.getParameter<int>( "MeanHitBin");
109  double MeanHitMin = conf_.getParameter<double>("MeanHitMin");
110  double MeanHitMax = conf_.getParameter<double>("MeanHitMax");
111 
112  int MeanLayBin = conf_.getParameter<int>( "MeanLayBin");
113  double MeanLayMin = conf_.getParameter<double>("MeanLayMin");
114  double MeanLayMax = conf_.getParameter<double>("MeanLayMax");
115 
116  int LSBin = conf_.getParameter<int>( "LSBin");
117  int LSMin = conf_.getParameter<double>("LSMin");
118  int LSMax = conf_.getParameter<double>("LSMax");
119 
120  std::string StateName = conf_.getParameter<std::string>("MeasurementState");
121  if
122  (
123  StateName != "OuterSurface" &&
124  StateName != "InnerSurface" &&
125  StateName != "ImpactPoint" &&
126  StateName != "default" &&
127  StateName != "All"
128  )
129  {
130  // print warning
131  edm::LogWarning("TrackingMonitor") << "State Name is invalid, using 'ImpactPoint' by default";
132  }
133 
134  dqmStore_->setCurrentFolder(MEFolderName);
135 
136  // book the General Property histograms
137  // ---------------------------------------------------------------------------------//
138  dqmStore_->setCurrentFolder(MEFolderName+"/GeneralProperties");
139 
140  histname = "NumberOfTracks_" + CatagoryName;
141  NumberOfTracks = dqmStore_->book1D(histname, histname, TKNoBin, TKNoMin, TKNoMax);
142  NumberOfTracks->setAxisTitle("Number of Tracks per Event", 1);
143  NumberOfTracks->setAxisTitle("Number of Events", 2);
144 
145  histname = "NumberOfMeanRecHitsPerTrack_" + CatagoryName;
146  NumberOfMeanRecHitsPerTrack = dqmStore_->book1D(histname, histname, MeanHitBin, MeanHitMin, MeanHitMax);
147  NumberOfMeanRecHitsPerTrack->setAxisTitle("Mean number of RecHits per Track", 1);
149 
150  histname = "NumberOfMeanLayersPerTrack_" + CatagoryName;
151  NumberOfMeanLayersPerTrack = dqmStore_->book1D(histname, histname, MeanLayBin, MeanLayMin, MeanLayMax);
152  NumberOfMeanLayersPerTrack->setAxisTitle("Mean number of Layers per Track", 1);
154 
155  histname = "NumberOfGoodTracks_" + CatagoryName;
156  NumberOfGoodTracks = dqmStore_->book1D(histname, histname, TKNoBin, TKNoMin, TKNoMax);
157  NumberOfGoodTracks->setAxisTitle("Number of Good Tracks per Event", 1);
158  NumberOfGoodTracks->setAxisTitle("Number of Events", 2);
159 
160  histname = "FractionOfGoodTracks_" + CatagoryName;
161  FractionOfGoodTracks = dqmStore_->book1D(histname, histname, 101, -0.005, 1.005);
162  FractionOfGoodTracks->setAxisTitle("Fraction of High Purity Tracks (Tracks with Pt>1GeV)", 1);
163  FractionOfGoodTracks->setAxisTitle("Entries", 2);
164 
165  // book profile plots vs LS :
166  //---------------------------
167 
168  if ( doProfilesVsLS_ ) {
169  histname = "GoodTracksFractionVsLS_"+ CatagoryName;
170  GoodTracksFractionVsLS = dqmStore_->bookProfile(histname,histname, LSBin,LSMin,LSMax,0,1.1,"");
171  GoodTracksFractionVsLS->getTH1()->SetBit(TH1::kCanRebin);
172  GoodTracksFractionVsLS->setAxisTitle("#Lumi section",1);
173  GoodTracksFractionVsLS->setAxisTitle("Fraction of Good Tracks",2);
174 
175  histname = "GoodTracksNumberOfRecHitsPerTrackVsLS_" + CatagoryName;
177  GoodTracksNumberOfRecHitsPerTrackVsLS->getTH1()->SetBit(TH1::kCanRebin);
179  GoodTracksNumberOfRecHitsPerTrackVsLS->setAxisTitle("Mean number of RecHits per Good track",2);
180  }
181 
183 
184  // book the Seed Property histograms
185  // ---------------------------------------------------------------------------------//
186  if (conf_.getParameter<bool>("doSeedParameterHistos"))
187  {
188  dqmStore_->setCurrentFolder(MEFolderName+"/TrackBuilding");
189 
190  histname = "NumberOfSeeds_" + CatagoryName;
191  NumberOfSeeds = dqmStore_->book1D(histname, histname, TKNoSeedBin, TKNoSeedMin, TKNoSeedMax);
192  NumberOfSeeds->setAxisTitle("Number of Seeds per Event", 1);
193  NumberOfSeeds->setAxisTitle("Number of Events", 2);
194 
195  histname = "NumberOfTrackCandidates_" + CatagoryName;
196  NumberOfTrackCandidates = dqmStore_->book1D(histname, histname, TCNoBin, TCNoMin, TCNoMax);
197  NumberOfTrackCandidates->setAxisTitle("Number of Track Candidates per Event", 1);
198  NumberOfTrackCandidates->setAxisTitle("Number of Event", 2);
199 
201  }
202  if (doLumiAnalysis) {
207  }
208  if (doTrackerSpecific_) {
209 
210  int NClusPxBin = conf_.getParameter<int>( "NClusPxBin");
211  double NClusPxMin = conf_.getParameter<double>("NClusPxMin");
212  double NClusPxMax = conf_.getParameter<double>("NClusPxMax");
213 
214  int NClusStrBin = conf_.getParameter<int>( "NClusStrBin");
215  double NClusStrMin = conf_.getParameter<double>("NClusStrMin");
216  double NClusStrMax = conf_.getParameter<double>("NClusStrMax");
217 
218  int NClus2DTotBin = conf_.getParameter<int>( "NClus2DTotBin");
219  double NClus2DTotMin = conf_.getParameter<double>("NClus2DTotMin");
220  double NClus2DTotMax = conf_.getParameter<double>("NClus2DTotMax");
221  int NTrk2DBin = conf_.getParameter<int>( "NTrk2DBin");
222  double NTrk2DMin = conf_.getParameter<double>("NTrk2DMin");
223  double NTrk2DMax = conf_.getParameter<double>("NTrk2DMax");
224 
225  dqmStore_->setCurrentFolder(MEFolderName+"/HitProperties");
226 
227  histname = "NumberOfClustersInPixel_" + CatagoryName;
228  NumberOfPixelClus = dqmStore_->book1D(histname, histname, NClusPxBin, NClusPxMin, NClusPxMax);
229  NumberOfPixelClus->setAxisTitle("# of Clusters in Pixel", 1);
230  NumberOfPixelClus->setAxisTitle("Number of Events", 2);
231 
232  histname = "NumberOfClustersInStrip_" + CatagoryName;
233  NumberOfStripClus = dqmStore_->book1D(histname, histname, NClusStrBin, NClusStrMin, NClusStrMax);
234  NumberOfStripClus->setAxisTitle("# of Clusters in Strip Detectors", 1);
235  NumberOfStripClus->setAxisTitle("Number of Events", 2);
236 
237  histname = "RatioOfPixelAndStripClusters_" + CatagoryName;
239  RatioOfPixelAndStripClus->setAxisTitle("ArcTan(PixelCluster/StripClusters)", 1);
240  RatioOfPixelAndStripClus->setAxisTitle("Number of Events", 2);
241 
242  histname = "TracksVsClusters_" + CatagoryName;
243  NumberOfTrkVsClus = dqmStore_->book2D(histname,histname,NTrk2DBin,NTrk2DMin,NTrk2DMax,
244  NClus2DTotBin,NClus2DTotMin,NClus2DTotMax);
245  NumberOfTrkVsClus->setAxisTitle("Number of Tracks", 1);
246  NumberOfTrkVsClus->setAxisTitle("# of Clusters in (Pixel+Strip) Detectors", 2);
247 
248  }
249 
250 
251 }
T getParameter(std::string const &) const
MonitorElement * FractionOfGoodTracks
DQMStore * dqmStore_
TrackAnalyzer * theTrackAnalyzer
edm::ParameterSet conf_
MonitorElement * book1D(const char *name, const char *title, int nchX, double lowX, double highX)
Book 1D histogram.
Definition: DQMStore.cc:514
MonitorElement * NumberOfGoodTracks
MonitorElement * NumberOfMeanRecHitsPerTrack
MonitorElement * GoodTracksFractionVsLS
MonitorElement * NumberOfPixelClus
virtual void beginJob(DQMStore *dqmStore_)
MonitorElement * NumberOfSeeds
TH1 * getTH1(void) const
MonitorElement * bookProfile(const char *name, const char *title, int nchX, double lowX, double highX, int nchY, double lowY, double highY, const char *option="s")
Definition: DQMStore.cc:828
std::string histname
virtual void beginJob(DQMStore *dqmStore_)
TrackBuildingAnalyzer * theTrackBuildingAnalyzer
MonitorElement * NumberOfMeanLayersPerTrack
MonitorElement * NumberOfStripClus
MonitorElement * RatioOfPixelAndStripClus
MonitorElement * GoodTracksNumberOfRecHitsPerTrackVsLS
MonitorElement * NumberOfTrackCandidates
void setLumiFlag(void)
this ME is meant to be stored for each luminosity section
MonitorElement * book2D(const char *name, const char *title, int nchX, double lowX, double highX, int nchY, double lowY, double highY)
Book 2D histogram.
Definition: DQMStore.cc:642
MonitorElement * NumberOfTrkVsClus
void setAxisTitle(const std::string &title, int axis=1)
set x-, y- or z-axis title (axis=1, 2, 3 respectively)
void setCurrentFolder(const std::string &fullpath)
Definition: DQMStore.cc:232
MonitorElement * NumberOfTracks
void TrackingMonitor::beginLuminosityBlock ( const edm::LuminosityBlock lumi,
const edm::EventSetup eSetup 
)
virtual

Reimplemented from edm::EDAnalyzer.

Definition at line 263 of file TrackingMonitor.cc.

References doLumiAnalysis, TrackAnalyzer::doSoftReset(), dqmStore_, FractionOfGoodTracks, NumberOfGoodTracks, NumberOfTracks, DQMStore::softReset(), and theTrackAnalyzer.

263  {
264  if (doLumiAnalysis) {
269  }
270 }
MonitorElement * FractionOfGoodTracks
DQMStore * dqmStore_
TrackAnalyzer * theTrackAnalyzer
MonitorElement * NumberOfGoodTracks
void softReset(MonitorElement *me)
Definition: DQMStore.cc:2527
void doSoftReset(DQMStore *dqmStore_)
MonitorElement * NumberOfTracks
void TrackingMonitor::beginRun ( const edm::Run iRun,
const edm::EventSetup iSetup 
)
virtual

Reimplemented from edm::EDAnalyzer.

Definition at line 255 of file TrackingMonitor.cc.

References genTriggerEventFlag_, GenericTriggerEventFlag::initRun(), and GenericTriggerEventFlag::on().

256 {
257  // Initialize the GenericTriggerEventFlag
258  if ( genTriggerEventFlag_->on() ) genTriggerEventFlag_->initRun( iRun, iSetup );
259 }
GenericTriggerEventFlag * genTriggerEventFlag_
void initRun(const edm::Run &run, const edm::EventSetup &setup)
To be called from beginedm::Run() methods.
void TrackingMonitor::doProfileX ( TH2 *  th2,
MonitorElement me 
)
private
void TrackingMonitor::doProfileX ( MonitorElement th2m,
MonitorElement me 
)
private
void TrackingMonitor::endJob ( void  )
virtual

Reimplemented from edm::EDAnalyzer.

Definition at line 452 of file TrackingMonitor.cc.

References conf_, dqmStore_, edm::ParameterSet::getParameter(), dumpDBToFile_GT_ttrig_cfg::outputFileName, DQMStore::save(), and DQMStore::showDirStructure().

453 {
454  bool outputMEsInRootFile = conf_.getParameter<bool>("OutputMEsInRootFile");
455  std::string outputFileName = conf_.getParameter<std::string>("OutputFileName");
456  if(outputMEsInRootFile)
457  {
459  dqmStore_->save(outputFileName);
460  }
461 }
T getParameter(std::string const &) const
DQMStore * dqmStore_
edm::ParameterSet conf_
void save(const std::string &filename, const std::string &path="", const std::string &pattern="", const std::string &rewrite="", SaveReferenceTag ref=SaveWithReference, int minStatus=dqm::qstatus::STATUS_OK, const std::string &fileupdate="RECREATE")
Definition: DQMStore.cc:1898
void showDirStructure(void) const
Definition: DQMStore.cc:2554
void TrackingMonitor::endRun ( const edm::Run ,
const edm::EventSetup  
)
virtual

Reimplemented from edm::EDAnalyzer.

Definition at line 441 of file TrackingMonitor.cc.

References DQMStore::disableSoftReset(), doLumiAnalysis, dqmStore_, FractionOfGoodTracks, NumberOfGoodTracks, NumberOfTracks, theTrackAnalyzer, and TrackAnalyzer::undoSoftReset().

442 {
443  if (doLumiAnalysis) {
448  }
449 
450 }
MonitorElement * FractionOfGoodTracks
DQMStore * dqmStore_
TrackAnalyzer * theTrackAnalyzer
MonitorElement * NumberOfGoodTracks
void disableSoftReset(MonitorElement *me)
Definition: DQMStore.cc:2535
MonitorElement * NumberOfTracks
void undoSoftReset(DQMStore *dqmStore_)

Member Data Documentation

edm::InputTag TrackingMonitor::bsSrc
private

Definition at line 58 of file TrackingMonitor.h.

Referenced by analyze().

std::string TrackingMonitor::builderName
private

Definition at line 88 of file TrackingMonitor.h.

Referenced by analyze().

edm::ParameterSet TrackingMonitor::conf_
private

Definition at line 55 of file TrackingMonitor.h.

Referenced by analyze(), beginJob(), and endJob().

bool TrackingMonitor::doLumiAnalysis
private

Definition at line 92 of file TrackingMonitor.h.

Referenced by beginJob(), beginLuminosityBlock(), and endRun().

bool TrackingMonitor::doProfilesVsLS_
private

Definition at line 93 of file TrackingMonitor.h.

Referenced by analyze(), and beginJob().

bool TrackingMonitor::doTrackerSpecific_
private

Definition at line 91 of file TrackingMonitor.h.

Referenced by analyze(), and beginJob().

DQMStore* TrackingMonitor::dqmStore_
private

Definition at line 54 of file TrackingMonitor.h.

Referenced by beginJob(), beginLuminosityBlock(), endJob(), and endRun().

MonitorElement* TrackingMonitor::FractionOfGoodTracks
private

Definition at line 70 of file TrackingMonitor.h.

Referenced by analyze(), beginJob(), beginLuminosityBlock(), and endRun().

GenericTriggerEventFlag* TrackingMonitor::genTriggerEventFlag_
private

Definition at line 95 of file TrackingMonitor.h.

Referenced by analyze(), beginRun(), and ~TrackingMonitor().

MonitorElement* TrackingMonitor::GoodTracksFractionVsLS
private

Definition at line 85 of file TrackingMonitor.h.

Referenced by analyze(), and beginJob().

MonitorElement* TrackingMonitor::GoodTracksNumberOfRecHitsPerTrackVsLS
private

Definition at line 86 of file TrackingMonitor.h.

Referenced by analyze(), and beginJob().

std::string TrackingMonitor::histname
private

Definition at line 52 of file TrackingMonitor.h.

Referenced by beginJob().

MonitorElement* TrackingMonitor::NumberOfGoodTracks
private

Definition at line 69 of file TrackingMonitor.h.

Referenced by analyze(), beginJob(), beginLuminosityBlock(), and endRun().

MonitorElement* TrackingMonitor::NumberOfMeanLayersPerTrack
private

Definition at line 66 of file TrackingMonitor.h.

Referenced by analyze(), and beginJob().

MonitorElement* TrackingMonitor::NumberOfMeanRecHitsPerTrack
private

Definition at line 65 of file TrackingMonitor.h.

Referenced by analyze(), and beginJob().

MonitorElement* TrackingMonitor::NumberOfPixelClus
private

Definition at line 79 of file TrackingMonitor.h.

Referenced by analyze(), and beginJob().

MonitorElement* TrackingMonitor::NumberOfSeeds
private

Definition at line 73 of file TrackingMonitor.h.

Referenced by analyze(), and beginJob().

MonitorElement* TrackingMonitor::NumberOfStripClus
private

Definition at line 80 of file TrackingMonitor.h.

Referenced by analyze(), and beginJob().

MonitorElement* TrackingMonitor::NumberOfTrackCandidates
private

Definition at line 76 of file TrackingMonitor.h.

Referenced by analyze(), and beginJob().

MonitorElement* TrackingMonitor::NumberOfTracks
private

Definition at line 64 of file TrackingMonitor.h.

Referenced by analyze(), beginJob(), beginLuminosityBlock(), and endRun().

MonitorElement* TrackingMonitor::NumberOfTrkVsClus
private

Definition at line 82 of file TrackingMonitor.h.

Referenced by analyze(), and beginJob().

MonitorElement* TrackingMonitor::RatioOfPixelAndStripClus
private

Definition at line 81 of file TrackingMonitor.h.

Referenced by analyze(), and beginJob().

TrackAnalyzer* TrackingMonitor::theTrackAnalyzer
private

Definition at line 60 of file TrackingMonitor.h.

Referenced by analyze(), beginJob(), beginLuminosityBlock(), endRun(), and ~TrackingMonitor().

TrackBuildingAnalyzer* TrackingMonitor::theTrackBuildingAnalyzer
private

Definition at line 61 of file TrackingMonitor.h.

Referenced by analyze(), beginJob(), and ~TrackingMonitor().

edm::ESHandle<TransientTrackingRecHitBuilder> TrackingMonitor::theTTRHBuilder
private

Definition at line 89 of file TrackingMonitor.h.

Referenced by analyze().