CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
SiPixelRecHitsValid.cc
Go to the documentation of this file.
1 // SiPixelRecHitsValid.cc
2 // Description: see SiPixelRecHitsValid.h
3 // Author: Jason Shaev, JHU
4 // Created 6/7/06
5 //
6 // G. Giurgiu, JHU (ggiurgiu@pha.jhu.edu)
7 // added pull distributions (12/27/06)
8 //--------------------------------
9 
11 
13 
19 
27 
29 
30 #include <math.h>
32 
33 using namespace std;
34 using namespace edm;
35 
36 
38  dbe_(0),
39  conf_(ps),
40  src_( ps.getParameter<edm::InputTag>( "src" ) )
41 {
42  outputFile_ = ps.getUntrackedParameter<string>("outputFile", "pixelrechitshisto.root");
44  //dbe_->showDirStructure();
45  dbe_->setCurrentFolder("TrackerRecHitsV/TrackerRecHits/Pixel/clustBPIX");
46 
47  Char_t histo[200];
48 
49  // ---------------------------------------------------------------
50  // All histograms that depend on plaquette number have 7 indexes.
51  // The first 4 (0-3) correspond to Panel 1 plaquettes 1-4.
52  // The last 3 (4-6) correspond to Panel 2 plaquettes 1-3.
53  // ---------------------------------------------------------------
54 
55  //Cluster y-size by module number for barrel
56  for (int i=0; i<8; i++) {
57  sprintf(histo, "Clust_y_size_Module%d", i+1);
58  clustYSizeModule[i] = dbe_->book1D(histo,"Cluster y-size by Module", 20, 0.5, 20.5);
59  } // end for
60 
61  //Cluster x-size by layer for barrel
62  for (int i=0; i<3; i++) {
63  sprintf(histo, "Clust_x_size_Layer%d", i+1);
64  clustXSizeLayer[i] = dbe_->book1D(histo,"Cluster x-size by Layer", 20, 0.5, 20.5);
65  } // end for
66 
67  //Cluster charge by module for 3 layers of barrel
68  for (int i=0; i<8; i++) {
69  //Cluster charge by module for Layer1
70  sprintf(histo, "Clust_charge_Layer1_Module%d", i+1);
71  clustChargeLayer1Modules[i] = dbe_->book1D(histo, "Cluster charge Layer 1 by Module", 50, 0., 200000.);
72 
73  //Cluster charge by module for Layer2
74  sprintf(histo, "Clust_charge_Layer2_Module%d", i+1);
75  clustChargeLayer2Modules[i] = dbe_->book1D(histo, "Cluster charge Layer 2 by Module", 50, 0., 200000.);
76 
77  //Cluster charge by module for Layer3
78  sprintf(histo, "Clust_charge_Layer3_Module%d", i+1);
79  clustChargeLayer3Modules[i] = dbe_->book1D(histo, "Cluster charge Layer 3 by Module",50, 0., 200000.);
80  } // end for
81 
82  dbe_->setCurrentFolder("TrackerRecHitsV/TrackerRecHits/Pixel/clustFPIX");
83  //Cluster x-size, y-size, and charge by plaquette for Disks in Forward
84  for (int i=0; i<7; i++) {
85  //Cluster x-size for Disk1 by Plaquette
86  sprintf(histo, "Clust_x_size_Disk1_Plaquette%d", i+1);
87  clustXSizeDisk1Plaquettes[i] = dbe_->book1D(histo, "Cluster X-size for Disk1 by Plaquette", 20, 0.5, 20.5);
88 
89  //Cluster x-size for Disk2 by Plaquette
90  sprintf(histo, "Clust_x_size_Disk2_Plaquette%d", i+1);
91  clustXSizeDisk2Plaquettes[i] = dbe_->book1D(histo, "Cluster X-size for Disk2 by Plaquette", 20, 0.5, 20.5);
92 
93  //Cluster y-size for Disk1 by Plaquette
94  sprintf(histo, "Clust_y_size_Disk1_Plaquette%d", i+1);
95  clustYSizeDisk1Plaquettes[i] = dbe_->book1D(histo, "Cluster Y-size for Disk1 by Plaquette", 20, 0.5, 20.5);
96 
97  //Cluster y-size for Disk2 by Plaquette
98  sprintf(histo, "Clust_y_size_Disk2_Plaquette%d", i+1);
99  clustYSizeDisk2Plaquettes[i] = dbe_->book1D(histo, "Cluster Y-size for Disk2 by Plaquette", 20, 0.5, 20.5);
100 
101  //Cluster charge for Disk1 by Plaquette
102  sprintf(histo, "Clust_charge_Disk1_Plaquette%d", i+1);
103  clustChargeDisk1Plaquettes[i] = dbe_->book1D(histo, "Cluster charge for Disk1 by Plaquette", 50, 0., 200000.);
104 
105  //Cluster charge for Disk2 by Plaquette
106  sprintf(histo, "Clust_charge_Disk2_Plaquette%d", i+1);
107  clustChargeDisk2Plaquettes[i] = dbe_->book1D(histo, "Cluster charge for Disk2 by Plaquette", 50, 0., 200000.);
108  } // end for
109 
110 
111 
112  dbe_->setCurrentFolder("TrackerRecHitsV/TrackerRecHits/Pixel/recHitBPIX");
113  //RecHit X Resolution all barrel hits
114  recHitXResAllB = dbe_->book1D("RecHit_xres_b_All","RecHit X Res All Modules in Barrel", 100, -200., 200.);
115 
116  //RecHit Y Resolution all barrel hits
117  recHitYResAllB = dbe_->book1D("RecHit_yres_b_All","RecHit Y Res All Modules in Barrel", 100, -200., 200.);
118 
119  //RecHit X distribution for full modules for barrel
120  recHitXFullModules = dbe_->book1D("RecHit_x_FullModules", "RecHit X distribution for full modules", 100,-2., 2.);
121 
122  //RecHit X distribution for half modules for barrel
123  recHitXHalfModules = dbe_->book1D("RecHit_x_HalfModules", "RecHit X distribution for half modules", 100, -1., 1.);
124 
125  //RecHit Y distribution all modules for barrel
126  recHitYAllModules = dbe_->book1D("RecHit_y_AllModules", "RecHit Y distribution for all modules", 100, -4., 4.);
127 
128  //RecHit X resolution for flipped and unflipped ladders by layer for barrel
129  for (int i=0; i<3; i++) {
130  //RecHit X resolution for flipped ladders by layer
131  sprintf(histo, "RecHit_XRes_FlippedLadder_Layer%d", i+1);
132  recHitXResFlippedLadderLayers[i] = dbe_->book1D(histo, "RecHit XRes Flipped Ladders by Layer", 100, -200., 200.);
133 
134  //RecHit X resolution for unflipped ladders by layer
135  sprintf(histo, "RecHit_XRes_UnFlippedLadder_Layer%d", i+1);
136  recHitXResNonFlippedLadderLayers[i] = dbe_->book1D(histo, "RecHit XRes NonFlipped Ladders by Layer", 100, -200., 200.);
137  } // end for
138 
139  //RecHit Y resolutions for layers by module for barrel
140  for (int i=0; i<8; i++) {
141  //Rec Hit Y resolution by module for Layer1
142  sprintf(histo, "RecHit_YRes_Layer1_Module%d", i+1);
143  recHitYResLayer1Modules[i] = dbe_->book1D(histo, "RecHit YRes Layer1 by module", 100, -200., 200.);
144 
145  //RecHit Y resolution by module for Layer2
146  sprintf(histo, "RecHit_YRes_Layer2_Module%d", i+1);
147  recHitYResLayer2Modules[i] = dbe_->book1D(histo, "RecHit YRes Layer2 by module", 100, -200., 200.);
148 
149  //RecHit Y resolution by module for Layer3
150  sprintf(histo, "RecHit_YRes_Layer3_Module%d", i+1);
151  recHitYResLayer3Modules[i] = dbe_->book1D(histo, "RecHit YRes Layer3 by module", 100, -200., 200.);
152  } // end for
153 
154  dbe_->setCurrentFolder("TrackerRecHitsV/TrackerRecHits/Pixel/recHitFPIX");
155  //RecHit X resolution all plaquettes
156  recHitXResAllF = dbe_->book1D("RecHit_xres_f_All", "RecHit X Res All in Forward", 100, -200., 200.);
157 
158  //RecHit Y resolution all plaquettes
159  recHitYResAllF = dbe_->book1D("RecHit_yres_f_All", "RecHit Y Res All in Forward", 100, -200., 200.);
160 
161  //RecHit X distribution for plaquette with x-size 1 in forward
162  recHitXPlaquetteSize1 = dbe_->book1D("RecHit_x_Plaquette_xsize1", "RecHit X Distribution for plaquette x-size1", 100, -2., 2.);
163 
164  //RecHit X distribution for plaquette with x-size 2 in forward
165  recHitXPlaquetteSize2 = dbe_->book1D("RecHit_x_Plaquette_xsize2", "RecHit X Distribution for plaquette x-size2", 100, -2., 2.);
166 
167  //RecHit Y distribution for plaquette with y-size 2 in forward
168  recHitYPlaquetteSize2 = dbe_->book1D("RecHit_y_Plaquette_ysize2", "RecHit Y Distribution for plaquette y-size2", 100, -4., 4.);
169 
170  //RecHit Y distribution for plaquette with y-size 3 in forward
171  recHitYPlaquetteSize3 = dbe_->book1D("RecHit_y_Plaquette_ysize3", "RecHit Y Distribution for plaquette y-size3", 100, -4., 4.);
172 
173  //RecHit Y distribution for plaquette with y-size 4 in forward
174  recHitYPlaquetteSize4 = dbe_->book1D("RecHit_y_Plaquette_ysize4", "RecHit Y Distribution for plaquette y-size4", 100, -4., 4.);
175 
176  //RecHit Y distribution for plaquette with y-size 5 in forward
177  recHitYPlaquetteSize5 = dbe_->book1D("RecHit_y_Plaquette_ysize5", "RecHit Y Distribution for plaquette y-size5", 100, -4., 4.);
178 
179  //X and Y resolutions for both disks by plaquette in forward
180  for (int i=0; i<7; i++) {
181  //X resolution for Disk1 by plaquette
182  sprintf(histo, "RecHit_XRes_Disk1_Plaquette%d", i+1);
183  recHitXResDisk1Plaquettes[i] = dbe_->book1D(histo, "RecHit XRes Disk1 by plaquette", 100, -200., 200.);
184  //X resolution for Disk2 by plaquette
185  sprintf(histo, "RecHit_XRes_Disk2_Plaquette%d", i+1);
186  recHitXResDisk2Plaquettes[i] = dbe_->book1D(histo, "RecHit XRes Disk2 by plaquette", 100, -200., 200.);
187 
188  //Y resolution for Disk1 by plaquette
189  sprintf(histo, "RecHit_YRes_Disk1_Plaquette%d", i+1);
190  recHitYResDisk1Plaquettes[i] = dbe_->book1D(histo, "RecHit YRes Disk1 by plaquette", 100, -200., 200.);
191  //Y resolution for Disk2 by plaquette
192  sprintf(histo, "RecHit_YRes_Disk2_Plaquette%d", i+1);
193  recHitYResDisk2Plaquettes[i] = dbe_->book1D(histo, "RecHit YRes Disk2 by plaquette", 100, -200., 200.);
194 
195  }
196 
197 
198  dbe_->setCurrentFolder("TrackerRecHitsV/TrackerRecHits/Pixel/recHitPullsBPIX");
199  recHitXPullAllB = dbe_->book1D("RecHit_xres_b_All" , "RecHit X Pull All Modules in Barrel" , 100, -10.0, 10.0);
200  recHitYPullAllB = dbe_->book1D("RecHit_yres_b_All" , "RecHit Y Pull All Modules in Barrel" , 100, -10.0, 10.0);
201 
202  for (int i=0; i<3; i++)
203  {
204  sprintf(histo, "RecHit_XPull_FlippedLadder_Layer%d", i+1);
205  recHitXPullFlippedLadderLayers[i] = dbe_->book1D(histo, "RecHit XPull Flipped Ladders by Layer", 100, -10.0, 10.0);
206 
207  sprintf(histo, "RecHit_XPull_UnFlippedLadder_Layer%d", i+1);
208  recHitXPullNonFlippedLadderLayers[i] = dbe_->book1D(histo, "RecHit XPull NonFlipped Ladders by Layer", 100, -10.0, 10.0);
209  }
210 
211  for (int i=0; i<8; i++)
212  {
213  sprintf(histo, "RecHit_YPull_Layer1_Module%d", i+1);
214  recHitYPullLayer1Modules[i] = dbe_->book1D(histo, "RecHit YPull Layer1 by module", 100, -10.0, 10.0);
215 
216  sprintf(histo, "RecHit_YPull_Layer2_Module%d", i+1);
217  recHitYPullLayer2Modules[i] = dbe_->book1D(histo, "RecHit YPull Layer2 by module", 100, -10.0, 10.0);
218 
219  sprintf(histo, "RecHit_YPull_Layer3_Module%d", i+1);
220  recHitYPullLayer3Modules[i] = dbe_->book1D(histo, "RecHit YPull Layer3 by module", 100, -10.0, 10.0);
221  }
222 
223  dbe_->setCurrentFolder("TrackerRecHitsV/TrackerRecHits/Pixel/recHitPullsFPIX");
224  recHitXPullAllF = dbe_->book1D("RecHit_XPull_f_All", "RecHit X Pull All in Forward", 100, -10.0, 10.0);
225 
226  recHitYPullAllF = dbe_->book1D("RecHit_YPull_f_All", "RecHit Y Pull All in Forward", 100, -10.0, 10.0);
227 
228  for (int i=0; i<7; i++)
229  {
230  sprintf(histo, "RecHit_XPull_Disk1_Plaquette%d", i+1);
231  recHitXPullDisk1Plaquettes[i] = dbe_->book1D(histo, "RecHit XPull Disk1 by plaquette", 100, -10.0, 10.0);
232  sprintf(histo, "RecHit_XPull_Disk2_Plaquette%d", i+1);
233  recHitXPullDisk2Plaquettes[i] = dbe_->book1D(histo, "RecHit XPull Disk2 by plaquette", 100, -10.0, 10.0);
234 
235  sprintf(histo, "RecHit_YPull_Disk1_Plaquette%d", i+1);
236  recHitYPullDisk1Plaquettes[i] = dbe_->book1D(histo, "RecHit YPull Disk1 by plaquette", 100, -10.0, 10.0);
237 
238  sprintf(histo, "RecHit_YPull_Disk2_Plaquette%d", i+1);
239  recHitYPullDisk2Plaquettes[i] = dbe_->book1D(histo, "RecHit YPull Disk2 by plaquette", 100, -10.0, 10.0);
240  }
241 
242 }
243 
245 }
246 
248 
249 }
250 
252  if ( outputFile_.size() != 0 && dbe_ ) dbe_->save(outputFile_);
253 }
254 
256 {
257 
258  LogInfo("EventInfo") << " Run = " << e.id().run() << " Event = " << e.id().event();
259  if ( (int) e.id().event() % 1000 == 0 )
260  cout << " Run = " << e.id().run() << " Event = " << e.id().event() << endl;
261 
262  //Get RecHits
264  e.getByLabel( src_, recHitColl);
265 
266  //Get event setup
268  es.get<TrackerDigiGeometryRecord>().get(geom);
269  const TrackerGeometry& theTracker(*geom);
270 
271  TrackerHitAssociator associate( e, conf_ );
272 
273  //iterate over detunits
274  for (TrackerGeometry::DetContainer::const_iterator it = geom->dets().begin(); it != geom->dets().end(); it++)
275  {
276  DetId detId = ((*it)->geographicalId());
277  unsigned int subid=detId.subdetId();
278 
279  if (! ((subid==1) || (subid==2))) continue;
280 
281  const PixelGeomDetUnit * theGeomDet = dynamic_cast<const PixelGeomDetUnit*>(theTracker.idToDet(detId) );
282 
283  SiPixelRecHitCollection::const_iterator pixeldet = recHitColl->find(detId);
284  if (pixeldet == recHitColl->end()) continue;
285  SiPixelRecHitCollection::DetSet pixelrechitRange = *pixeldet;
286  SiPixelRecHitCollection::DetSet::const_iterator pixelrechitRangeIteratorBegin = pixelrechitRange.begin();
287  SiPixelRecHitCollection::DetSet::const_iterator pixelrechitRangeIteratorEnd = pixelrechitRange.end();
288  SiPixelRecHitCollection::DetSet::const_iterator pixeliter = pixelrechitRangeIteratorBegin;
289  std::vector<PSimHit> matched;
290 
291  //----Loop over rechits for this detId
292  for ( ; pixeliter != pixelrechitRangeIteratorEnd; pixeliter++)
293  {
294  matched.clear();
295  matched = associate.associateHit(*pixeliter);
296 
297  if ( !matched.empty() )
298  {
299  float closest = 9999.9;
300  std::vector<PSimHit>::const_iterator closestit = matched.begin();
301  LocalPoint lp = pixeliter->localPosition();
302  float rechit_x = lp.x();
303  float rechit_y = lp.y();
304 
305  //loop over sim hits and fill closet
306  for (std::vector<PSimHit>::const_iterator m = matched.begin(); m<matched.end(); m++)
307  {
308  float sim_x1 = (*m).entryPoint().x();
309  float sim_x2 = (*m).exitPoint().x();
310  float sim_xpos = 0.5*(sim_x1+sim_x2);
311 
312  float sim_y1 = (*m).entryPoint().y();
313  float sim_y2 = (*m).exitPoint().y();
314  float sim_ypos = 0.5*(sim_y1+sim_y2);
315 
316  float x_res = fabs(sim_xpos - rechit_x);
317  float y_res = fabs(sim_ypos - rechit_y);
318 
319  float dist = sqrt(x_res*x_res + y_res*y_res);
320 
321  if ( dist < closest )
322  {
323  closest = x_res;
324  closestit = m;
325  }
326  } // end sim hit loop
327 
328  if (subid==1)
329  { //<----------barrel
330  fillBarrel(*pixeliter, *closestit, detId, theGeomDet);
331  } // end barrel
332  if (subid==2)
333  { // <-------forward
334  fillForward(*pixeliter, *closestit, detId, theGeomDet);
335  }
336 
337  } // end matched emtpy
338  } // <-----end rechit loop
339  } // <------ end detunit loop
340 }
341 
342 void SiPixelRecHitsValid::fillBarrel(const SiPixelRecHit& recHit, const PSimHit& simHit,
343  DetId detId, const PixelGeomDetUnit* theGeomDet)
344 {
345  const float cmtomicron = 10000.0;
346 
347  LocalPoint lp = recHit.localPosition();
348  float lp_y = lp.y();
349  float lp_x = lp.x();
350 
351  LocalError lerr = recHit.localPositionError();
352  float lerr_x = sqrt(lerr.xx());
353  float lerr_y = sqrt(lerr.yy());
354 
355  recHitYAllModules->Fill(lp_y);
356 
357  float sim_x1 = simHit.entryPoint().x();
358  float sim_x2 = simHit.exitPoint().x();
359  float sim_xpos = 0.5*(sim_x1 + sim_x2);
360  float res_x = (lp.x() - sim_xpos)*cmtomicron;
361 
362  recHitXResAllB->Fill(res_x);
363 
364  float sim_y1 = simHit.entryPoint().y();
365  float sim_y2 = simHit.exitPoint().y();
366  float sim_ypos = 0.5*(sim_y1 + sim_y2);
367  float res_y = (lp.y() - sim_ypos)*cmtomicron;
368 
369  recHitYResAllB->Fill(res_y);
370 
371  float pull_x = ( lp_x - sim_xpos ) / lerr_x;
372  float pull_y = ( lp_y - sim_ypos ) / lerr_y;
373 
374  recHitXPullAllB->Fill(pull_x);
375  recHitYPullAllB->Fill(pull_y);
376 
377  int rows = theGeomDet->specificTopology().nrows();
378 
379  if (rows == 160)
380  {
381  recHitXFullModules->Fill(lp_x);
382  }
383  else if (rows == 80)
384  {
385  recHitXHalfModules->Fill(lp_x);
386  }
387 
388  float tmp1 = theGeomDet->surface().toGlobal(Local3DPoint(0.,0.,0.)).perp();
389  float tmp2 = theGeomDet->surface().toGlobal(Local3DPoint(0.,0.,1.)).perp();
390 
391  if (tmp2<tmp1)
392  { // flipped
393  for (unsigned int i=0; i<3; i++)
394  {
395  if (PXBDetId(detId).layer() == i+1)
396  {
399  }
400  }
401  }
402  else
403  {
404  for (unsigned int i=0; i<3; i++)
405  {
406  if (PXBDetId(detId).layer() == i+1)
407  {
410  }
411  }
412  }
413 
414  //get cluster
415  SiPixelRecHit::ClusterRef const& clust = recHit.cluster();
416 
417  // fill module dependent info
418  for (unsigned int i=0; i<8; i++)
419  {
420  if (PXBDetId(detId).module() == i+1)
421  {
422  int sizeY = (*clust).sizeY();
423  clustYSizeModule[i]->Fill(sizeY);
424 
425  if (PXBDetId(detId).layer() == 1)
426  {
427  float charge = (*clust).charge();
428  clustChargeLayer1Modules[i]->Fill(charge);
429  recHitYResLayer1Modules[i]->Fill(res_y);
430  recHitYPullLayer1Modules[i]->Fill(pull_y);
431  }
432  else if (PXBDetId(detId).layer() == 2)
433  {
434  float charge = (*clust).charge();
435  clustChargeLayer2Modules[i]->Fill(charge);
436  recHitYResLayer2Modules[i]->Fill(res_y);
437  recHitYPullLayer2Modules[i]->Fill(pull_y);
438  }
439  else if (PXBDetId(detId).layer() == 3)
440  {
441  float charge = (*clust).charge();
442  clustChargeLayer3Modules[i]->Fill(charge);
443  recHitYResLayer3Modules[i]->Fill(res_y);
444  recHitYPullLayer3Modules[i]->Fill(pull_y);
445  }
446  }
447  }
448  int sizeX = (*clust).sizeX();
449  if (PXBDetId(detId).layer() == 1) clustXSizeLayer[0]->Fill(sizeX);
450  if (PXBDetId(detId).layer() == 2) clustXSizeLayer[1]->Fill(sizeX);
451  if (PXBDetId(detId).layer() == 3) clustXSizeLayer[2]->Fill(sizeX);
452 }
453 
454 void SiPixelRecHitsValid::fillForward(const SiPixelRecHit & recHit, const PSimHit & simHit,
455  DetId detId,const PixelGeomDetUnit * theGeomDet )
456 {
457  int rows = theGeomDet->specificTopology().nrows();
458  int cols = theGeomDet->specificTopology().ncolumns();
459 
460  const float cmtomicron = 10000.0;
461 
462  LocalPoint lp = recHit.localPosition();
463  float lp_x = lp.x();
464  float lp_y = lp.y();
465 
466  LocalError lerr = recHit.localPositionError();
467  float lerr_x = sqrt(lerr.xx());
468  float lerr_y = sqrt(lerr.yy());
469 
470  float sim_x1 = simHit.entryPoint().x();
471  float sim_x2 = simHit.exitPoint().x();
472  float sim_xpos = 0.5*(sim_x1 + sim_x2);
473 
474  float sim_y1 = simHit.entryPoint().y();
475  float sim_y2 = simHit.exitPoint().y();
476  float sim_ypos = 0.5*(sim_y1 + sim_y2);
477 
478  float pull_x = ( lp_x - sim_xpos ) / lerr_x;
479  float pull_y = ( lp_y - sim_ypos ) / lerr_y;
480 
481 
482  if (rows == 80)
483  {
485  }
486  else if (rows == 160)
487  {
489  }
490 
491  if (cols == 104)
492  {
494  }
495  else if (cols == 156)
496  {
498  }
499  else if (cols == 208)
500  {
502  }
503  else if (cols == 260)
504  {
506  }
507 
508  float res_x = (lp.x() - sim_xpos)*cmtomicron;
509 
510  recHitXResAllF->Fill(res_x);
511  recHitXPullAllF->Fill(pull_x);
512 
513  float res_y = (lp.y() - sim_ypos)*cmtomicron;
514 
515  recHitYPullAllF->Fill(pull_y);
516 
517  // get cluster
518  SiPixelRecHit::ClusterRef const& clust = recHit.cluster();
519 
520  // fill plaquette dependent info
521  for (unsigned int i=0; i<7; i++)
522  {
523  if (PXFDetId(detId).module() == i+1)
524  {
525  if (PXFDetId(detId).disk() == 1)
526  {
527  int sizeX = (*clust).sizeX();
529 
530  int sizeY = (*clust).sizeY();
532 
533  float charge = (*clust).charge();
535 
538 
541  }
542  else
543  {
544  int sizeX = (*clust).sizeX();
546 
547  int sizeY = (*clust).sizeY();
549 
550  float charge = (*clust).charge();
552 
555 
558 
559  } // end else
560  } // end if module
561  else if (PXFDetId(detId).panel() == 2 && (PXFDetId(detId).module()+4) == i+1)
562  {
563  if (PXFDetId(detId).disk() == 1)
564  {
565  int sizeX = (*clust).sizeX();
567 
568  int sizeY = (*clust).sizeY();
570 
571  float charge = (*clust).charge();
573 
576 
579  }
580  else
581  {
582  int sizeX = (*clust).sizeX();
584 
585  int sizeY = (*clust).sizeY();
587 
588  float charge = (*clust).charge();
590 
593 
596 
597  } // end else
598  } // end else
599  } // end for
600 }
RunNumber_t run() const
Definition: EventID.h:42
GlobalPoint toGlobal(const Point2DBase< Scalar, LocalTag > lp) const
Definition: Surface.h:78
EventNumber_t event() const
Definition: EventID.h:44
T getUntrackedParameter(std::string const &, T const &) const
int i
Definition: DBlmapReader.cc:9
MonitorElement * clustYSizeModule[8]
MonitorElement * clustXSizeDisk1Plaquettes[7]
float xx() const
Definition: LocalError.h:19
edm::ParameterSet conf_
int module() const
Definition: HLTadd.h:12
boost::transform_iterator< IterHelp, const_IdIter > const_iterator
MonitorElement * recHitXPullDisk2Plaquettes[7]
MonitorElement * recHitXResFlippedLadderLayers[3]
virtual LocalError localPositionError() const
MonitorElement * recHitXFullModules
MonitorElement * recHitXResAllF
T perp() const
Definition: PV3DBase.h:66
MonitorElement * recHitXHalfModules
virtual int ncolumns() const =0
MonitorElement * recHitYPullAllF
MonitorElement * recHitXResDisk1Plaquettes[7]
MonitorElement * clustXSizeDisk2Plaquettes[7]
MonitorElement * recHitYResAllB
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:1883
MonitorElement * recHitYPullDisk2Plaquettes[7]
MonitorElement * clustXSizeLayer[3]
T y() const
Definition: PV3DBase.h:57
MonitorElement * clustChargeLayer1Modules[8]
virtual int nrows() const =0
MonitorElement * recHitYPlaquetteSize5
tuple histo
Definition: trackerHits.py:12
MonitorElement * recHitXPlaquetteSize1
MonitorElement * recHitXResDisk2Plaquettes[7]
double charge(const std::vector< uint8_t > &Ampls)
MonitorElement * recHitXPullNonFlippedLadderLayers[3]
virtual LocalPoint localPosition() const
void Fill(long long x)
MonitorElement * recHitYPullDisk1Plaquettes[7]
MonitorElement * recHitXPullAllB
MonitorElement * recHitXResAllB
MonitorElement * clustChargeLayer2Modules[8]
MonitorElement * recHitYResDisk2Plaquettes[7]
Local3DPoint exitPoint() const
Exit point in the local Det frame.
Definition: PSimHit.h:38
MonitorElement * recHitXResNonFlippedLadderLayers[3]
MonitorElement * recHitYResDisk1Plaquettes[7]
MonitorElement * recHitYResLayer2Modules[8]
MonitorElement * recHitYPlaquetteSize2
float yy() const
Definition: LocalError.h:21
T sqrt(T t)
Definition: SSEVec.h:28
MonitorElement * recHitYPullLayer3Modules[8]
MonitorElement * clustYSizeDisk1Plaquettes[7]
void fillForward(const SiPixelRecHit &, const PSimHit &, DetId, const PixelGeomDetUnit *)
int subdetId() const
get the contents of the subdetector field (not cast into any detector&#39;s numbering enum) ...
Definition: DetId.h:39
virtual const GeomDet * idToDet(DetId) const
bool getByLabel(InputTag const &tag, Handle< PROD > &result) const
Definition: Event.h:359
DQMStore * dbe_
virtual void analyze(const edm::Event &e, const edm::EventSetup &c)
MonitorElement * recHitXPlaquetteSize2
Point3DBase< float, LocalTag > Local3DPoint
Definition: LocalPoint.h:9
MonitorElement * clustChargeLayer3Modules[8]
Definition: DetId.h:20
MonitorElement * recHitYResAllF
MonitorElement * recHitYResLayer3Modules[8]
const T & get() const
Definition: EventSetup.h:55
virtual const PixelTopology & specificTopology() const
Returns a reference to the pixel proxy topology.
MonitorElement * recHitYPullLayer2Modules[8]
MonitorElement * clustYSizeDisk2Plaquettes[7]
edm::EventID id() const
Definition: EventBase.h:56
MonitorElement * recHitYPlaquetteSize4
iterator end()
Definition: DetSetNew.h:59
MonitorElement * recHitXPullFlippedLadderLayers[3]
void fillBarrel(const SiPixelRecHit &, const PSimHit &, DetId, const PixelGeomDetUnit *)
std::vector< PSimHit > associateHit(const TrackingRecHit &thit)
MonitorElement * recHitYResLayer1Modules[8]
MonitorElement * recHitYPullLayer1Modules[8]
tuple cout
Definition: gather_cfg.py:41
MonitorElement * recHitXPullDisk1Plaquettes[7]
SiPixelRecHitsValid(const edm::ParameterSet &conf)
MonitorElement * recHitYPullAllB
T x() const
Definition: PV3DBase.h:56
ClusterRef const & cluster() const
Definition: SiPixelRecHit.h:42
MonitorElement * recHitXPullAllF
Local3DPoint entryPoint() const
Entry point in the local Det frame.
Definition: PSimHit.h:35
virtual const BoundPlane & surface() const
The nominal surface of the GeomDet.
Definition: GeomDet.h:37
MonitorElement * recHitYPlaquetteSize3
MonitorElement * clustChargeDisk1Plaquettes[7]
MonitorElement * clustChargeDisk2Plaquettes[7]
Our base class.
Definition: SiPixelRecHit.h:27
MonitorElement * recHitYAllModules
iterator begin()
Definition: DetSetNew.h:56